Thanks for the great effort for the WebIssues program and support.
In order to emphasize the priority of issues, I added Attribute as "Priority". "Priority" attribute Type is Dropdown list that has items "Urgent, High, Medium, Low".
One thing I wish to change is add css style for this "Priority" value from the Issue list and Issue detail using by "border-radius" and "background" property.
For example some issue has "Urgent" priority value, "Urgent" text has 12px border-radius with red background, yellow font-color.
In my opinion, this can be done using
- add some style to common/theme/style.css
- add some code to client/issuelist.html.php
I using webissue ver 1.1.4 and web client now.
Would you please advise me? Thanks in advance.
- Log in to post comments
I found a solution by myself. If you want to change userdefined attribute value instead of text such as icon or progress bar, colored text or whatever CSS style supports, then it can be done.
Just add your css class or id to style.css. After that, modify issuelist.html.php. If you want to change attribute value on detail page of each issue, modify issuedetail.html.php.
1. Add CSS style to common/style.css
#priority-urgent defines red round button style. It helps easy recognition of each issue's priority by color.
For example, Priority "Urgent" has color Red, "Normal" has Blue, "Low" has Green and "Undefined" has Gray.
Add below css definition to bottom of style.css file.
#priority-urgent { width : 30px; height:14px; font-size:11px; color: black; line-height:13px; background: red; border: solid 1px black; border-radius: 12px }
2. Add code to client/issuelist.html.php
63: elseif ( $column == System_Api_Column::Location ):
64: echo $issue[ 'project_name'] . ' — ' . $issue[ 'folder_name' ];
65: else:
66: if ( $issue[ $name ] == "Urgent") :
67: echo '<div id=priority-urgent>'. $issue[$name] . '</div>'; // Add your code depend on userdefined dropdown list what will you do.
68: else:
69: echo $issue[$name];
70: endif;
71:endif;
72:?>
3. Add attribute and set value from admin panel