From b4b1eee57add9e86f388dec0dbe73e36adbf4452 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Mon, 12 May 2014 22:03:38 +0000 Subject: [PATCH] Expand what is accepted as a CSV for multi-select. Fixes Permanent time zone preference does not get saved. --- etemplate/js/et2_core_widget.js | 2 +- etemplate/js/et2_widget_selectbox.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/etemplate/js/et2_core_widget.js b/etemplate/js/et2_core_widget.js index 2eea8090cd..df11e8424d 100644 --- a/etemplate/js/et2_core_widget.js +++ b/etemplate/js/et2_core_widget.js @@ -209,7 +209,7 @@ var et2_widget = ClassWithAttributes.extend( if(this.id) { - this.id = this.id.replace(/\[/g,'[').replace(/]/g,']'); + //this.id = this.id.replace(/\[/g,'[').replace(/]/g,']'); } // Add all attributes hidden in the content arrays to the attributes diff --git a/etemplate/js/et2_widget_selectbox.js b/etemplate/js/et2_widget_selectbox.js index 635ec7b773..ec4ffe4b3c 100644 --- a/etemplate/js/et2_widget_selectbox.js +++ b/etemplate/js/et2_widget_selectbox.js @@ -427,7 +427,7 @@ var et2_selectbox = et2_inputWidget.extend( }, set_value: function(_value) { - if(typeof _value == "string" && this.options.multiple && _value.match(/^[,0-9A-Za-z]+$/) !== null) + if(typeof _value == "string" && this.options.multiple && _value.match(/^[,0-9A-Za-z/-_]+$/) !== null) { _value = _value.split(','); }