Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
best-practical
rt-extension-jsgantt
Commits
b2fa5536
Commit
b2fa5536
authored
Oct 27, 2011
by
sunnavy
Browse files
make ColorSchemeByOwner true by default
everyone loves coloring owners consistently
parent
21e1359b
Changes
2
Hide whitespace changes
Inline
Side-by-side
README
View file @
b2fa5536
...
...
@@ -16,14 +16,23 @@ How to install:
ShowOwner => 1,
ShowProgress => 1,
ShowDuration => 1,
# define your own color scheme
ColorScheme => ['ff0000', 'ffff00', 'ff00ff', '00ff00', '00ffff', '0000ff'],
# use the same color for each owner and specify colors to use for some owners
ColorSchemeByOwner => { root => 'ff0000', foo => '00ff00' },
# we color owners consistently by default, you can disable it via:
# ColorSchemeByOwner => 0,
# you can specify colors to use, unspecified owners will be
# assigned to some color automatically:
# ColorSchemeByOwner => { root => 'ff0000', foo => '00ff00' },
# if can't find both start and end dates, use this color
NullDatesColor => 333,
# to caculate day length
WorkingHoursPerDay => 8,
# used to set start/end if one exists but the other does not
DefaultDays => 7,
);
...
...
lib/RT/Extension/JSGantt.pm
View file @
b2fa5536
...
...
@@ -134,6 +134,7 @@ sub TicketsInfo {
my
(
$min_start
,
$min_start_obj
);
my
%color_map
;
$options
{
ColorSchemeByOwner
}
=
1
unless
exists
$options
{
ColorSchemeByOwner
};
if
(
$options
{
ColorSchemeByOwner
}
)
{
my
@owner_names
=
uniq
map
{
$_
->
OwnerObj
->
Name
}
@
{
$args
{
Tickets
}
};
@color_map
{
@owner_names
}
=
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment