1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2024-11-30 09:41:11 -05:00
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 Don't show hidden labels when filling out an issue template (#31576) 2024-07-14 10:39:08 +02:00
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 Fix overflow in issue card (#31203) 2024-06-09 11:13:39 +02:00
choose.tmpl Fix spacing in issue navbar (#30238) 2024-04-07 15:40:31 +02:00
comment_tab.tmpl Always use ctx.Locale.Tr inside templates (#27231) 2023-09-25 08:56:50 +00:00
filter_actions.tmpl Rename project board -> column to make the UI less confusing (#30170) 2024-06-02 09:42:39 +02:00
filter_list.tmpl [BUG] Ensure all filters are persistent in issue filters 2024-08-06 17:12:10 +02:00
filters.tmpl Migrate margin and padding helpers to tailwind (#30043) 2024-03-30 07:17:29 +01:00
label_precolors.tmpl Replace 10 more gt- classes with tw- (#29945) 2024-03-26 19:04:27 +01:00
labels.tmpl Fix spacing in issue navbar (#30238) 2024-04-07 15:40:31 +02:00
list.tmpl Replace gt-word-break with tw-break-anywhere 2024-06-11 08:57:27 +05:00
milestone_issues.tmpl chore: rename class issue-title-buttons to button-row 2024-06-28 13:11:16 +05:00
milestone_new.tmpl Fix spacing in issue navbar (#30238) 2024-04-07 15:40:31 +02:00
milestones.tmpl chore: rename class issue-title-buttons to button-row 2024-06-28 13:11:16 +05:00
navbar.tmpl Fix menu buttons in issues and release (#30056) 2024-03-30 07:17:30 +01:00
new.tmpl Fix incorrect redirection when creating a PR fails (#29537) 2024-03-06 12:10:45 +08:00
new_form.tmpl Fix milestone assignment in New Issue 2024-09-17 17:45:02 +02:00
openclose.tmpl Migrate margin and padding helpers to tailwind (#30043) 2024-03-30 07:17:29 +01:00
search.tmpl fix(ui): use right placeholder string in milestones search (#4628) 2024-07-25 03:33:44 +00:00
view.tmpl Make Issue/PR/projects more compact, misc CSS tweaks (#24459) 2023-05-03 17:58:59 -04:00
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