Re-Check on Issue/Comment content change if things have changed in between #13619

Closed
opened 2025-11-02 10:48:24 -06:00 by GiteaMirror · 3 comments
Owner

Originally created by @6543 on GitHub (Oct 21, 2024).

dublicat of https://github.com/go-gitea/gitea/issues/22907

Feature Description

currently if you edit an issue or comment, we use the value we got on init load of the page and then submit as new state whatever is in the editor as new value.

If you have some other person edit something in between this, it will get overwritten without even being noticed.

we could either add some lock mechansim that only allow one to edit, but we then have to add a lot of complexity e.g. when to timeout ...

... or we could add an optionall parameter on the save proggess that submits the content hash of the old value, witch the backend can check on an update. if it does not macht we can show an error to the user and not save it ...
... the user then can either force update or reload and edit new ...

... instead of an content hash we could also add version number to issue/comment content that can be checked and are itterated

the second proposal only need to update the WebUI and the update functions...

Screenshots

No response

Originally created by @6543 on GitHub (Oct 21, 2024). ### dublicat of https://github.com/go-gitea/gitea/issues/22907 ### Feature Description currently if you edit an issue or comment, we use the value we got on init load of the page and then submit as new state whatever is in the editor as new value. If you have some other person edit something in between this, it will get overwritten without even being noticed. we could either add some lock mechansim that only allow one to edit, but we then have to add a lot of complexity e.g. when to timeout ... ... or we could add an optionall parameter on the save proggess that submits the content hash of the old value, witch the backend can check on an update. if it does not macht we can show an error to the user and not save it ... ... the user then can either force update or reload and edit new ... ... instead of an content hash we could also add version number to issue/comment content that can be checked and are itterated the second proposal only need to update the WebUI and the update functions... ### Screenshots _No response_
GiteaMirror added the topic/uxtype/proposaltopic/uiissue/duplicate labels 2025-11-02 10:48:24 -06:00
Author
Owner

@6543 commented on GitHub (Oct 21, 2024):

-> we might also have a look if we can use the content history to derive a version "number" ...

@6543 commented on GitHub (Oct 21, 2024): -> we might also have a look if we can use the content history to derive a version "number" ...
Author
Owner

@wxiaoguang commented on GitHub (Oct 21, 2024):

Isn't it already there?

-> Prevent simultaneous editing of comments and issues #31053

@wxiaoguang commented on GitHub (Oct 21, 2024): Isn't it already there? -> Prevent simultaneous editing of comments and issues #31053
Author
Owner

@6543 commented on GitHub (Oct 21, 2024):

well just shows that I'm currently not up to date to all issues/pulls :/

but thanks nice 🎉

@6543 commented on GitHub (Oct 21, 2024): well just shows that I'm currently not up to date to all issues/pulls :/ but thanks nice :tada:
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#13619