# Field order changes via layout editor not persisting between logins

**URL:** <https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645>\
**Category:** Help me!\
**Created:** [July 10, 2020, 9:19pm UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645 "2020-07-10T21:19:20Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![canada-market](https://dub1.discourse-cdn.com/flex013/user_avatar/community.forestadmin.com/canada-market/32/520_2.png) [@canada-market](https://community.forestadmin.com/u/canada-market)\
**Post date:** [July 10, 2020, 9:19pm UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645/1 "2020-07-10T21:19:20Z")

</div>

## Expected behavior

We are expecting that layout changes that we make – in particular with respect to the order of fields in the “Add” and “Edit” views – will reliably persist.

## Actual behavior

1. Open layout editor, change field order in the “add” and “edit” views. Confirm fields are in the desired order.
2. Log out.
3. Log back in. Field order is reverted to before layout edits in step 1.

Additional context: This is happening specifically for 5 of our tables where the field display names were (erroneously) changed and then changed back to original names. This doesn’t seem like it _should_ be relevant _but_ the failure to persist field order issue is only affected these same 5 tables.

## Failure Logs

No errors in logs are observed.

## Context

package dependencies are as follows:

```
"chalk": "~1.1.3",
"cookie-parser": "1.4.4",
"cors": "2.8.5",
"debug": "~4.0.1",
"dotenv": "~6.1.0",
"express": "~4.16.3",
"express-jwt": "5.3.1",
"forest-express-sequelize": "^6.0.0",
"morgan": "1.9.1",
"pg": "~6.1.0",
"require-all": "^3.0.0",
"sequelize": "~5.15.1",
"sequelize-noupdate-attributes": "^1.0.0"

```

Project name: CM-API  
(Issue is occurring in both environments)

---

<div class="post-metadata">

**Author:** ![anon39848301](https://avatars.discourse-cdn.com/v4/letter/a/b9e5f3/32.png) [@anon39848301](https://community.forestadmin.com/u/anon39848301)\
**Post date:** [July 13, 2020, 8:41am UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645/2 "2020-07-13T08:41:34Z")

</div>

Hi @canada-market, and welcome to our community !

I’m not able to reproduce your issue on both collection with and without custom display name. Since a fix was deployed friday for a similar issue, would you mind refreshing your browser and tell me if the problem persist ?

If that’s the case, could you provide any further explanation that could help me reproduce your issue ?

Thanks in advance 🙏

---

<div class="post-metadata">

**Author:** ![canada-market](https://dub1.discourse-cdn.com/flex013/user_avatar/community.forestadmin.com/canada-market/32/520_2.png) [@canada-market](https://community.forestadmin.com/u/canada-market)\
**Post date:** [July 13, 2020, 2:39pm UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645/3 "2020-07-13T14:39:31Z")

</div>

Hey @anon39848301 – thanks for your reply.

The issue is still persisting.

I was able to reproduce it just now as follows:

1. log into one of our environments (“development-shared”) for our project (“cm-admin”)
2. navigate to one of our collections (“agent terms agreements”) and modify the ‘add’ and ‘details / edit’ layouts as follows:

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/forest/original/1X/2c7853dab797abfd2450e25943f83ed8da3e1050.png)

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/forest/original/1X/87028f8d1a135b84196bfe15e7d8a9dd9aeeb391.png)

(Note order of fields is : [id, agent, terms, request details, created by]

1. log out of environment and then log back in.

2. See that the field order layout has reverted and the layout changes made in step 2 are no longer present:

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/forest/original/1X/e62a4f172cd9ac2234ecfa01398193d1e380cfeb.png)

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/forest/original/1X/18d257d15d4e34b1582351c6486eba486beae616.png)

Please let me know anything else that I could provide to assist with trouble-shooting at your end.

Note that this is a development environment without any production data so I would be happy to create or share credentials for login if that would help.

---

<div class="post-metadata">

**Author:** ![anon39848301](https://avatars.discourse-cdn.com/v4/letter/a/b9e5f3/32.png) [@anon39848301](https://community.forestadmin.com/u/anon39848301)\
**Post date:** [July 13, 2020, 3:23pm UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645/4 "2020-07-13T15:23:23Z")

</div>

@canada-market totally my bad, I’m indeed able to reproduce. Using your browser developer console, could you please confirm that the `/api/layout` request return you a HTTP 422 error ?

I’m digging through this and I’ll let you know when I have more informations to share.

**EDIT:** The team did locate the source of the issue and is working on a fix. We’ll keep you posted as soon as it is released

---

<div class="post-metadata">

**Author:** ![anon39848301](https://avatars.discourse-cdn.com/v4/letter/a/b9e5f3/32.png) [@anon39848301](https://community.forestadmin.com/u/anon39848301)\
**Post date:** [July 13, 2020, 5:26pm UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645/5 "2020-07-13T17:26:14Z")

</div>

@canada-market the fix was deployed 5 minutes ago, so your problem should definitely be fixed.

Let me know if everything is ok on your side 🙏

---

<div class="post-metadata">

**Author:** ![canada-market](https://dub1.discourse-cdn.com/flex013/user_avatar/community.forestadmin.com/canada-market/32/520_2.png) [@canada-market](https://community.forestadmin.com/u/canada-market)\
**Post date:** [July 13, 2020, 9:33pm UTC](https://community.forestadmin.com/t/field-order-changes-via-layout-editor-not-persisting-between-logins/645/6 "2020-07-13T21:33:08Z")

</div>

@anon39848301

So far, so good! The issue now appears to be resolved and my most-recent layout changes have now persisted between logins.

I’ll come back to this post if I ever see the issue again but I believe that we can consider it “closed” for now.

Thanks for the help!
