Skip to content

Commit

Permalink
Merge branch 'master' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
olleharstedt committed Jul 17, 2023
2 parents 1e7691e + 0c2c0d9 commit 67c60ec
Show file tree
Hide file tree
Showing 27 changed files with 183 additions and 196 deletions.
2 changes: 1 addition & 1 deletion application/config/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@
$config['buildnumber'] = '';
$config['updatable'] = true;
$config['templateapiversion'] = 3;
$config['assetsversionnumber'] = '30344';
$config['assetsversionnumber'] = '30345';
return $config;
2 changes: 1 addition & 1 deletion application/controllers/FailedEmailController.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function actionIndex(): void
App()->user->setState('pageSize', (int) $pageSize);
}

App()->getClientScript()->registerScriptFile('/application/views/failedEmail/javascript/failedEmail.js', LSYii_ClientScript::POS_BEGIN);
App()->getClientScript()->registerScriptFile(App()->getConfig('adminscripts') . 'failedEmail.js', LSYii_ClientScript::POS_BEGIN);
$failedEmailModel = FailedEmail::model();
$failedEmailModel->setAttributes(App()->getRequest()->getParam('FailedEmail'), false);
$failedEmailModel->setAttribute('surveyid', $surveyId);
Expand Down
1 change: 0 additions & 1 deletion application/extensions/admin/grid/CLSGridView.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ protected function lsAfterAjaxUpdate(): void
$this->afterAjaxUpdate .= $jsCode;
}
$this->afterAjaxUpdate .= 'LS.actionDropdown.create();';
$this->afterAjaxUpdate .= 'if (typeof LS.actionDropdown.create() !== "undefined"){ LS.actionDropdown.create();}';
$this->afterAjaxUpdate .= '}';
} else {
// trigger action_dropdown() as a default although no lsAfterAjaxUpdate param passed.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
LS.actionDropdown = {
DropdownClass: class extends bootstrap.Dropdown {
_getMenuElement() {
_getMenuElement()
{
return this._config.lsMenuElement;
}
},
Expand All @@ -12,39 +13,17 @@ LS.actionDropdown = {
let body = document.querySelector('body');
dropdownElementList.map(function (dropdownToggleEl) {
let dropdownMenu = dropdownToggleEl.nextElementSibling;
new LS.actionDropdown.DropdownClass(dropdownToggleEl, {
lsMenuElement: dropdownMenu,
boundary: body,
popperConfig: {
strategy: 'fixed',
},
});
body.append(dropdownMenu);
});

// when open dropdown, z-index should be set to `ls-sticky-column` element to avoid dropdown overlapping
// &:has(.dropdown-menu.show) is working for chrome but not in other browsers like firefox, so we add has-dropdown class and set z-index there
$('.ls-sticky-column .ls-dropdown-toggle').on('click', function () {
let $stickyColumn = $(this).closest('.ls-sticky-column');
let $dropdownMenu = $stickyColumn.find('.dropdown-menu');

if ($dropdownMenu.hasClass('show')) {
$stickyColumn.addClass('has-dropdown');
} else {
$stickyColumn.removeClass('has-dropdown');
if (dropdownMenu !== null) {
new LS.actionDropdown.DropdownClass(dropdownToggleEl, {
lsMenuElement: dropdownMenu,
boundary: body,
popperConfig: {
strategy: 'fixed',
},
});
body.append(dropdownMenu);
}
});

// when click outside dropdown, `has-dropdown` class should be removed
let menuParentElementList = [].slice.call(
document.querySelectorAll('.dropdown')
);
menuParentElementList.map((element) => {
element.addEventListener('hide.bs.dropdown', function () {
let $stickyColumn = $(this).closest('.ls-sticky-column');
$stickyColumn.removeClass('has-dropdown');
});
});
}
};

Expand Down
4 changes: 2 additions & 2 deletions application/helpers/update/updates/Update_452.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public function up()
if ($emailsmtppassword && !empty($emailsmtppassword['stg_value']) && $emailsmtppassword['stg_value'] !== 'somepassword') {
$decryptedValue = \LSActiveRecord::decryptSingleOld($emailsmtppassword['stg_value']);
$encryptedValue = \LSActiveRecord::encryptSingle($decryptedValue);
$this->db->createCommand()->update('{{settings_global}}', ['stg_value' => $encryptedValue], "stg_name='emailsmtppassword'");
$this->db->createCommand()->update('{{settings_global}}', ['stg_value' => $encryptedValue ?? ''], "stg_name='emailsmtppassword'");
}

// update encryption for bounceaccountpass
Expand All @@ -30,7 +30,7 @@ public function up()
if ($bounceaccountpass && !empty($bounceaccountpass['stg_value']) && $bounceaccountpass['stg_value'] !== 'enteredpassword') {
$decryptedValue = \LSActiveRecord::decryptSingleOld($bounceaccountpass['stg_value']);
$encryptedValue = \LSActiveRecord::encryptSingle($decryptedValue);
$this->db->createCommand()->update('{{settings_global}}', ['stg_value' => $encryptedValue], "stg_name='bounceaccountpass'");
$this->db->createCommand()->update('{{settings_global}}', ['stg_value' => $encryptedValue ?? ''], "stg_name='bounceaccountpass'");
}
}
}
Expand Down
3 changes: 2 additions & 1 deletion application/models/Permissiontemplates.php
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,8 @@ public function getButtons(): string
'enabledCondition' => $permissionSuperAdminRead,
'linkClass' => 'RoleControl--action--openmodal RoleControl--action--permissions',
'linkAttributes' => [
'data-href' => $setPermissionsUrl
'data-href' => $setPermissionsUrl,
'data-modalSize' => 'modal-lg',
]
];

Expand Down
2 changes: 1 addition & 1 deletion application/views/layouts/adminmenu.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<span class="navbar-toggler-icon"></span>
</button>
<a class="navbar-brand" href="<?php echo $this->createUrl("/admin/"); ?>">
<img src="/assets/images/logo-icon-white.png" height="34" class="d-inline-block align-bottom" alt="">
<img src="<?= Yii::app()->baseUrl ?>/assets/images/logo-icon-white.png" height="34" class="d-inline-block align-bottom" alt="">
<?= $sitename ?>
</a>
<!-- Only on xs screens -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,6 @@
",
LSYii_ClientScript::POS_POSTSCRIPT
);
App()->getClientScript()->registerScriptFile('/application/views/surveyAdministration/javascript/text-option-inherit.js', LSYii_ClientScript::POS_END)
App()->getClientScript()->registerScriptFile(App()->getConfig('adminscripts') . 'text-option-inherit.js', LSYii_ClientScript::POS_END)

?>
7 changes: 0 additions & 7 deletions assets/admin_themes/Sea_Green/tables/tables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,6 @@ table {
right : -1px; // Chrome(<109) bug forces us to use -1px because it would show a 1px gap
box-shadow : inset 15px 0 15px -15px rgba(0, 0, 0, 0.05);
}
// this is new feature, and it works only in chrome but not in firefox
&:has(.dropdown-menu.show) {
z-index : $zindex-sticky;
}
&.has-dropdown {
z-index : $zindex-sticky;
}
}
[class^="ri-"], [class*=" ri-"] {
vertical-align: -0.20em;
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
19 changes: 19 additions & 0 deletions docs/release_notes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,25 @@ Thank you to everyone who helped with this new release!

CHANGE LOG
------------------------------------------------------
Changes from 6.1.7 (build 230710) to 6.1.8 (build 230717) July 17, 2023
-Fixed issue #18942: Roles - Permissions Modal is too narrow (#3276) (Gabriel Jenik)
-Fixed issue #18937: Action menu stop work after any action on any user (#3282) (Gabriel Jenik)
-Fixed issue #18929: Cannot edit data notification entries (#3265) (Gabriel Jenik)
-Fixed issue #18927: [security] Export user roles without authorization (#3272) (Gabriel Jenik)
-Fixed issue #18837: Unable to replace record during reimport of VV files (#3275) (Denis Chenu)
-Fixed issue #18368: export_statistics from API yields error (#3244) (Gabriel Jenik)
-Fixed issue #18281: Users in group are not deleted (#2565) (Gabriel Jenik)
#Updated translation: Swedish by c_schmitz, maxzomborszki
#Updated translation: Slovak by jelen1
#Updated translation: Portuguese (Brazil) by c_schmitz, holch, lucaspcs, marcelovincenzi, samarta, Tiller
#Updated translation: Polish by elissa
#Updated translation: Polish (Informal) by elissa
#Updated translation: Japanese by d_inoue, nomoto
#Updated translation: Finnish by Jmantysalo
#Updated translation: Czech by jelen1
#Updated translation: Czech (Informal) by jelen1


Changes from 6.1.6 (build 230703) to 6.1.7 (build 230710) July 10, 2023
-Fixed issue: Auto-translate was broken (Olle Haerstedt)
-Fixed issue #18934: [security] Stored XSS in label set administration (#3271) (Gabriel Jenik)
Expand Down

0 comments on commit 67c60ec

Please sign in to comment.