Skip to content

Commit

Permalink
[Admin] Translations - properly escape key on roweditor
Browse files Browse the repository at this point in the history
  • Loading branch information
dvesh3 committed Aug 22, 2022
1 parent e109dfe commit 2fd4685
Showing 1 changed file with 5 additions and 2 deletions.
Expand Up @@ -247,7 +247,10 @@ pimcore.settings.translation.domain = Class.create({
];

var typesColumns = [
{text: t("key"), sortable: true, dataIndex: 'key', flex: 1, editable: false, filter: 'string'},
{text: t("key"), sortable: true, dataIndex: 'key', flex: 1, editable: false, filter: 'string',
editor: new Ext.form.DisplayField({
htmlEncode: true
})},
{text: t("type"), sortable: true, dataIndex: 'type', width: 100, editor: new Ext.form.ComboBox({
triggerAction: 'all',
editable: false,
Expand Down Expand Up @@ -315,7 +318,7 @@ pimcore.settings.translation.domain = Class.create({
icon: "/bundles/pimcoreadmin/img/flat-color-icons/delete.svg",
handler: function (grid, rowIndex) {
let data = grid.getStore().getAt(rowIndex);
pimcore.helpers.deleteConfirm(t('translation'), data.data.key, function () {
pimcore.helpers.deleteConfirm(t('translation'), Ext.util.Format.htmlEncode(data.data.key), function () {
grid.getStore().removeAt(rowIndex);
}.bind(this));
}.bind(this)
Expand Down

0 comments on commit 2fd4685

Please sign in to comment.