Add css to manage row status color
This commit is contained in:
parent
e4a2da6c3d
commit
674bc8e9cb
|
@ -0,0 +1,8 @@
|
|||
.externalDisabledRow {
|
||||
background-color: #CCC ! important;;
|
||||
}
|
||||
|
||||
|
||||
.externalErroredRow {
|
||||
background-color: #F2DEDE ! important;;
|
||||
}
|
|
@ -237,7 +237,7 @@ OCA.External.StatusManager = {
|
|||
// Save default view
|
||||
OCA.External.StatusManager.Utils.storeDefaultFolderIconAndBgcolor(elementList);
|
||||
// Disable row until check status
|
||||
elementList.css('background-color', '#CCC');
|
||||
elementList.addClass('externalDisabledRow');
|
||||
OCA.External.StatusManager.Utils.toggleLink(elementList.find('a.name'), false, false);
|
||||
}
|
||||
}
|
||||
|
@ -361,12 +361,11 @@ OCA.External.StatusManager = {
|
|||
OCA.External.StatusManager.Utils = {
|
||||
|
||||
showIconError: function(folder, clickAction, errorImageUrl) {
|
||||
var bgColor = '#F2DEDE';
|
||||
var imageUrl = "url(" + errorImageUrl + ")";
|
||||
var trFolder = $('#fileList tr[data-file=\"' + OCA.External.StatusManager.Utils.jqSelEscape(folder) + '\"]'); //FileList.findFileEl(OCA.External.StatusManager.Utils.jqSelEscape(folder));
|
||||
this.changeFolderIcon(folder, imageUrl);
|
||||
this.toggleLink(folder, false, clickAction);
|
||||
trFolder.css('background-color', bgColor);
|
||||
trFolder.addClass('externalErroredRow');
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -406,7 +405,7 @@ OCA.External.StatusManager.Utils = {
|
|||
// cant use here FileList.findFileEl(OCA.External.StatusManager.Utils.jqSelEscape(folder)); return incorrect instance of filelist
|
||||
trFolder = $('#fileList tr[data-file=\"' + OCA.External.StatusManager.Utils.jqSelEscape(folder) + '\"]');
|
||||
}
|
||||
trFolder.css('background-color', '');
|
||||
trFolder.removeClass('externalErroredRow').removeClass('externalDisabledRow');
|
||||
tdChilds = trFolder.find("td:first-child div.thumbnail");
|
||||
tdChilds.each(function(){
|
||||
var thisElement = $(this);
|
||||
|
|
|
@ -24,6 +24,7 @@ OCP\User::checkLoggedIn();
|
|||
$tmpl = new OCP\Template('files_external', 'list', '');
|
||||
|
||||
/* Load Status Manager */
|
||||
\OCP\Util::addStyle('files_external', 'external');
|
||||
\OCP\Util::addScript('files_external', 'statusmanager');
|
||||
\OCP\Util::addScript('files_external', 'rollingqueue');
|
||||
|
||||
|
|
Loading…
Reference in New Issue