Skip to content

Commit

Permalink
Fixed issue #17598: Save and close button on label sets list screen n…
Browse files Browse the repository at this point in the history
…ot working as expected (#2061)

Co-authored-by: encuestabizdevgit <devgit@encuesta.biz>
  • Loading branch information
gabrieljenik and encuestabizdevgit committed Sep 30, 2021
1 parent 9e5c6bc commit 274c64f
Show file tree
Hide file tree
Showing 8 changed files with 266 additions and 250 deletions.
10 changes: 7 additions & 3 deletions application/controllers/admin/labels.php
Expand Up @@ -362,7 +362,7 @@ public function process()
$lid = $oLabelSet->lid;
}
if (($action == "modlabelsetanswers" || ($action == "ajaxmodlabelsetanswers")) && Permission::model()->hasGlobalPermission('labelsets', 'update')) {
modlabelsetanswers($lid);
modlabelsetanswers($lid);
}
if ($action == "deletelabelset" && Permission::model()->hasGlobalPermission('labelsets', 'delete')) {
if (LabelSet::model()->deleteLabelSet($lid)) {
Expand All @@ -371,10 +371,14 @@ public function process()
}
}

if (Yii::app()->request->getPost("saveandclose")) {
$this->getController()->redirect(array("admin/labels/sa/view"));
}

if ($lid) {
$this->getController()->redirect(array("admin/labels/sa/view/lid/" . $lid));
$this->getController()->redirect(array("admin/labels/sa/view/lid/" . $lid));
} else {
$this->getController()->redirect(array("admin/labels/sa/view"));
$this->getController()->redirect(array("admin/labels/sa/view"));
}
}

Expand Down
242 changes: 121 additions & 121 deletions assets/packages/adminbasics/build/adminbasics.css
@@ -1,8 +1,4 @@
@charset "UTF-8";
#cpdbatt {
min-height: 100px;
}

/**
* Lime Admin Common CSS File
*
Expand Down Expand Up @@ -4187,6 +4183,123 @@ table.dataTable thead .sorting_desc:after {
padding-right: 0;
}

.jcarousel-wrapper {
margin: 20px auto;
position: relative;
border: 10px solid #fff;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;
-webkit-box-shadow: 0 0 2px #999;
-moz-box-shadow: 0 0 2px #999;
box-shadow: 0 0 2px #999;
}

/** Carousel **/
.jcarousel {
position: relative;
overflow: hidden;
width: 100%;
}

.jcarousel ul {
width: 20000em;
position: relative;
list-style: none;
margin: 0;
padding: 0;
}

.jcarousel li {
width: 200px;
float: left;
border: 1px solid #fff;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}

.jcarousel img {
display: block;
max-width: 100%;
height: auto !important;
}

/** Carousel Controls **/
.jcarousel-control-prev,
.jcarousel-control-next {
position: absolute;
top: 50%;
margin-top: -15px;
width: 30px;
height: 30px;
text-align: center;
background: #4E443C;
color: #fff;
text-decoration: none;
text-shadow: 0 0 1px #000;
font: 24px/27px Arial, sans-serif;
-webkit-border-radius: 30px;
-moz-border-radius: 30px;
border-radius: 30px;
-webkit-box-shadow: 0 0 4px #F0EFE7;
-moz-box-shadow: 0 0 4px #F0EFE7;
box-shadow: 0 0 4px #F0EFE7;
}

.jcarousel-control-prev {
left: 15px;
}

.jcarousel-control-next {
right: 15px;
}

/** Carousel Pagination **/
.jcarousel-pagination {
position: absolute;
bottom: -40px;
left: 50%;
-webkit-transform: translate(-50%, 0);
-ms-transform: translate(-50%, 0);
transform: translate(-50%, 0);
margin: 0;
}

.jcarousel-pagination a {
text-decoration: none;
display: inline-block;
font-size: 11px;
height: 10px;
width: 10px;
line-height: 10px;
background: #fff;
color: #4E443C;
border-radius: 10px;
text-indent: -9999px;
margin-right: 7px;
-webkit-box-shadow: 0 0 2px #4E443C;
-moz-box-shadow: 0 0 2px #4E443C;
box-shadow: 0 0 2px #4E443C;
}

.jcarousel-pagination a.active {
background: #4E443C;
color: #fff;
opacity: 1;
-webkit-box-shadow: 0 0 2px #F0EFE7;
-moz-box-shadow: 0 0 2px #F0EFE7;
box-shadow: 0 0 2px #F0EFE7;
}

.template-miniature {
cursor: pointer;
}

.item.inactive {
display: none;
}

.draggable-container {
min-height: 300px;
}
Expand Down Expand Up @@ -4294,6 +4407,10 @@ div.mappable-attribute-wrapper.paired.ui-state-disabled {
min-height: 100px;
}

#cpdbatt {
min-height: 100px;
}

#selectable .ui-selecting {
background: #8CCE00;
}
Expand Down Expand Up @@ -4374,123 +4491,6 @@ div.mappable-attribute-wrapper.paired.ui-state-disabled {
padding-bottom: 15px;
}

.jcarousel-wrapper {
margin: 20px auto;
position: relative;
border: 10px solid #fff;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;
-webkit-box-shadow: 0 0 2px #999;
-moz-box-shadow: 0 0 2px #999;
box-shadow: 0 0 2px #999;
}

/** Carousel **/
.jcarousel {
position: relative;
overflow: hidden;
width: 100%;
}

.jcarousel ul {
width: 20000em;
position: relative;
list-style: none;
margin: 0;
padding: 0;
}

.jcarousel li {
width: 200px;
float: left;
border: 1px solid #fff;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}

.jcarousel img {
display: block;
max-width: 100%;
height: auto !important;
}

/** Carousel Controls **/
.jcarousel-control-prev,
.jcarousel-control-next {
position: absolute;
top: 50%;
margin-top: -15px;
width: 30px;
height: 30px;
text-align: center;
background: #4E443C;
color: #fff;
text-decoration: none;
text-shadow: 0 0 1px #000;
font: 24px/27px Arial, sans-serif;
-webkit-border-radius: 30px;
-moz-border-radius: 30px;
border-radius: 30px;
-webkit-box-shadow: 0 0 4px #F0EFE7;
-moz-box-shadow: 0 0 4px #F0EFE7;
box-shadow: 0 0 4px #F0EFE7;
}

.jcarousel-control-prev {
left: 15px;
}

.jcarousel-control-next {
right: 15px;
}

/** Carousel Pagination **/
.jcarousel-pagination {
position: absolute;
bottom: -40px;
left: 50%;
-webkit-transform: translate(-50%, 0);
-ms-transform: translate(-50%, 0);
transform: translate(-50%, 0);
margin: 0;
}

.jcarousel-pagination a {
text-decoration: none;
display: inline-block;
font-size: 11px;
height: 10px;
width: 10px;
line-height: 10px;
background: #fff;
color: #4E443C;
border-radius: 10px;
text-indent: -9999px;
margin-right: 7px;
-webkit-box-shadow: 0 0 2px #4E443C;
-moz-box-shadow: 0 0 2px #4E443C;
box-shadow: 0 0 2px #4E443C;
}

.jcarousel-pagination a.active {
background: #4E443C;
color: #fff;
opacity: 1;
-webkit-box-shadow: 0 0 2px #F0EFE7;
-moz-box-shadow: 0 0 2px #F0EFE7;
box-shadow: 0 0 2px #F0EFE7;
}

.template-miniature {
cursor: pointer;
}

.item.inactive {
display: none;
}

.grid-view .table td.button-column, .grid-view .table th.button-column, .grid-view-ls .table td.button-column, .grid-view-ls .table th.button-column {
white-space: nowrap;
text-align: initial;
Expand Down
9 changes: 8 additions & 1 deletion assets/packages/adminbasics/build/adminbasics.js
Expand Up @@ -30377,7 +30377,14 @@
name: 'saveandclose',
value: '1'
}).appendTo($form);
$form.find('[type="submit"]').first().trigger('click');
var submitButton = $form.find('[type="submit"]').first();

if (submitButton.length) {
submitButton.trigger('click');
} else {
$form.submit();
}

displayLoadingState(this);
return false;
},
Expand Down
2 changes: 1 addition & 1 deletion assets/packages/adminbasics/build/adminbasics.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/packages/adminbasics/build/adminbasics.min.js

Large diffs are not rendered by default.

0 comments on commit 274c64f

Please sign in to comment.