localgov icon indicating copy to clipboard operation
localgov copied to clipboard

Feature/466 autosave

Open finnlewis opened this issue 2 years ago • 11 comments

@keelanfh @markconroy @andybroomfield

Here's a PR to test, just adds and installs the module with default configuration (saves content forms every 60 seconds)

Coming from https://github.com/localgovdrupal/localgov/issues/466

finnlewis avatar Jan 11 '23 15:01 finnlewis

Initial look through. Installing this branch does not appear to enable autosave by default in an existing install. Once enabled, it can still be removed. I noticed it doesn't come with any configuration so to be useful is going to need to be enabled and set to autosave on all content types, which I guess also means there is going to be something needed to update that, which brings back the issues in the original PR about how to make this opt in.

andybroomfield avatar Jan 11 '23 17:01 andybroomfield

@andybroomfield If you don't select any of the content types, it defaults to being enabled for all content types. So I don't think that would require ongoing changes.

keelanfh avatar Jan 11 '23 18:01 keelanfh

Would be good to have a notification or something to existing sites via drupal_set_message to say "Hey, we've added an autosave module, would you like to enable it".

We've lots of nice new features that existing sites don't get by default. Sorry, I know this is a side issue to the main PR.

markconroy avatar Jan 12 '23 11:01 markconroy

No need to apologise Mark, this was a large topic of conversation in our Tech Group Governance meeting yesterday.

Specifically: "What is the policy for adding modules to default install LocalGov eg. autosave"

I will draft a policy for review, but key questions include:

  1. are there at least 2 councils requesting a new module or feature?
  2. Are users able to optionally disable the module / feature?
  3. Are most of our users using / wanting the module / feature?
  4. Should we check with the product group / product owner?
  5. How do we communicate new potential additions to existing instalations? (Release notes / README / drupal_set_message like you suggest @markconroy ?)

So perhaps we can use this pull request as a case in point to draft and agree a working policy for such things.

finnlewis avatar Jan 12 '23 11:01 finnlewis

Thanks @keelanfh I did notice that after a while, I got thrown as autosave does not work for /node/add, so only noticed it when I went back to edit. I'd worry though about rolling it out to all content, to be useful it may welll need to have some default config shipped with it, which brings us back to how to make this opt in.

andybroomfield avatar Jan 12 '23 12:01 andybroomfield

Worth putting this to draft whilst the discussion is ongoing @finnlewis ?

andybroomfield avatar Jan 13 '23 16:01 andybroomfield

I've started a draft policy for discussion on the general questions this raises: https://github.com/localgovdrupal/localgov/wiki/%5BDraft%5D-Policy-for-adding-a-new-feature,-functionality-or-modules-to-LocalGov-Drupal

finnlewis avatar Jan 16 '23 14:01 finnlewis

@andybroomfield that's interesting that it doesn't work for /node/add, I was not aware of that.

keelanfh avatar Jan 17 '23 13:01 keelanfh

Going to need at least these patches on core I think to get it to work with paragraphs https://www.drupal.org/project/drupal/issues/2824097 https://www.drupal.org/project/drupal/issues/2844229

And this patch on the module to get autosave on node creation https://www.drupal.org/project/autosave_form/issues/2924006

andybroomfield avatar Jan 23 '23 14:01 andybroomfield

This is still being discussed in the backlog group with some updates being tested.

finnlewis avatar Jun 05 '23 13:06 finnlewis

Still being discussed https://github.com/localgovdrupal/localgov/issues/466

finnlewis avatar Jun 21 '23 16:06 finnlewis