forgejo/templates/repo/issue
Sai Nane 1e54e211ca Fix milestone assignment in New Issue
Avoids the use of HTMX on milestone assignment within a New Issue form.

The New Issue form doesn't have an issue ID to send to a milestone change URL,
which the backend expects in order to construct a proper reply. The frontend
template was also not built to use the new HTMX response. This resulted in a
backend error and a large warning whenever anyone tried to set a milestone
from within the New Issue form (new pull requests were also affected), rather
than from a View Issue page.

This introduces a new parameter into the `issue/milestone/select_menu`
template, "NewIssuePage".

When unset, the template produces the same results as before. Selection uses
`hx-post` to notify the server immediately, using the updated htmx fragment
from the reply.

When set to a truthy value, the old style of form is used. Selection uses
`data-id` and `data-href` to update the selected milestone locally, via
`selectItem` in `repo-legacy.js`, recreating the selected element and updating
the hidden form value.

Fixes #5176.
2024-09-17 17:45:02 +02:00
..
fields
labels follow up on #2367: rel="nofollow" on in-list labels 2024-08-15 21:56:26 +02:00
milestone Fix milestone assignment in New Issue 2024-09-17 17:45:02 +02:00
view_content [PORT] Add warning message in merge instructions when AutodetectManualMerge was not enabled (gitea#31805) 2024-08-11 19:15:37 +02:00
card.tmpl
choose.tmpl
comment_tab.tmpl
filter_actions.tmpl
filter_list.tmpl [BUG] Ensure all filters are persistent in issue filters 2024-08-06 17:12:10 +02:00
filters.tmpl
label_precolors.tmpl
labels.tmpl
list.tmpl
milestone_issues.tmpl
milestone_new.tmpl
milestones.tmpl
navbar.tmpl
new.tmpl
new_form.tmpl Fix milestone assignment in New Issue 2024-09-17 17:45:02 +02:00
openclose.tmpl
search.tmpl
view.tmpl
view_content.tmpl Update module github.com/editorconfig-checker/editorconfig-checker/v2/cmd/editorconfig-checker to v3 2024-08-09 21:03:37 +02:00
view_title.tmpl fix: WIP toggle by reducing max issue title 2024-08-29 01:36:58 +02:00