X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=roojs-ui-debug.js;h=bba3a3b169cd1dc5464561a9370e765e55115894;hb=1b4749ce8c37404c24ee65fd3b8555979443fbec;hp=b7d97c0c35a824052edac47b7379d53f9386c78d;hpb=fe518432826fd3fc9b75cf6307144d820c27bfd8;p=roojs1 diff --git a/roojs-ui-debug.js b/roojs-ui-debug.js index b7d97c0c35..bba3a3b169 100644 --- a/roojs-ui-debug.js +++ b/roojs-ui-debug.js @@ -567,6 +567,7 @@ Roo.extend(Roo.data.Store, Roo.util.Observable, { remove : function(record){ var index = this.data.indexOf(record); this.data.removeAt(index); + if(this.pruneModifiedRecords){ this.modified.remove(record); } @@ -1398,7 +1399,7 @@ Roo.extend(Roo.data.MemoryProxy, Roo.data.DataProxy, { params = params || {}; var result; try { - result = reader.readRecords(this.data); + result = reader.readRecords(params.data ? params.data :this.data); }catch(e){ this.fireEvent("loadexception", this, arg, null, e); callback.call(scope, null, arg, false); @@ -2137,24 +2138,31 @@ var myReader = new Roo.data.ArrayReader({ *

 [ [1, 'Bill', 'Gardener'], [2, 'Ben', 'Horticulturalist'] ]
   
- * @cfg {String} id (optional) The subscript within row Array that provides an ID for the Record + * @constructor * Create a new JsonReader * @param {Object} meta Metadata configuration options. - * @param {Object} recordType Either an Array of field definition objects + * @param {Object|Array} recordType Either an Array of field definition objects + * + * @cfg {Array} fields Array of field definition objects + * @cfg {String} id Name of the property within a row object that contains a record identifier value. * as specified to {@link Roo.data.Record#create}, * or an {@link Roo.data.Record} object + * + * * created using {@link Roo.data.Record#create}. */ Roo.data.ArrayReader = function(meta, recordType){ - Roo.data.ArrayReader.superclass.constructor.call(this, meta, recordType); + + + Roo.data.ArrayReader.superclass.constructor.call(this, meta, recordType||meta.fields); }; Roo.extend(Roo.data.ArrayReader, Roo.data.JsonReader, { /** * Create a data block containing Roo.data.Records from an XML document. * @param {Object} o An Array of row objects which represents the dataset. - * @return {Object} data A data block which is used by an Roo.data.Store object as + * @return {Object} A data block which is used by an {@link Roo.data.Store} object as * a cache of Roo.data.Records. */ readRecords : function(o){ @@ -11225,7 +11233,7 @@ Roo.QuickTips = function(){ if(ttp){ showProc = show.defer(tm.showDelay, tm, [{ el: t, - text: ttp, + text: ttp.replace(/\\n/g,'
'), width: et.getAttributeNS(ns, cfg.width), autoHide: et.getAttributeNS(ns, cfg.hide) != "user", title: et.getAttributeNS(ns, cfg.title), @@ -12393,7 +12401,7 @@ Roo.extend(Roo.tree.MultiSelectionModel, Roo.util.Observable, { * @cfg {Boolean} allowDrop false if this node cannot be drop on * @cfg {Boolean} disabled true to start the node disabled * @cfg {String} icon The path to an icon for the node. The preferred way to do this - * is to use the cls or iconCls attributes and add the icon via a CSS background image. + * is to use the cls or iconCls attributes and add the icon via a CSS background image. * @cfg {String} cls A css class to be added to the node * @cfg {String} iconCls A css class to be added to the nodes icon element for applying css background images * @cfg {String} href URL of the link used for the node (defaults to #) @@ -13560,7 +13568,9 @@ Roo.extend(Roo.tree.RootTreeNodeUI, Roo.tree.TreeNodeUI, { myTreeLoader.on("beforeload", function(treeLoader, node) { this.baseParams.category = node.attributes.category; }, this); -< + + + * * This would pass an HTTP parameter called "category" to the server containing * the value of the Node's "category" attribute. * @constructor @@ -16531,6 +16541,7 @@ side Add an error icon to the right of the field with a popup on hover */ reset : function(){ this.setValue(this.resetValue); + this.originalValue = this.getValue(); this.clearInvalid(); }, @@ -19227,6 +19238,7 @@ Roo.extend(Roo.form.ComboBox, Roo.form.TriggerField, { reset : function(){ // overridden so that last data is reset.. this.setValue(this.resetValue); + this.originalValue = this.getValue(); this.clearInvalid(); this.lastData = false; if (this.view) { @@ -20486,7 +20498,7 @@ Roo.extend(Roo.HtmlEditorCore, Roo.Component, { black: false, white: false, - + bodyCls : '', /** * Protected method that will not generally be called directly. It @@ -21408,7 +21420,7 @@ Roo.extend(Roo.HtmlEditorCore, Roo.Component, { if (v.match(/^\./) || v.match(/^\//)) { return; } - if (v.match(/^(http|https):\/\//) || v.match(/^mailto:/)) { + if (v.match(/^(http|https):\/\//) || v.match(/^mailto:/) || v.match(/^ftp:/)) { return; } if (v.match(/^#/)) { @@ -24348,6 +24360,11 @@ Roo.extend(Roo.form.BasicForm, Roo.util.Observable, { * @type Mixed */ waitMsgTarget : false, + + /** + * @type Boolean + */ + disableMask : false, // private initEl : function(el){ @@ -24503,15 +24520,17 @@ clientValidation Boolean Applies to submit only. Pass true to call fo beforeAction : function(action){ var o = action.options; - - if(this.waitMsgTarget === true){ - this.el.mask(o.waitMsg || "Sending", 'x-mask-loading'); - }else if(this.waitMsgTarget){ - this.waitMsgTarget = Roo.get(this.waitMsgTarget); - this.waitMsgTarget.mask(o.waitMsg || "Sending", 'x-mask-loading'); - }else { - Roo.MessageBox.wait(o.waitMsg || "Sending", o.waitTitle || this.waitTitle || 'Please Wait...'); + if(!this.disableMask) { + if(this.waitMsgTarget === true){ + this.el.mask(o.waitMsg || "Sending", 'x-mask-loading'); + }else if(this.waitMsgTarget){ + this.waitMsgTarget = Roo.get(this.waitMsgTarget); + this.waitMsgTarget.mask(o.waitMsg || "Sending", 'x-mask-loading'); + }else { + Roo.MessageBox.wait(o.waitMsg || "Sending", o.waitTitle || this.waitTitle || 'Please Wait...'); + } } + }, @@ -24520,15 +24539,17 @@ clientValidation Boolean Applies to submit only. Pass true to call fo this.activeAction = null; var o = action.options; - if(this.waitMsgTarget === true){ - this.el.unmask(); - }else if(this.waitMsgTarget){ - this.waitMsgTarget.unmask(); - }else{ - Roo.MessageBox.updateProgress(1); - Roo.MessageBox.hide(); + if(!this.disableMask) { + if(this.waitMsgTarget === true){ + this.el.unmask(); + }else if(this.waitMsgTarget){ + this.waitMsgTarget.unmask(); + }else{ + Roo.MessageBox.updateProgress(1); + Roo.MessageBox.hide(); + } } - + if(success){ if(o.reset){ this.reset(); @@ -24998,7 +25019,13 @@ Roo.extend(Roo.form.Form, Roo.form.BasicForm, { */ progressUrl : false, - + /** + * @cfg {boolean|FormData} formData - true to use new 'FormData' post, or set to a new FormData({dom form}) Object, if + * sending a formdata with extra parameters - eg uploaded elements. + */ + + formData : false, + /** * Opens a new {@link Roo.form.Column} container in the layout stack. If fields are passed after the config, the * fields are added and the column is closed. If no fields are passed the column remains open @@ -25554,7 +25581,8 @@ Roo.extend(Roo.form.Action.Submit, Roo.form.Action, { url:this.getUrl(!isPost), method: method, params:isPost ? this.getParams() : null, - isUpload: this.form.fileUpload + isUpload: this.form.fileUpload, + formData : this.form.formData })); this.uploadProgress(); @@ -30900,8 +30928,7 @@ Roo.ContentPanel = function(el, config, content){ * @param {Roo.ContentPanel} this */ "render" : true - - + }); @@ -31077,7 +31104,7 @@ panel.load({ } if(this.footer){ var te = this.footer.getEl(); - Roo.log("footer:" + te.getHeight()); + //Roo.log("footer:" + te.getHeight()); height -= te.getHeight(); te.setWidth(width); @@ -34778,6 +34805,9 @@ Roo.extend(Roo.grid.ColumnModel, Roo.util.Observable, { /** * @cfg {String} align (Optional) Set the CSS text-align property of the column. Defaults to undefined. */ + /** + * @cfg {String} valign (Optional) Set the CSS vertical-align property of the column (eg. middle, top, bottom etc). Defaults to undefined. + */ /** * @cfg {String} cursor (Optional) */