/** * Kendo UI v2016.1.112 (http://www.telerik.com/kendo-ui) * Copyright 2016 Telerik AD. All rights reserved. * * Kendo UI commercial licenses may be obtained at * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete * If you do not own a commercial license, this file shall be governed by the trial license terms. */ !function(e,define){define("kendo.filtercell.min",["kendo.autocomplete.min","kendo.datepicker.min","kendo.numerictextbox.min","kendo.combobox.min","kendo.dropdownlist.min"],e)}(function(){return function(e,t){function r(t){var r="string"==typeof t?t:t.operator;return e.inArray(r,v)>-1}function a(t,r){var o,n,l=[];if(e.isPlainObject(t))if(t.hasOwnProperty("filters"))l=t.filters;else if(t.field==r)return t;for(e.isArray(t)&&(l=t),o=0;l.length>o;o++)if(n=a(l[o],r))return n}function o(t,r){t.filters&&(t.filters=e.grep(t.filters,function(e){return o(e,r),e.filters?e.filters.length:e.field!=r}))}function n(e,t){var r=l.getter(t,!0);return function(t){for(var a,o,n=e(t),l=[],i=0,s={};n.length>i;)a=n[i++],o=r(a),s.hasOwnProperty(o)||(l.push(a),s[o]=!0);return l}}var l=window.kendo,i=l.ui,s=l.data.DataSource,u=i.Widget,p="change",d="boolean",c="enums",f="string",g="Is equal to",h="Is not equal to",m=e.proxy,v=["isnull","isnotnull","isempty","isnotempty"],w=u.extend({init:function(a,o){var n,i,s,g,h,v,w,y,b,I,S,D;if(a=e(a).addClass("k-filtercell"),n=this.wrapper=e("").appendTo(a),i=this,h=o,y=i.operators=o.operators||{},b=i.input=e("").attr(l.attr("bind"),"value: value").appendTo(n),u.fn.init.call(i,a[0],o),o=i.options,s=i.dataSource=o.dataSource,i.model=s.reader.model,w=o.type=f,I=l.getter("reader.model.fields",!0)(s)||{},S=I[o.field],S&&S.type&&(w=o.type=S.type),o.values&&(o.type=w=c),y=y[w]||o.operators[w],!h.operator)for(v in y){o.operator=v;break}i._parse=function(e){return e+""},i.model&&i.model.fields&&(D=i.model.fields[o.field],D&&D.parse&&(i._parse=m(D.parse,D))),i.viewModel=g=l.observable({operator:o.operator,value:null,operatorVisible:function(){var e=this.get("value");return null!==e&&e!==t&&"undefined"!=e||r(this.get("operator"))&&!i._clearInProgress&&!i.manuallyUpdatingVM}}),g.bind(p,m(i.updateDsFilter,i)),w==f&&i.initSuggestDataSource(o),null!==o.inputWidth&&b.width(o.inputWidth),i._setInputType(o,w),w!=d&&o.showOperators!==!1?i._createOperatorDropDown(y):n.addClass("k-operator-hidden"),i._createClearIcon(),l.bind(this.wrapper,g),w==f&&(o.template||i.setAutoCompleteSource()),w==c&&i.setComboBoxSource(i.options.values),i._refreshUI(),i._refreshHandler=m(i._refreshUI,i),i.dataSource.bind(p,i._refreshHandler)},_setInputType:function(t,r){var a,o,n,i,s,u=this,p=u.input;"function"==typeof t.template?(t.template.call(u.viewModel,{element:u.input,dataSource:u.suggestDataSource}),u._angularItems("compile")):r==f?p.attr(l.attr("role"),"autocomplete").attr(l.attr("text-field"),t.dataTextField||t.field).attr(l.attr("filter"),t.suggestionOperator).attr(l.attr("delay"),t.delay).attr(l.attr("min-length"),t.minLength).attr(l.attr("value-primitive"),!0):"date"==r?p.attr(l.attr("role"),"datepicker"):r==d?(p.remove(),a=e(""),o=u.wrapper,n=l.guid(),i=e("