Univention Bugzilla – Attachment 8138 Details for
Bug 41204
HTML code in notification window
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch
41204.patch (text/plain), 5.53 KB, created by
Florian Best
on 2016-10-20 12:24 CEST
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Florian Best
Created:
2016-10-20 12:24 CEST
Size:
5.53 KB
patch
obsolete
>diff --git a/base/univention-system-setup/umc/js/setup.js b/base/univention-system-setup/umc/js/setup.js >index e7334f6..d3f83c9 100644 >--- a/base/univention-system-setup/umc/js/setup.js >+++ b/base/univention-system-setup/umc/js/setup.js >@@ -500,7 +500,11 @@ define([ > var confirmMessage = '<p>' + _('The following changes will be applied to the system:') + '</p><ul style="max-height:200px; overflow:auto;">'; > array.forEach(summaries, function(idesc) { > if (idesc.showConfirm) { >- confirmMessage += '<li>' + entities.encode(idesc.description) + ': ' + entities.encode(idesc.values) + '</li>'; >+ var values = idesc.values; >+ if (!idesc.values_html_escaped) { >+ values = entities.encode(values); >+ } >+ confirmMessage += '<li>' + entities.encode(idesc.description) + ': ' + values + '</li>'; > } > }); > confirmMessage += '</ul><p>' + _('Please confirm to apply these changes to the system. This may take some time.') + '</p>'; >diff --git a/base/univention-system-setup/umc/js/setup/Interfaces.js b/base/univention-system-setup/umc/js/setup/Interfaces.js >index eb75ee0..344a570 100644 >--- a/base/univention-system-setup/umc/js/setup/Interfaces.js >+++ b/base/univention-system-setup/umc/js/setup/Interfaces.js >@@ -34,10 +34,11 @@ define([ > "dojo/_base/array", > "dojo/store/Memory", > "dojo/Stateful", >+ "dojox/html/entities", > "umc/tools", > "umc/modules/setup/types", > "umc/i18n!umc/modules/setup" >-], function(declare, lang, array, Memory, Stateful, tools, types, _) { >+], function(declare, lang, array, Memory, Stateful, entities, tools, types, _) { > > var Device = declare('umc.modules.setup.types.Device', null, { > constructor: function(props, interfaces) { >@@ -113,17 +114,17 @@ define([ > var ip6s = formatIPs(this.ip6); > > if (this.ip4dynamic) { >- back.push(_('Dynamic (DHCP)')); >+ back.push(entities.encode(_('Dynamic (DHCP)'))); > } > if (this.ip6dynamic) { >- back.push(_('Autoconfiguration (SLAAC)')); >+ back.push(entities.encode(_('Autoconfiguration (SLAAC)'))); > } > > if (ip4s.length && !this.ip4dynamic){ >- back.push(_('Static') + ': ' + ip4s.join(', ')); >+ back.push(entities.encode(_('Static') + ': ' + ip4s.join(', '))); > } > if (ip6s.length && !this.ip6dynamic) { >- back.push(_('Static (IPv6)') + ': ' + ip6s.join(', ')); >+ back.push(entities.encode(_('Static (IPv6)') + ': ' + ip6s.join(', '))); > } > > return back.join('<br/>'); >@@ -133,7 +134,7 @@ define([ > if (description) { > return description; > } >- return _('Unconfigured'); >+ return entities.encode(_('Unconfigured')); > } > }); > var Ethernet = declare('umc.modules.setup.interfaces.Ethernet', [Device], {}); >@@ -164,7 +165,7 @@ define([ > if (descr) { > back.push(descr); > } >- back.push(_('Bond slaves') + ': ' + this.bond_slaves.join(', ')); >+ back.push(entities.encode(_('Bond slaves') + ': ' + this.bond_slaves.join(', '))); > > return back.join('<br/>'); > } >@@ -186,7 +187,7 @@ define([ > if (descr) { > back.push(descr); > } >- back.push(_('Bridge ports') + ': ' + this.bridge_ports.join(', ')); >+ back.push(entities.encode(_('Bridge ports') + ': ' + this.bridge_ports.join(', '))); > > return back.join('<br/>'); > } >diff --git a/base/univention-system-setup/umc/js/setup/NetworkPage.js b/base/univention-system-setup/umc/js/setup/NetworkPage.js >index fb97eb9..99ae45e 100644 >--- a/base/univention-system-setup/umc/js/setup/NetworkPage.js >+++ b/base/univention-system-setup/umc/js/setup/NetworkPage.js >@@ -33,6 +33,7 @@ define([ > "dojo/_base/lang", > "dojo/_base/array", > "dojo/aspect", >+ "dojox/html/entities", > "umc/tools", > "umc/widgets/Page", > "umc/widgets/StandbyMixin", >@@ -44,7 +45,7 @@ define([ > "umc/modules/setup/Interfaces", > "umc/i18n!umc/modules/setup", > "umc/modules/setup/InterfaceWizard" >-], function(declare, lang, array, aspect, tools, Page, StandbyMixin, ComboBox, TextBox, MultiInput, Form, InterfaceGrid, Interfaces, _) { >+], function(declare, lang, array, aspect, entities, tools, Page, StandbyMixin, ComboBox, TextBox, MultiInput, Form, InterfaceGrid, Interfaces, _) { > return declare("umc.modules.setup.NetworkPage", [ Page, StandbyMixin ], { > // summary: > // This class renderes a detail page containing subtabs and form elements >@@ -297,6 +298,7 @@ define([ > }, { > variables: ['interfaces'], > description: _('Network interfaces'), >+ values_html_escaped: true, > values: this._getInterfaceSummary(vals.interfaces) > }, { > variables: ['interfaces/primary'], >@@ -337,7 +339,7 @@ define([ > summary += '<li>' + _('Created:') + '<ul>'; > array.forEach(created, function(iface) { > summary += '<li>'; >- summary += iface.name + ' (' + iface.label + '): '; >+ summary += entities.encode(iface.name + ' (' + iface.label + '): '); > summary += iface.getSummary(); > summary += '</li>'; > }); >@@ -347,7 +349,7 @@ define([ > summary += '<li>' + _('Modified:') + '<ul>'; > array.forEach(modified, function(iface) { > summary += '<li>'; >- summary += iface.name + ' (' + iface.label + '): '; >+ summary += entities.encode(iface.name + ' (' + iface.label + '): '); > summary += iface.getSummary(); > summary += '</li>'; > }); >@@ -356,9 +358,9 @@ define([ > if (removed.length) { > summary += '<li>' + _('Removed:') + '<ul>'; > summary += '<li>'; >- summary += array.map(removed, function(iface) { >+ summary += entities.encode(array.map(removed, function(iface) { > return iface.name + ' (' + iface.label + ')'; >- }).join(', '); >+ }).join(', ')); > summary += '</li></ul>'; > } > summary += '</li>';
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 41204
:
7639
| 8138