New column has been added to the existing table (on both Development & Staging).
On Development environment the field is visible and works as expected.
Two segments were created using new field.
After configured Development layout was copied to Staging.
Notes:
segments were copied successfully, but conditions inside are empty;
hard reload with empty cache does not help;
query-based segment using new field are working as expected.
Expected behavior
Field is available in layout editor.
Field is visible in segment conditions.
Actual behavior
Field is not available in layout editor.
Field is not visible in segment conditions.
What is your field name? Is it CVR_company_status?
Is this field a smart field?
It might be a bit silly, but are you sure this field has been added to both Development and Staging server models? Can you see it in both environments in the Companies table?
yes, I’m sure, that field is added to the model. Database migration & model changes were delivered simultaneously during yesterday’s deploy, no doubt about that. As I’ve mentioned in actual behavior section - the field is not available, just not there, in the layout editor (this includes both list and detailed view on Companies collection), not only in segments.
Ok so it’s not a problem about the copy layout, but a problem about your field not taken into account in your staging collection even if it has been defined in your model.
From what I can see, your Development environment last model refresh that we received is from yesterday.
However, your Staging environment last model refresh was the 10th of November.
Might be silly again, but I have to ask: did you actually restarted the Staging instance?
When you restart it, do you have any error in the server console?
Yes, restart occurred at least after deploy to Staging, that happened yesterday. Back-end is a serverless function, so instances are created & disposed regularly.
I’ve checked logs, but see nothing suspicious there.
I thought of layout copy just because we’ve used it for similar tasks without problems before.
I confirm that the problem is that we did not receive the new models for your Staging environment since the 10th of November.
It could be caused by 2 issues I can think of:
Your server did not restarted yet (it’s a this specific moment that the new apiMap is calculated and sent to us).
There is an error in your models (for instance) and so the new apiMap cannot be generated.
Can you confirm that your code is identical between your Development and your Staging?
Server did restart at least once, otherwise database migration would not have been applied. Migration & model changes were deployed together. I’ve restarted server several times but it didn’t help.
Another idea: can you check that the forestadmin-schema.json file that has been generated by your Development environment has been pushed to your Staging environment?
It is a pre-requisite in the workflow to make everything work.