comparison app/view/widget/base/TextField.js @ 1144:5ceb0381ae73

Set a regex and required for ortszuordnungstyp field.
author Raimund Renkert <raimund.renkert@intevation.de>
date Fri, 27 May 2016 14:51:12 +0200
parents d6e259e76de6
children bfdc00c24baf
comparison
equal deleted inserted replaced
1142:255d550e74f4 1144:5ceb0381ae73
26 msgTarget: 'none', 26 msgTarget: 'none',
27 maxLength: this.maxLength || 1000, 27 maxLength: this.maxLength || 1000,
28 enforceMaxLength: this.enforceMaxLength || true, 28 enforceMaxLength: this.enforceMaxLength || true,
29 fieldLabel: this.fieldLabel, 29 fieldLabel: this.fieldLabel,
30 labelWidth: this.labelWidth, 30 labelWidth: this.labelWidth,
31 readOnly: this.readOnly || false, 31 readOnly: this.readOnly || false,
32 listeners: this.listeners 32 listeners: this.listeners
33 }, { 33 }, {
34 xtype: 'image', 34 xtype: 'image',
35 name: 'warnImg', 35 name: 'warnImg',
36 src: 'resources/img/dialog-warning.png', 36 src: 'resources/img/dialog-warning.png',
44 width: 14, 44 width: 14,
45 height: 14, 45 height: 14,
46 hidden: true 46 hidden: true
47 }]; 47 }];
48 this.callParent(arguments); 48 this.callParent(arguments);
49 if (this.regex) {
50 Ext.apply(this.down('textfield'), {regex: this.regex});
51 }
52 if (this.allowBlank === false) {
53 Ext.apply(this.down('textfield'), {allowBlank: this.allowBlank});
54 }
49 }, 55 },
50 56
51 showWarnings: function(warnings) { 57 showWarnings: function(warnings) {
52 var img = this.down('image[name=warnImg]'); 58 var img = this.down('image[name=warnImg]');
53 Ext.create('Ext.tip.ToolTip', { 59 Ext.create('Ext.tip.ToolTip', {

http://lada.wald.intevation.org