Skip to content
This repository was archived by the owner on Mar 8, 2021. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions manager/actions/mutate_module.dynamic.php
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ function showParameters(ctrl) {
currentParams = JSON.parse(props);
}

t = '<table width="100%" class="displayparams"><thead><tr><td width="1%"><?php echo $_lang['parameter']; ?></td><td width="99%"><?php echo $_lang['value']; ?></td></tr></thead>';
t = '<table width="100%" class="displayparams"><thead><tr><td><?php echo $_lang['parameter']; ?></td><td><?php echo $_lang['value']; ?></td><td style="text-align:right;"><?php echo $_lang["set_default"]; ?> </td></tr></thead>';

try {
var type, options, found, info, sd;
Expand Down Expand Up @@ -180,7 +180,7 @@ function showParameters(ctrl) {
c = '<input type="text" name="prop_' + key + '" value="' + value + '" size="30" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />';
break;
case 'menu':
c = '<select name="prop_' + key + '" style="width:auto" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
c = '<select name="prop_' + key + '" style="width:100%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
if (currentParams[key] == options) currentParams[key] = ls[0]; // use first list item as default
for (i = 0; i < ls.length; i++) {
c += '<option value="' + ls[i] + '"' + ((ls[i] == value) ? ' selected="selected"' : '') + '>' + ll[i] + '</option>';
Expand All @@ -189,7 +189,7 @@ function showParameters(ctrl) {
break;
case 'list':
if (currentParams[key] == options) currentParams[key] = ls[0]; // use first list item as default
c = '<select name="prop_' + key + '" size="' + ls.length + '" style="width:auto" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
c = '<select name="prop_' + key + '" size="' + ls.length + '" style="width:100%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
for (i = 0; i < ls.length; i++) {
c += '<option value="' + ls[i] + '"' + ((ls[i] == value) ? ' selected="selected"' : '') + '>' + ll[i] + '</option>';
}
Expand All @@ -199,7 +199,7 @@ function showParameters(ctrl) {
// value = typeof ar[3] !== 'undefined' ? (ar[3] + '').replace(/^\s|\s$/, "") : '';
arrValue = value.split(",");
if (currentParams[key] == options) currentParams[key] = ls[0]; // use first list item as default
c = '<select name="prop_' + key + '" size="' + ls.length + '" multiple="multiple" style="width:auto" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
c = '<select name="prop_' + key + '" size="' + ls.length + '" multiple="multiple" style="width:100%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
for (i = 0; i < ls.length; i++) {
if (arrValue.length) {
found = false;
Expand Down Expand Up @@ -233,18 +233,18 @@ function showParameters(ctrl) {
}
break;
case 'textarea':
c = '<textarea name="prop_' + key + '" style="width:80%" rows="4" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">' + value + '</textarea>';
c = '<textarea name="prop_' + key + '" style="width:100%" rows="4" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">' + value + '</textarea>';
break;
default: // string
c = '<input type="text" name="prop_' + key + '" value="' + value + '" style="width:80%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />';
c = '<input type="text" name="prop_' + key + '" value="' + value + '" style="width:100%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />';
break;
}

info = '';
info += desc ? '<br/><small>' + desc + '</small>' : '';
sd = defaultVal != undefined ? ' <ul class="actionButtons" style="position:absolute;right:0px;bottom:6px;min-height:0;"><li><a href="#" class="primary btn-small btnSetDefault" onclick="setDefaultParam(\'' + key + '\',1);return false;"><?php echo $_lang["set_default"]; ?></a></li></ul>' : '';
sd = defaultVal != undefined ? '<ul class="actionButtons" style="float:right;margin-top:12px;"><li><a title="<?php echo $_lang["set_default"]; ?>" href="#" class="btnSetDefault" onclick="setDefaultParam(\'' + key + '\',1);return false;"><i class="fa fa-refresh"></i></a></li></ul>' : '';

t += '<tr><td class="labelCell" bgcolor="#FFFFFF" width="20%"><span class="paramLabel">' + label + '</span><span class="paramDesc">'+ info + '</span></td><td class="inputCell relative" bgcolor="#FFFFFF" width="80%">' + c + sd + '</td></tr>';
t += '<tr><td class="labelCell" bgcolor="#FFFFFF" width="20%"><span class="paramLabel">' + label + '</span><span class="paramDesc">'+ info + '</span></td><td class="inputCell relative" bgcolor="#FFFFFF" width="74%">' + c + '</td><td style="align:center" bgcolor="#FFFFFF" >' + sd + '</td></tr>';
});

t += '</table>';
Expand Down
16 changes: 8 additions & 8 deletions manager/actions/mutate_plugin.dynamic.php
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ function showParameters(ctrl) {
currentParams = JSON.parse(props);
}

t = '<table width="100%" class="displayparams"><thead><tr><td width="1%"><?php echo $_lang['parameter']; ?></td><td width="99%"><?php echo $_lang['value']; ?></td></tr></thead>';
t = '<table width="100%" class="displayparams"><thead><tr><td><?php echo $_lang['parameter']; ?></td><td><?php echo $_lang['value']; ?></td><td style="text-align:right;"><?php echo $_lang["set_default"]; ?> </td></tr></thead>';

try {
var type, options, found, info, sd;
Expand Down Expand Up @@ -166,7 +166,7 @@ function showParameters(ctrl) {
c = '<input type="text" name="prop_' + key + '" value="' + value + '" size="30" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />';
break;
case 'menu':
c = '<select name="prop_' + key + '" style="width:auto" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
c = '<select name="prop_' + key + '" style="width:100%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
if (currentParams[key] == options) currentParams[key] = ls[0]; // use first list item as default
for (i = 0; i < ls.length; i++) {
c += '<option value="' + ls[i] + '"' + ((ls[i] == value) ? ' selected="selected"' : '') + '>' + ll[i] + '</option>';
Expand All @@ -175,7 +175,7 @@ function showParameters(ctrl) {
break;
case 'list':
if (currentParams[key] == options) currentParams[key] = ls[0]; // use first list item as default
c = '<select name="prop_' + key + '" size="' + ls.length + '" style="width:auto" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
c = '<select name="prop_' + key + '" size="' + ls.length + '" style="width:100%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">';
for (i = 0; i < ls.length; i++) {
c += '<option value="' + ls[i] + '"' + ((ls[i] == value) ? ' selected="selected"' : '') + '>' + ll[i] + '</option>';
}
Expand Down Expand Up @@ -209,7 +209,7 @@ function showParameters(ctrl) {
lv = (value + '').split(",");
c = '';
for (i = 0; i < ls.length; i++) {
c += '<label><input type="checkbox" name="prop_' + key + '[]" value="' + ls[i] + '"' + ((contains(lv, ls[i]) == true) ? ' checked="checked"' : '') + ' onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />'+ll[i]+'</label>&nbsp;';
c += '<label><input type="checkbox" name="prop_' + key + '[]" value="' + ls[i] + '"' + ((contains(lv, ls[i]) == true) ? ' checked="checked"' : '') + ' onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />&nbsp;';
}
break;
case 'radio':
Expand All @@ -219,18 +219,18 @@ function showParameters(ctrl) {
}
break;
case 'textarea':
c = '<textarea name="prop_' + key + '" style="width:80%" rows="4" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">' + value + '</textarea>';
c = '<textarea name="prop_' + key + '" style="width:100%" rows="4" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)">' + value + '</textarea>';
break;
default: // string
c = '<input type="text" name="prop_' + key + '" value="' + value + '" style="width:80%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />';
c = '<input type="text" style="width:100%" name="prop_' + key + '" value="' + value + '" style="width:80%" onchange="setParameter(\'' + key + '\',\'' + type + '\',this)" />';
break;
}

info = '';
info += desc ? '<br/><small>' + desc + '</small>' : '';
sd = defaultVal != undefined ? ' <ul class="actionButtons" style="position:absolute;right:0px;bottom:6px;min-height:0;"><li><a href="#" class="primary btn-small btnSetDefault" onclick="setDefaultParam(\'' + key + '\',1);return false;"><?php echo $_lang["set_default"]; ?></a></li></ul>' : '';
sd = defaultVal != undefined ? '<ul class="actionButtons" style="float:right;margin-top:12px;"><li><a title="<?php echo $_lang["set_default"]; ?>" href="#" class="btnSetDefault" onclick="setDefaultParam(\'' + key + '\',1);return false;"><i class="fa fa-refresh"></i></a></li></ul>' : '';

t += '<tr><td class="labelCell" bgcolor="#FFFFFF" width="20%"><span class="paramLabel">' + label + '</span><span class="paramDesc">'+ info + '</span></td><td class="inputCell relative" bgcolor="#FFFFFF" width="80%">' + c + sd + '</td></tr>';
t += '<tr><td class="labelCell" bgcolor="#FFFFFF" width="20%"><span class="paramLabel">' + label + '</span><span class="paramDesc">'+ info + '</span></td><td class="inputCell relative" bgcolor="#FFFFFF" width="74%">' + c + '</td><td style="align:center" bgcolor="#FFFFFF" >' + sd + '</td></tr>';
});

t += '</table>';
Expand Down
17 changes: 13 additions & 4 deletions manager/media/style/MODxRE2/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -2461,6 +2461,7 @@ input#dateto:focus.DatePicker {

/* normalize some td paddings */


#tabTemplate tbody td,
.sectionBody td,
.sectionBody th {
Expand All @@ -2479,19 +2480,26 @@ input#dateto:focus.DatePicker {

.sectionBody .displayparams th,
.sectionBody .displayparams td {
padding: 2px 4px;
padding: 4px 4px;
}

.sectionBody .displayparams thead td,
.sectionBody .permissiongroup thead td {
border-top: none;
}

#displayparams table{
background: #fff;
}
#displayparams table tbody td {
border-bottom: 1px dotted #d3d3d3;
}
.sectionBody .permissiongroup input,
.sectionBody .permissiongroups input {
width: 200px;
}

td#displayparams > table.displayparams {
border: none;
}

/* replace warning red color in tabs */

Expand Down Expand Up @@ -3381,4 +3389,5 @@ table.actionButtons .searchtext {
.userprofiletable {margin-bottom:-20px;}

.btn-small { padding:2px 4px !important; font-size:11px !important; }
.relative { position:relative; }
.relative { position:relative; }