Index: lams_tool_scratchie/web/pages/learning/results.jsp =================================================================== diff -u -r60a436814bc46a3089f38fc7d2702787e1950ca4 -rd5c812e896f5a590bd3b91b6c3753b0ae0f82a38 --- lams_tool_scratchie/web/pages/learning/results.jsp (.../results.jsp) (revision 60a436814bc46a3089f38fc7d2702787e1950ca4) +++ lams_tool_scratchie/web/pages/learning/results.jsp (.../results.jsp) (revision d5c812e896f5a590bd3b91b6c3753b0ae0f82a38) @@ -40,6 +40,16 @@ padding-top: 3px; padding-bottom: 3px } + + /* when item is editable - show pencil icon on hover */ + .burning-question-text:hover +span+ i, /* when link is hovered select i */ + .burning-question-text + span:hover+ i, /* when space after link is hovered select i */ + .burning-question-text + span + i:hover { /* when icon is hovered select i */ + visibility: visible; + } + .burning-question-text +span+ i { /* in all other case hide it */ + visibility: hidden; + } @@ -124,6 +134,18 @@ {name:'isUserAuthor', width:0, hidden: true}, {name:'groupName', index:'groupName', width:100}, {name:'burningQuestion', index:'burningQuestion', width:501, edittype: 'textarea', editoptions:{rows:"5"}, + formatter:function(cellvalue, options, rowObject) { + var item = $(this).jqGrid("getLocalRow", options.rowId); + + //when item is editable - show pencil icon on hover + return ${isUserLeader} && eval(item.isUserAuthor) ? + "" +cellvalue + " " + : cellvalue; + }, + unformat:function(cellvalue, options, rowObject) { + var text = $('
' + cellvalue + '
').text(); + return text.trim(); + }, editable: function (options) { var item = $(this).jqGrid("getLocalRow", options.rowid); return ${isUserLeader} && eval(item.isUserAuthor); @@ -136,7 +158,7 @@ }, {name:'count', index:'count', width:50, align:"right"} ], - caption: "${scratchieItem.title}", + caption: "${scratchieItem.title}""${scratchieItem.title}", cellurl: '?sessionId=${toolSessionID}&itemUid=${scratchieItem.uid}', cellEdit: true, beforeSubmitCell : function (rowid,name,val,iRow,iCol){