#11649 closed enhancement (fixed)
Add description field to ticket enums
| Reported by: | Ryan J Ollos | Owned by: | Ryan J Ollos |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.3.2 |
| Component: | ticket system | Version: | |
| Severity: | normal | Keywords: | |
| Cc: | craig_silver@… | Branch: | |
| Release Notes: |
Added |
||
| API Changes: | |||
| Internal Changes: | |||
Description (last modified by )
A description field will be added for each ticket enum. This was discussed in comment:10:ticket:1233.
Attachments (0)
Change History (14)
comment:1 by , 11 years ago
| Owner: | set to |
|---|---|
| Status: | new → assigned |
comment:2 by , 11 years ago
| Cc: | added |
|---|
follow-up: 13 comment:3 by , 11 years ago
comment:4 by , 11 years ago
| Description: | modified (diff) |
|---|
comment:5 by , 11 years ago
| Milestone: | 1.1.3 → next-dev-1.1.x |
|---|---|
| Owner: | removed |
| Status: | assigned → new |
comment:7 by , 10 years ago
| Milestone: | next-dev-1.1.x → next-dev-1.3.x |
|---|
Narrowing focus for milestone:1.2. Please move ticket to milestone:1.2 if you intend to fix it.
comment:8 by , 9 years ago
| Milestone: | next-dev-1.3.x → 1.3.2 |
|---|---|
| Owner: | set to |
| Release Notes: | modified (diff) |
| Status: | new → assigned |
Proposed changes in rjollos.git:t11649_enum_description. The "string replace" used to modify the reports is similar to that in db13.py. I've also tried to make the reports for new environments more robust against the need for changes ([cc17233d/rjollos.git]).
Upgrade step documented in 1.3/TracUpgrade@12 and 1.3/TracUpgrade@13.
follow-up: 10 comment:9 by , 9 years ago
At least, enum.name is incorrectly formatted as javascript.
jQuery(document).ready(function($) {
$("#description").autoPreview("${href.wiki_render()}", {
realm: "${enum.type}",
- id: "${enum.name}"
+ id: ${to_json(enum.name)|safe}
}, $("#preview").showOnPreview());
});
comment:10 by , 9 years ago
Replying to Jun Omae:
At least,
enum.nameis incorrectly formatted as javascript.jQuery(document).ready(function($) { $("#description").autoPreview("${href.wiki_render()}", { realm: "${enum.type}", - id: "${enum.name}" + id: ${to_json(enum.name)|safe} }, $("#preview").showOnPreview()); });
That would also be true then for other instances in which an arbitrary string is used for id, such as in milestone_edit_form.html?
comment:11 by , 9 years ago
Yes. I think we should check whether it is needed to use to_json or javascript_quote in the following locations.
$ git grep ": *[\"']\${"
trac/ticket/templates/admin_components.html: realm: "${component.resource.realm}",
trac/ticket/templates/admin_components.html: id: "${component.resource.id}"
trac/ticket/templates/admin_enums.html: realm: "${enum.type}",
trac/ticket/templates/admin_enums.html: id: "${enum.name}"
trac/ticket/templates/admin_versions.html: realm: "${version.resource.realm}",
trac/ticket/templates/admin_versions.html: id: "${version.resource.id}"
trac/ticket/templates/milestone_edit_form.html: realm: "${milestone.resource.realm}",
trac/ticket/templates/milestone_edit_form.html: id: "${milestone.resource.id}"
trac/ticket/templates/report_edit.html: realm: "report", id: "${report.id}"
trac/versioncontrol/templates/admin_repositories.html: realm: "repository", id: "${reponame}"
trac/versioncontrol/templates/browser.html: range_min_secs: '${dir.range_min_secs}',
trac/versioncontrol/templates/browser.html: range_max_secs: '${dir.range_max_secs}'
trac/versioncontrol/templates/revisionlog.html: var canvas = $('<canvas>').css({width: '${graph.columns * 2}em',
trac/versioncontrol/templates/revisionlog.html: height: '${len(items) * 2}em'})
trac/wiki/templates/wiki_edit.html: realm: "${page.resource.realm}", id: "${page.resource.id}"
comment:12 by , 9 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Committed to trunk in r15933. I'll address the comment:11 changes in #3776.
comment:13 by , 9 years ago
Replying to Ryan J Ollos:
After this ticket is implemented, we should consider creating a macro to list the enums and optionally their descriptions. This would be useful for listing the Resolution descriptions on the TracTicketTriage#StatusandResolution page.
This can probably be handled in #11702, or in tickets that follow from that one. I've updated comment:description:ticket:11702 to include consideration of a Ticket enum macro.
comment:14 by , 6 years ago
| Release Notes: | modified (diff) |
|---|



After this ticket is implemented, we should consider creating a macro to list the enums and optionally their descriptions. This would be useful for listing the Resolution descriptions on the TracTicketTriage#StatusandResolution page.