text: // All material copyright ESRI, All Rights Reserved, unless otherwise specified.
  // See http://js.arcgis.com/3.15/esri/copyright.txt and http://www.arcgis.com/apps/webappbuilder/copyright.txt for details.
  
  //>>built
  require({cache:{"url:jimu/dijit/_filter/EditTable.html":'\x3cdiv\x3e\r\n    \x3cdiv class\x3d"jimu-multiple-set-container"\x3e\r\n      \x3cdiv data-dojo-attach-point\x3d"" class\x3d"items-list-content items-list-header"  \x3e\r\n        \x3cdiv class\x3d"item"\x3e\r\n          \x3cdiv class\x3d"label jimu-ellipsis" title\x3d"${Nls.value}"\x3e${Nls.value}\x3c/div\x3e\r\n          \x3cdiv class\x3d"label jimu-ellipsis" title\x3d"${CommonNls.label}"\x3e${CommonNls.label}\x3c/div\x3e\r\n          \x3cdiv class\x3d"label checkboxHeader jimu-ellipsis" title\x3d"${CommonNls.defaults}"\x3e${CommonNls.defaults}\x3c/div\x3e\r\n          \x3cdiv class\x3d"label lableR jimu-ellipsis" title\x3d"${CommonNls.actions}"\x3e${CommonNls.actions}\x3c/div\x3e\r\n        \x3c/div\x3e\r\n      \x3c/div\x3e\r\n      \x3cdiv data-dojo-attach-point\x3d"listContent" class\x3d"items-list-content" data-dojo-attach-event\x3d"click:_onListContentClicked, dblclick:_onListContentDblClicked"\x3e\r\n      \x3c/div\x3e\r\n    \x3c/div\x3e\r\n  \x3c/div\x3e'}});
  define("dojo/_base/lang dojo/_base/html dojo/Evented dojo/on dojo/keys dojo/dom-attr dojo/_base/declare dijit/_WidgetBase dojo/query dijit/form/ValidationTextBox dijit/form/NumberTextBox dijit/_TemplatedMixin dijit/_WidgetsInTemplateMixin dojo/text!./EditTable.html jimu/utils".split(" "),function(k,d,n,m,p,l,q,r,g,t,u,v,w,x,h){return q([r,v,w,n],{templateString:x,currentItem:null,dataList:[],codedValues:null,isNumberField:!0,tableType:"unique",postMixInProperties:function(){this.inherited(arguments);
  this.CommonNls=window.jimuNls.common;this.Nls=window.jimuNls.filterBuilder},postCreate:function(){this.inherited(arguments);d.addClass(this.domNode,"jimu-filter-mutcheck-list-value-provider");"unique"===this.tableType?(this.inputType="radio",d.addClass(this.listContent,"radio-items-list-content")):this.inputType="checkbox"},_onListContentDblClicked:function(a){this.isSearch=!1;var c=a.target||a.srcElement,b=h.getAncestorDom(c,function(a){return d.hasClass(a,"item")},3);if(b&&(d.hasClass(c,"name")||
  d.hasClass(c,"alias"))&&(!d.hasClass(b,"empty")||!d.hasClass(c,"name"))){this._dijit?(this.editState="active",this.updateInputDivPre=this.updateInputDiv,this._dijitPre=this._dijit):this.editState="negative";a=this._getNodeText(c);var e=decodeURIComponent(d.getAttr(c,"data")),b=d.hasClass(b,"custom");this.placeHolder=d.hasClass(c,"name")&&!this.codedValues?e:a;b?d.hasClass(c,"alias")&&this.placeHolder!==this.customLabel?this.currentLabel=a:this.currentLabel=NaN:this.currentLabel=this.isNumberField&&
  d.hasClass(c,"name")&&!this.codedValues?parseFloat(this.placeHolder):this.placeHolder;l.set(c,"innerHTML","");a="";d.hasClass(c,"name")&&(a='\x3cdiv class\x3d"searchBtn"\x3e\x3cdiv class\x3d"jimu-icon jimu-icon-down-arrow-8"\x3e\x3c/div\x3e\x3c/div\x3e');this.updateInputDiv=d.create("div",{"class":"updateInputDiv",innerHTML:'\x3cdiv class\x3d"inputDiv"\x3e\x3c/div\x3e'+a},c);a=g(".inputDiv",this.updateInputDiv)[0];this.searchBtn=g(".searchBtn",this.updateInputDiv)[0];this.own(m(this.updateInputDiv,
  "dblclick",k.hitch(this,function(a){a.stopPropagation();a.preventDefault()})));e={required:!1,intermediateChanges:!1,value:this.currentLabel};this.codedValues&&d.hasClass(c,"name")&&(e.disabled=!0);this.isNumberField&&d.hasClass(c,"name")?(e.constraints={pattern:"#####0.##########"},this._dijit=new u(e)):(e.trim=!0,this._dijit=new t(e));this._dijit.startup();this._dijit.on("keydown",function(a){(a.keyCode||a.which)===p.ENTER&&this._dijit.emit("blur")}.bind(this));this._dijit.on("blur",k.hitch(this,
  function(){if(this._dijit){var a="Error"!==this._dijit.state?this._dijit.displayedValue:this.currentLabel;this.isNumberField&&d.hasClass(c,"name")&&"Error"===this._dijit.state&&this._dijit.setValue(parseFloat(a));var a=h.sanitizeHTML(a),b=this._dijit.get("value");""!==b&&b?d.hasClass(c,"name")&&(this.placeHolder===this.customValue||"NaN"===this.placeHolder&&""!==this._dijit.displayedValue)&&(b=h.getAncestorDom(this._dijit.domNode,function(a){return d.hasClass(a,"item")},4),d.removeClass(b,"custom"),
  this.emit("editTable_itemChanged")):a=this.placeHolder;this.newLabel=a;setTimeout(k.hitch(this,function(){var a,c;if(this.isSearch||"active"===this.editState)"active"===this.editState&&(b=this.updateInputDivPre.parentNode,c=decodeURIComponent(d.getAttr(b,"data")),d.hasClass(b,"name")?this.currentValLabel=""===this._dijitPre.displayedValue?c===this.customValue?this.customValue:this.isNumberField?this._getLocalNumber(c):c:this.isNumberField?this._getLocalNumber(this._dijitPre.value):this._dijitPre.value:
  this.currentValLabel=""===this._dijitPre.displayedValue?c===this.customLabel?this.customLabel:c:this._dijitPre.displayedValue,!d.hasClass(b,"name")||"NaN"===this.newLabel||this.newLabel===this.customValue||this._getNodeText(b.nextSibling)!==this.customLabel&&this._dijit.value!==this.customLabel||(d.isDescendant(this.updateInputDiv,b.nextSibling)?this._dijit.set("value",this.currentValLabel):(a=this.isNumberField?this.currentValLabel:this.newLabel,d.setAttr(b.nextSibling,"data",encodeURIComponent(a)),
  this._setNodeText(b.nextSibling,a),d.setAttr(b.nextSibling,"title",a))),a=d.hasClass(b,"name")?""===this._dijitPre.displayedValue?c===this.customValue?this.customValue:c:this._dijitPre.value:this.newLabel,d.setAttr(b,"data",encodeURIComponent(a)),a=d.hasClass(b,"name")?this.currentValLabel:this.newLabel,this._setNodeText(b,a),d.setAttr(b,"title",a),this._dijitPre=this.updateInputDivPre=null,this.editState="negative");else{var b=this.updateInputDiv.parentNode;c=decodeURIComponent(d.getAttr(b,"data"));
  d.hasClass(b,"name")?this.currentValLabel=""===this._dijit.displayedValue?c===this.customValue?this.customValue:this.isNumberField?this._getLocalNumber(c):c:this.isNumberField?this._getLocalNumber(this._dijit.value):this._dijit.value:this.currentValLabel=""===this._dijit.displayedValue?c===this.customLabel?this.customLabel:c:this._dijit.displayedValue;d.hasClass(b,"name")&&"NaN"!==this.newLabel&&this.newLabel!==this.customValue&&this._getNodeText(b.nextSibling)===this.customLabel&&(a=this.isNumberField?
  this.currentValLabel:this.newLabel,d.setAttr(b.nextSibling,"data",encodeURIComponent(a)),this._setNodeText(b.nextSibling,a),d.setAttr(b.nextSibling,"title",a));a=d.hasClass(b,"name")?""===this._dijit.displayedValue?c===this.customValue?this.customValue:c:this._dijit.value:this.newLabel;d.setAttr(b,"data",encodeURIComponent(a));a=d.hasClass(b,"name")?this.currentValLabel:this.newLabel;this._setNodeText(b,a);d.setAttr(b,"title",a);this._dijit=null;this.isSearch=!1}}),300);this.placeHolder=""}}));d.setStyle(this._dijit.domNode,
  "width","100%");this._dijit.placeAt(a);g("input",this._dijit.domNode)[1].focus();this.searchBtn&&(this.own(m(this.searchBtn,"click",k.hitch(this,function(a){this.isSearch||(this.isSearch=!0,this.searchTarget=a.target||a.srcElement,this.emit("editTable_openListSelectByName",this.newLabel),a.stopPropagation(),a.preventDefault())}))),this.codedValues&&this.searchBtn.click())}},_getLocalNumber:function(a){"string"===typeof a&&(a=parseFloat(a));this.emit("editTable_getValLabelsArrayForNumber",!0,[a]);
  return this.currentValLabel},_setNewLabel:function(a,c){var b;void 0===a&&void 0===c&&(""!==this._dijit.displayedValue?this.codedValues?(c=this._dijit.displayedValue,a=this._getCodeFromCodevalueLabel(c)):(c=a=this._dijit.value,this.isNumberField&&this.newLabel!==this.customValue&&(c=this._getLocalNumber(a))):(a=c=this.customValue,this.updateInputDiv&&this.updateInputDiv.parentNode&&(b=this.updateInputDiv.parentNode,b=decodeURIComponent(d.getAttr(b,"data")),b!==this.customValue&&(a=this.isNumberField?
  parseFloat(b):b,c=this.codedValues?this._getLabelFromCodevalue(a):this.isNumberField?this._getLocalNumber(a):a))));this.updateInputDiv&&this.updateInputDiv.parentNode&&(b=this.updateInputDiv.parentNode,c!==this.customValue&&this._getNodeText(b.nextSibling)===this.customLabel&&(d.setAttr(b.nextSibling,"data",encodeURIComponent(c)),this._setNodeText(b.nextSibling,c),d.setAttr(b.nextSibling,"title",c)),this.codedValues||(a=a?a:decodeURIComponent(d.getAttr(b,"data"))),d.setAttr(b,"data",encodeURIComponent(a)),
  a=b.parentNode,c!==this.customValue&&d.removeClass(a,"custom"),this._setNodeText(b,c),d.setAttr(b,"title",c));this._dijit=this.updateInputDiv=null},_onListContentClicked:function(a){a=a.target||a.srcElement;var c=h.getAncestorDom(a,function(a){return d.hasClass(a,"item")},3);c&&(d.hasClass(a,"checkboxEmpty")?d.hasClass(a,"checked")?d.removeClass(a,"checked"):d.addClass(a,"checked"):d.hasClass(a,this.inputType)?("radio"===this.inputType&&!0===this.currentItem&&(this.currentItem=this.getCurrentItem()),
  d.hasClass(a,"checked")?"radio"!==this.inputType?d.removeClass(a,"checked"):d.hasClass(this.currentItem,"checked")||d.removeClass(a,"checked"):("radio"===this.inputType&&this.currentItem&&d.removeClass(this.currentItem,"checked"),d.addClass(a,"checked"),this.currentItem=a)):d.hasClass(a,"action")&&(d.hasClass(a,"up")?c.previousElementSibling&&d.place(c,c.previousElementSibling,"before"):d.hasClass(a,"down")?c.nextElementSibling&&d.place(c,c.nextElementSibling,"after"):d.hasClass(a,"delete")&&(d.destroy(c),
  this.emit("editTable_itemChanged"))))},_getLabelFromCodevalue:function(a){for(var c=a,b=0;b<this.codedValues.length;b++){var d=this.codedValues[b];if(d.value===a){c=d.label;break}}return c},_getCodeFromCodevalueLabel:function(a){for(var c=a,b=0;b<this.codedValues.length;b++){var d=this.codedValues[b];if(d.label===a){c=d.value;break}}return c},_createEmptyTarget:function(a){for(var c=this.emptyStr,b=this.emptyLabel?this.emptyLabel:c,e=" checked",f=0;f<a.length;f++)if(a[f].isChecked){e="";break}" checked"===
  e&&(this.currentItem=!0);var f='data\x3d"'+encodeURIComponent(c)+'"',g="",h=this.Nls.emptyValueTips;if(0===a.length||this.enableEmpty)g=" checked";return d.create("div",{"class":"item empty",innerHTML:'\x3cdiv class\x3d"label name jimu-ellipsis" style\x3d"cursor: default;"'+f+"\x3e"+c+'\x3c/div\x3e\x3cdiv class\x3d"label alias jimu-ellipsis-Blanks" data\x3d"'+b+'"\x3e'+b+'\x3c/div\x3e\x3cdiv class\x3d"label '+this.inputType+e+' jimu-ellipsis"\x3e\x3c/div\x3e\x3cdiv class\x3d"label checkbox checkboxEmpty'+
  g+' jimu-ellipsis jimu-flipx" title\x3d"'+h+'"\x3e\x3c/div\x3e'},this.listContent)},_createTarget:function(a,c,b,e,f){var h="item";f&&(a=c=this.customValue,b=this.customLabel,h="item custom");a=a||0===a?a:"";c=c||"";b=b?b:a;e=e?e:"";var k=a;(this.codedValues||this.isNumberField)&&a!==this.Nls.addValuePlaceHolder&&(k=this.codedValues?this._getLabelFromCodevalue(a):c);c=this.isNumberField?a:encodeURIComponent(a);e=d.create("div",{"class":h,innerHTML:'\x3cdiv class\x3d"label name jimu-ellipsis-Blanks" '+
  ('data\x3d"'+c+'"')+"\x3e"+k+'\x3c/div\x3e\x3cdiv class\x3d"label alias jimu-ellipsis-Blanks" data\x3d"'+b+'"\x3e'+b+'\x3c/div\x3e\x3cdiv class\x3d"label '+this.inputType+e+' jimu-ellipsis"\x3e\x3c/div\x3e\x3cdiv class\x3d"actions jimu-float-trailing"\x3e\x3cdiv class\x3d"delete action jimu-float-trailing"\x3e\x3c/div\x3e\x3cdiv class\x3d"down action jimu-float-trailing"\x3e\x3c/div\x3e\x3cdiv class\x3d"up action jimu-float-trailing"\x3e\x3c/div\x3e\x3c/div\x3e'},this.listContent);f&&(f=g(".name",
  e)[0],d.setAttr(f,"title",a),d.setAttr(f.nextSibling,"title",b));return e},_destroyTarget:function(a){for(var c=g(".item .name",this.listContent),b=0;b<c.length;b++){var e=c[b];if(l.get(this._dijit.domNode.parentNode,"innerHTML")===a){d.destroy(e.parentNode);break}}},getCurrentItem:function(){for(var a=g(".item .radio",this.listContent),c=0;c<a.length;c++){var b=a[c];if(d.hasClass(b,"checked"))return b}return null},_getEmptyLabel:function(){var a=g(".label.alias",this.listContent.firstChild)[0],c=
  this._getNodeText(a);a.children.length&&(c="Error"===this._dijit.state?decodeURIComponent(d.getAttr(a,"data")):this._dijit.value);return c=h.sanitizeHTML(c)},_getEmptyStatus:function(){var a=g(".checkboxEmpty",this.listContent.firstChild)[0];return d.hasClass(a,"checked")?!0:!1},_getNodeText:function(a){return a.textContent||a.innerText||""},_setNodeText:function(a,c){a.innerHTML="\x26nbsp;";a.textContent?a.textContent=c:a.innerText=c},getListValues:function(){this.listItemsArray=[];this.listValuesArray=
  [];for(var a=g(".item .name",this.listContent),c="radio"===this.inputType?1:0;c<a.length;c++){var b=a[c],e=h.getAncestorDom(b,function(a){return d.hasClass(a,"item")},3);if(!d.hasClass(e,"custom")){var e=this._getNodeText(b),f=decodeURIComponent(d.getAttr(b,"data"));if(this.isNumberField||this.codedValues)e=f;b.children.length&&(e="Error"===this._dijit.state?f:this._dijit.value,this.codedValues&&(e=this._getCodeFromCodevalueLabel(e),e=void 0!==e?e:f));e=this.isNumberField?parseFloat(e):h.sanitizeHTML(e);
  f=this._getNodeText(b.nextSibling);f===this.customLabel&&(f=e.toString(),this.isNumberField&&(f=this._getLocalNumber(f)));b.nextSibling.children.length&&(f="Error"===this._dijit.state?decodeURIComponent(d.getAttr(b.nextSibling,"data")):this._dijit.value);f=h.sanitizeHTML(f);f={value:e,alias:f,isChecked:!1};this.listItemsArray.push(f);this.listValuesArray.push(e);d.hasClass(b.nextSibling.nextSibling,"checked")&&(f.isChecked=!0)}}a={list:this.listItemsArray,valueList:this.listValuesArray};"radio"===
  this.inputType&&(a.emptyLabel=this._getEmptyLabel(),a.enableEmpty=this._getEmptyStatus());return a},setListValues:function(a,c){l.set(this.listContent,"innerHTML","");"radio"===this.inputType&&this._createEmptyTarget(a);for(var b=0;b<a.length;b++){var e=a[b],f="";e.isChecked&&(f=" checked",this.currentItem=!0);this._createTarget(e.value,c?c[b].label:e.value,e.alias,f)}a=g(".name",this.listContent);for(c=0;c<a.length;c++)b=a[c],d.setAttr(b,"title",this._getNodeText(b)),b=b.nextSibling,d.setAttr(b,
  "title",this._getNodeText(b))},_initTable:function(){},getDijits:function(){return[this.mutiValuesSelect]},destroy:function(){this.inherited(arguments)}})});