[Rt-commit] rt branch, 4.6/inline-edit, updated. rt-4.4.1-145-gf444e0e
Shawn Moore
shawn at bestpractical.com
Fri Sep 16 13:16:55 EDT 2016
The branch, 4.6/inline-edit has been updated
via f444e0ea148fdd79143c1fae0c1860742f538a98 (commit)
via a30eb5f583cd26b03cf0533303388d71d41d7342 (commit)
from 9b803063aa7bb8959d00e804a9cd3301a7b6f43e (commit)
Summary of changes:
share/html/Elements/CollectionAsTable/Row | 2 ++
share/html/Elements/RT__Ticket/ColumnMap | 3 ++-
2 files changed, 4 insertions(+), 1 deletion(-)
- Log -----------------------------------------------------------------
commit a30eb5f583cd26b03cf0533303388d71d41d7342
Author: Shawn M Moore <shawn at bestpractical.com>
Date: Fri Sep 16 17:10:37 2016 +0000
Inline edit for ticket SLA
DefaultFromArgs => 0 forces the SelectSLA component to use the ticket's
current value for the default, rather than whatever happened to have been
passed as the "SLA" query parameter
diff --git a/share/html/Elements/RT__Ticket/ColumnMap b/share/html/Elements/RT__Ticket/ColumnMap
index e0c298e..411aab4 100644
--- a/share/html/Elements/RT__Ticket/ColumnMap
+++ b/share/html/Elements/RT__Ticket/ColumnMap
@@ -281,7 +281,8 @@ $COLUMN_MAP = {
SLA => {
attribute => 'SLA',
title => 'SLA', # loc
- value => sub { return $_[0]->SLA }
+ value => sub { return $_[0]->SLA },
+ edit => sub { return \($m->scomp('/Elements/SelectSLA', TicketObj => $_[0], DefaultFromArgs => 0)) },
},
UpdateStatus => {
title => 'New messages', # loc
commit f444e0ea148fdd79143c1fae0c1860742f538a98
Author: Shawn M Moore <shawn at bestpractical.com>
Date: Fri Sep 16 17:15:01 2016 +0000
For now, limit inline edit to just tickets
There are some "edit" entries in the base RT::Record ColumnMap, so without
this restriction, the UI for inline edit would appear on the collection list
for any record type with custom fields. Since the plumbing is implemented
only for tickets, limit the porcelain to tickets as well.
diff --git a/share/html/Elements/CollectionAsTable/Row b/share/html/Elements/CollectionAsTable/Row
index ffd4f59..3d279cb 100644
--- a/share/html/Elements/CollectionAsTable/Row
+++ b/share/html/Elements/CollectionAsTable/Row
@@ -109,6 +109,8 @@ foreach my $column (@Format) {
delete $attrs{edit} if !$InlineEdit;
+ delete $attrs{edit} unless $record->isa('RT::Ticket');
+
delete $attrs{edit} if $record->isa('RT::Ticket')
&& !$record->CurrentUserHasRight('ModifyTicket');
-----------------------------------------------------------------------
More information about the rt-commit
mailing list