/*
 Copyright 2009-2015 Luc Saffre
 License: BSD (see file COPYING for details)
*/

// lino.js --- generated Sun Apr 30 19:45:56 2017 by Lino Vilma 2017.4.0 for Administraator.
Ext.BLANK_IMAGE_URL = '/static/ext-3.3.1/resources/images/default/s.gif';
LANGUAGE_CHOICES = [ [ "en", "inglise" ], [ "et", "eesti" ] ];
MEDIA_URL = "/media/";

// hack to add a toCamel function, inspired by
// http://jamesroberts.name/blog/2010/02/22/string-functions-for-javascript-trim-to-camel-case-to-dashed-and-to-underscore/
String.prototype.toCamel = function(){
  //~ return this.replace(/(\-[a-z])/g, function($1){return $1.toUpperCase().replace('-','');});
  //~ return this;
  return this.replace(/([A-Z])([A-Z]+)/g, function(match,p1,p2,offset,string){
      //~ console.log("20131005 got ",arguments);
      return p1 + p2.toLowerCase();});
};


// 20151126 hack to modify Ext.EventObjectImpl.isSpecialKey() which
// returned false for Ctrl-S when called from a keyup handler (namely
// ComboBox.onLoad)

Ext.EventObjectImpl.prototype.isSpecialKey = function(){
    // same as original except for one line
    var k = this.normalizeKey(this.keyCode);
    // return (this.type == 'keypress' && this.ctrlKey) ||
    return (this.ctrlKey) ||
        this.isNavKeyPress() ||
        (k == this.BACKSPACE) || 
        (k >= 16 && k <= 20) || 
        (k >= 44 && k <= 46);   
};





/* MonthPickerPlugin: thanks to keypoint @ sencha forum
   http://www.sencha.com/forum/showthread.php?74002-3.x-Ext.ux.MonthMenu&p=356860#post356860
*/
Ext.namespace('Ext.ux'); 

Ext.ux.MonthPickerPlugin = function() { 
    var picker; 
    var oldDateDefaults; 

    this.init = function(pk) { 
        picker = pk; 
        picker.onTriggerClick = picker.onTriggerClick.createSequence(onClick); 
        picker.getValue = picker.getValue.createInterceptor(setDefaultMonthDay).createSequence(restoreDefaultMonthDay); 
        picker.beforeBlur = picker.beforeBlur.createInterceptor(setDefaultMonthDay).createSequence(restoreDefaultMonthDay); 
    }; 

    function setDefaultMonthDay() { 
        oldDateDefaults = Date.defaults.d; 
        Date.defaults.d = 1; 
        return true; 
    } 

    function restoreDefaultMonthDay(ret) { 
        Date.defaults.d = oldDateDefaults; 
        return ret; 
    } 

    function onClick(e, el, opt) { 
        var p = picker.menu.picker; 
        p.activeDate = p.activeDate.getFirstDateOfMonth(); 
        if (p.value) { 
            p.value = p.value.getFirstDateOfMonth(); 
        } 

        p.showMonthPicker(); 
         
        if (!p.disabled) { 
            p.monthPicker.stopFx(); 
            p.monthPicker.show(); 

            p.mun(p.monthPicker, 'click', p.onMonthClick, p); 
            p.mun(p.monthPicker, 'dblclick', p.onMonthDblClick, p); 
            p.onMonthClick = p.onMonthClick.createSequence(pickerClick); 
            p.onMonthDblClick = p.onMonthDblClick.createSequence(pickerDblclick); 
            p.mon(p.monthPicker, 'click', p.onMonthClick, p); 
            p.mon(p.monthPicker, 'dblclick', p.onMonthDblClick, p); 
        } 
    } 

    function pickerClick(e, t) { 
        var el = new Ext.Element(t); 
        if (el.is('button.x-date-mp-cancel')) { 
            picker.menu.hide(); 
        } else if(el.is('button.x-date-mp-ok')) { 
            var p = picker.menu.picker; 
            p.setValue(p.activeDate); 
            p.fireEvent('select', p, p.value); 
        } 
    } 

    function pickerDblclick(e, t) { 
        var el = new Ext.Element(t); 
        if (el.parent() 
            && (el.parent().is('td.x-date-mp-month') 
            || el.parent().is('td.x-date-mp-year'))) { 

            var p = picker.menu.picker; 
            p.setValue(p.activeDate); 
            p.fireEvent('select', p, p.value); 
        } 
    } 
}; 

Ext.preg('monthPickerPlugin', Ext.ux.MonthPickerPlugin);  


/**
JC Watsons solution (adapted to ExtJS 3.3.1 by LS) is elegant and simple:
`A "fix" for unchecked checkbox submission  behaviour
<http://www.sencha.com/forum/showthread.php?28449>`_

Added special handling for checkbox inputs. 
ExtJS defines disabled checkboxes `readonly`, not `disabled` as for other inputs.

*/
Ext.lib.Ajax.serializeForm = function(form) {
    //~ console.log('20120203 linolib.js serializeForm',form);
    var fElements = form.elements || (document.forms[form] || Ext.getDom(form)).elements, 
        hasSubmit = false, 
        encoder = encodeURIComponent, 
        name, 
        data = '', 
        type, 
        hasValue;

    Ext.each(fElements, function(element){
        name = element.name;
        type = element.type;

        if (!element.disabled && name && !(type == 'checkbox' && element.readonly)) {
            if (/select-(one|multiple)/i.test(type)) {
                Ext.each(element.options, function(opt){
                    if (opt.selected) {
                        hasValue = opt.hasAttribute ? opt.hasAttribute('value') : opt.getAttributeNode('value').specified;
                        data += String.format("{0}={1}&", encoder(name), encoder(hasValue ? opt.value : opt.text));
                    }
                });
            } else if (!(/file|undefined|reset|button/i.test(type))) {
                //~ if (!(/radio|checkbox/i.test(type) && !element.checked) && !(type == 'submit' && hasSubmit)) {
                if (!(type == 'submit' && hasSubmit)) {
                    if (type == 'checkbox') {
                        //~ console.log('20111001',element,'data += ',encoder(name) + '=' + (element.checked ? 'on' : 'off') + '&');
                        data += encoder(name) + '=' + (element.checked ? 'on' : 'off') + '&';
                    } else {
                        //~ console.log('20111001',element,'data += ',encoder(name) + '=' + encoder(element.value) + '&');
                        data += encoder(name) + '=' + encoder(element.value) + '&';
                    }
                    hasSubmit = /submit/i.test(type);
                }
            }
        //~ } else {
            //~ console.log(name,type,element.readonly);
        }
    });
    return data.substr(0, data.length - 1);
};



/*
Set a long timeout of fifteen minutes. 
See /blog/2012/0307
*/
Ext.Ajax.timeout = 15 * 60 * 1000; 

/*
 * Thanks to 
 * `huuze <http://stackoverflow.com/users/10040/huuuze>`_ for the question
 * and to 
 * `chrisv <http://stackoverflow.com/users/683808/chrisv>`_
 * for the answer on
 * http://stackoverflow.com/questions/3764589/how-do-i-include-django-1-2s-csrf-token-in-a-javascript-generated-html-form/5485616#5485616
 * 
 * */
 
Ext.Ajax.on('beforerequest', function (conn, options) {
   if (!(/^http:.*/.test(options.url) || /^https:.*/.test(options.url))) {
     if (typeof(options.headers) == "undefined") {
       options.headers = {'X-CSRFToken': Ext.util.Cookies.get('csrftoken')};
     } else {
       options.headers.extend({'X-CSRFToken': Ext.util.Cookies.get('csrftoken')});
     }                        
   }
}, this);


/*
My fix for the "Cannot set QuickTips dismissDelay to 0" bug,
see http://www.sencha.com/forum/showthread.php?183515 
*/
Ext.override(Ext.QuickTip,{
  showAt : function(xy){
        var t = this.activeTarget;
        //~ console.log("20120224 QuickTip.showAt",this.title,this.dismissDelay,t.dismissDelay);
        if(t){
            if(!this.rendered){
                this.render(Ext.getBody());
                this.activeTarget = t;
            }
            if(t.width){
                this.setWidth(t.width);
                this.body.setWidth(this.adjustBodyWidth(t.width - this.getFrameWidth()));
                this.measureWidth = false;
            } else{
                this.measureWidth = true;
            }
            this.setTitle(t.title || '');
            this.body.update(t.text);
            this.autoHide = t.autoHide;
            // bugfix by Luc 20120226
            if (t.dismissDelay != undefined) this.dismissDelay = t.dismissDelay;
            //~ this.dismissDelay = t.dismissDelay || this.dismissDelay;
            if(this.lastCls){
                this.el.removeClass(this.lastCls);
                delete this.lastCls;
            }
            if(t.cls){
                this.el.addClass(t.cls);
                this.lastCls = t.cls;
            }
            if(this.anchor){
                this.constrainPosition = false;
            }else if(t.align){ 
                xy = this.el.getAlignToXY(t.el, t.align);
                this.constrainPosition = false;
            }else{
                this.constrainPosition = true;
            }
        }
        Ext.QuickTip.superclass.showAt.call(this, xy);
    }
});

/*
Another hack. See /docs/blog/2012/0228
*/
Ext.Element.addMethods(
    function() {
        var VISIBILITY      = "visibility",
            DISPLAY         = "display",
            HIDDEN          = "hidden",
            NONE            = "none",
            XMASKED         = "x-masked",
            XMASKEDRELATIVE = "x-masked-relative",
            data            = Ext.Element.data;

        return {
            
            mask : function(msg, msgCls) {
                var me  = this,
                    dom = me.dom,
                    dh  = Ext.DomHelper,
                    EXTELMASKMSG = "ext-el-mask-msg",
                    el,
                    mask;
                // removed the following lines. See /docs/blog/2012/0228
                //~ if (!(/^body/i.test(dom.tagName) && me.getStyle('position') == 'static')) {
                    //~ console.log(20120228,dom.tagName,me);
                    //~ me.addClass(XMASKEDRELATIVE); 
                //~ }
                if (el = data(dom, 'maskMsg')) {
                    el.remove();
                }
                if (el = data(dom, 'mask')) {
                    el.remove();
                }

                mask = dh.append(dom, {cls : "ext-el-mask"}, true);
                data(dom, 'mask', mask);

                me.addClass(XMASKED);
                mask.setDisplayed(true);
                
                if (typeof msg == 'string') {
                    var mm = dh.append(dom, {cls : EXTELMASKMSG, cn:{tag:'div'}}, true);
                    data(dom, 'maskMsg', mm);
                    mm.dom.className = msgCls ? EXTELMASKMSG + " " + msgCls : EXTELMASKMSG;
                    mm.dom.firstChild.innerHTML = msg;
                    mm.setDisplayed(true);
                    mm.center(me);
                }
                
                
                if (Ext.isIE && !(Ext.isIE7 && Ext.isStrict) && me.getStyle('height') == 'auto') {
                    mask.setSize(undefined, me.getHeight());
                }
                
                return mask;
            }

            
        };
    }()
);



Ext.namespace('Lino');
    
    

//~ Lino.subst_user_field = new Ext.form.ComboBox({});
//~ Lino.subst_user = null;
Lino.insert_subst_user = function(p){
    //~ console.log('20120714 insert_subst_user',Lino.subst_user,p);
    //~ if (Lino.subst_user_field.getValue()) {
    if (p.su) return;
    if (Lino.subst_user) {
        //~ p.su = Lino.subst_user_field.getValue();
        p.su = Lino.subst_user;
    //~ } else {
        //~ delete p.su;
    }
    //~ console.log('20120714 insert_subst_user -->',Lino.subst_user,p);
}

Lino.login_window = null;

Lino.autorefresh = function() {
  if (Lino.current_window == null) {
      Lino.viewport.refresh();
      Lino.autorefresh.defer(60000);
  }
}

Lino.show_login_window = function(on_login, username, password) {
  // console.log('20121103 show_login_window',arguments);
  //~ var current_window = Lino.current_window;
  if (typeof username != 'string') username = '';
  if (typeof password != 'string') password = '';
  if (Lino.login_window == null) {
    
      function do_login() { 
            Lino.viewport.loadMask.show()
            login_panel.getForm().submit({ 
                method:'POST', 
                waitTitle:'Connecting', 
                waitMsg:'Sending data...',
                success:function(){ 
                  Lino.login_window.hide();
                  Lino.handle_home_button();
                  Lino.viewport.loadMask.hide();
                  if (typeof on_login == 'string') {
                      Lino.load_url(on_login);
                  } 
                },
                failure: function(form,action) { 
                  Lino.on_submit_failure(form, action);
                  Lino.viewport.loadMask.hide()
                }
            }); 
      };
    
      var login_button = new Ext.Button({ 
        text:"Logi sisse",
        formBind: true,	 
        // Function that fires when user clicks the button 
        handler: do_login});
    
      var login_panel = new Ext.FormPanel({ 
        //~ inspired by http://www.sencha.com/learn/a-basic-login/
        autoHeight:true,
        labelWidth:90,
        url:'/auth', 
        frame:true, 
        defaultType:'textfield',
        monitorValid:true,
        items:[{ 
            fieldLabel:"Kasutajanimi", 
            id: 'username',
            name:'username', 
            value: username, 
            autoHeight:true,
            allowBlank:false 
        },{ 
            fieldLabel:"Password", 
            id:'password', 
            name:'password', 
            value: password, 
            inputType:'password', 
            autoHeight:true,
            allowBlank:false 
        }],        
        buttons:[ login_button ]});
        
      Lino.login_window = new Ext.Window({
          layout:'fit',
          defaultButton: 'username',
          width:300,
          title:"Logi sisse", 
          autoHeight:true,
          modal: true,
          closeAction: "hide",
          keys: {
            key: Ext.EventObject.ENTER,
            fn: function() { do_login()}
          },
          items: [login_panel] });
  } else {
      var fld = Lino.login_window.items.first().form.findField('username');
      fld.setValue(username);
      var fld = Lino.login_window.items.first().form.findField('password');
      fld.setValue(password);
  };
  Lino.login_window.show();
};

Lino.logout = function(id,name) {
    Lino.call_ajax_action(
        Lino.viewport, 'GET', 
        '/auth',
        {}, 'logout', undefined, undefined,
        function(){Lino.reload();})
}

Lino.set_subst_user = function(id, name) {
    //~ console.log(20130723,'Lino.set_subst_user',id,name,Lino.current_window,Lino.viewport);
    Lino.subst_user = id;
    if (Lino.current_window) 
        Lino.current_window.main_item.set_base_param("su",id);
    if (Lino.viewport) 
        Lino.permalink_handler(Lino.current_window)();
}



//~ Lino.select_subst_user = function(cmp,rec,value){
    //~ Lino.subst_user=value;
    //~ console.log(20120713,rec);
//~ }
    
Lino.current_window = null;
Lino.window_history = Array();
    
Lino.chars2width = function(cols) {  return cols * 9; }
Lino.rows2height = function(cols) {  return cols * 20; }
Lino.perc2width = function(perc) {  
    // var w = Math.max(document.documentElement.clientWidth, window.innerWidth);
    // console.log("20151226", document, window, w);
    var w = Lino.viewport.getWidth();
    return w * perc / 100; 
}



Lino.MainPanel = {
  is_home_page: false,
  setting_param_values : false,
  config_containing_window : function(wincfg) { }
  ,init_containing_window : function(win) { }
  ,is_loading : function() { 
      if (!this.rendered) return true;
      //~ return (Ext.select('.x-loading-msg').elements.length > 0);
      return true; 
    } 
  ,do_when_clean : function(auto_save,todo) { todo() }
  ,get_master_params : function() {
    var p = {}
    p['mt'] = this.content_type; 
    rec = this.get_current_record()
    if (rec) {
      if (rec.phantom) {
          p['mk'] = undefined; 
      }else{
          p['mk'] = rec.id; 
      }
    } else {
      p['mk'] = undefined;
    }
    //~ console.log('get_master_params returns',p,'using record',rec);
    return p;
  }
  ,get_permalink : function() {
    var p = Ext.apply({}, this.get_base_params());
    delete p.fmt;
    Ext.apply(p, this.get_permalink_params());
    
    if (this.toggle_params_panel_btn) {
        p.sp = this.toggle_params_panel_btn.pressed;
        //~ if (this.toggle_params_panel_btn.pressed == this.params_panel_hidden) {
          //~ p.sp = true;
        //~ }
    }
    
    //~ Lino.insert_subst_user(p);
     //~ p.fmt = 'html';
    //~ console.log('get_permalink',p,this.get_permalink_params());
    if (this.is_home_page)
        //~ var url = '';
        var url = '/';
    else 
        var url = this.get_permalink_url();
    if (p.su == null) 
        delete p.su;
    if (Ext.urlEncode(p)) url = url + "?" + Ext.urlEncode(p);
    return url;
  }
  ,get_record_url : function(record_id) {
      var url = '/api' + this.ls_url
      //~ var url = this.containing_window.config.url_data; // ls_url;
      url += '/' + (record_id === undefined ? this.default_record_id : String(record_id));
      //~ if (record_id !== undefined) url += '/' + String(record_id);
      //~ url += '/' + String(record_id);
      return url;
  }
  ,get_permalink_url : function() {
      return '/api' + this.ls_url;
  }
  ,get_permalink_params : function() {
      //~ return {an:'grid'};
      var p = {};
      if (this.action_name)
          p.an = this.action_name;
      this.add_param_values(p,false)
      return p;
  }
  /*

  Lino.MainPanel.set_status() : the status can have the following keys:

  - param_values : values of parameter fields
  - field_values : values of action parameter fields
  - base_params
  - record_id
  - active_tab
  - data_record
  - show_params_panel
  - current_page

   */
  ,set_status : function(status, requesting_panel) {}
  ,get_status : function() { return {}}
  ,refresh : function() {}
  ,get_base_params : function() {  // Lino.MainPanel
    var p = {};
    Lino.insert_subst_user(p);
    return p;
  }
  ,add_params_panel : function (tbar) {
      if (this.params_panel) {
        //~  20130923b
        //~ this.params_panel.autoHeight = true; // 20130924
        var t = this;
        var update = function() {
            var p = t.params_panel;
            //~ console.log("update", p.getSize().height,p.forceLayout,p.autoHeight);
            var w = t.get_containing_window();
            Lino.do_when_visible(w, function() {
                //~ p.doLayout(true); // doLayout(shallow, force)
                w.doLayout(true); // doLayout(shallow, force)
                //~ t.params_panel.on('afterlayout',update,t,{single:true});
            });
        };
        Lino.do_when_visible(this.params_panel, update);
        this.params_panel.on('show',update);
        this.params_panel.on('hide',update);
        //~ this.params_panel.on('bodyresize',update);
        this.params_panel.on('afterlayout',update);
        //~ this.params_panel.on('afterlayout',update,this,{single:true});
        //~ this.params_panel.on('bodyresize',update,this,{single:true});
        //~ this.params_panel.on('resize',update,this,{single:true});
        //~ this.params_panel.on('render',update,this,{single:true});
        
        // this.params_panel.on('render',
        //~ this.params_panel.on('afterlayout',update,this,{single:true,delay:200});
        //~ this.params_panel.on('bodyresize',update,this,{single:true,delay:200});
        this.toggle_params_panel_btn = new Ext.Button({ scope:this, 
          //~ text: "$_("[parameters]")", // gear
          iconCls: 'x-tbar-database_gear',
          tooltip:"Show or hide the table parameters panel",
          enableToggle: true,
          //~ pressed: ! this.params_panel.hidden,
          pressed: ! this.params_panel_hidden,
          toggleHandler: function(btn,state) { 
            //~ console.log("20120210 add_params_panel",state,this.params_panel);
            if (state) {
                this.params_panel.show();
            } else {
                this.params_panel.hide();
            }
            //~ this.params_panel.on('afterlayout',update,this,{single:true});
            //~ t.get_containing_window().doLayout();
            //~ this.params_panel.on('afterlayout',function() {
                //~ console.log("20130918 afterlayout");
                //~ t.get_containing_window().doLayout(); // doLayout(shallow, force)
            //~ },this,{single:true});
          }
        }); 
        tbar = tbar.concat([this.toggle_params_panel_btn]);
        var refresh = function() {
            if (!t.setting_param_values) {
                t._force_dirty = true; 
                t.refresh();
            }
        }
        Ext.each(this.params_panel.fields,function(f) {
          //~ f.on('valid',function() {t.refresh()});
          if (f instanceof Ext.form.Checkbox) {
              f.on('check',refresh);
          } else if (f instanceof Ext.DatePicker) {
              f.on('select',refresh);
          } else if (f instanceof Ext.form.TriggerField) {
              f.on('select',refresh);
              //~ f.on('change',refresh);
              //~ f.on('valid',refresh);
          } else {
              if (! f.on) 
                  console.log("20121010 no method 'on'",f);
              else
                  f.on('change',refresh);
            }
          });
      }
      return tbar;
  }
  ,add_param_values : function (p,force_dirty) {
    if (this.params_panel) {
      /* 
      * 20120918 add param_values to the request string 
      * *only if the params_form is dirty*.
      * Otherwise Actor.default_params() would never be used.
      *
      * 20121023 But IntegClients.params_default has non-empty default values. 
      * Users must have the possibility to make them empty.
      * 
      * 20130605 : added `force_dirty` parameter because Checkbox fields don't 
      * mark their form as dirty when check is fired.
      * 
      * 20130721 : `force_dirty` not as a parameter but as 
      * `this._force_dirty` because
      * 
      * 20130915 : both _force_dirty and force_dirty parameter are needed.
      * 
      */
      if (force_dirty || this._force_dirty || this.params_panel.form.isDirty()) {
      //~ if (this._force_dirty || this.params_panel.form.isDirty()) {
        p.pv = this.get_param_values();
        //~ console.log("20130923 form is dirty (",force_dirty,this._force_dirty,this.params_panel.form.isDirty(),")");
        //~ console.log("20130923 form is dirty",p);
      }else{
        //~ console.log("20130923 form not dirty:",this.params_panel.form);
        if (this.status_param_values) 
          p.pv = Lino.fields2array(
            this.params_panel.fields,this.status_param_values);
      }
      //~ if (!this.params_panel.form.isDirty()) return;
      //~ p.pv = this.get_param_values();
      //~ console.log("20120203 add_param_values added pv",p.pv,"to",p);
    }
  },
  get_param_values : function() { // similar to get_field_values()
      return Lino.fields2array(this.params_panel.fields);
  },
  set_param_values : function(pv) {
    if (this.params_panel) {
      //~ console.log('20120203 MainPanel.set_param_values', pv);
      this.status_param_values = pv;
      //~ this.params_panel.form.suspendEvents(false);
      this.setting_param_values = true;
      if (pv) { 
          this.params_panel.form.my_loadRecord(pv);
      } else { 
        this.params_panel.form.reset(); 
      }
      this.setting_param_values = false;
      this._force_dirty = false; 
      //~ this.params_panel.form.resumeEvents();
    }
  }
};




Lino.Viewport = Ext.extend(Ext.Viewport, Lino.MainPanel);
Lino.Viewport = Ext.extend(Lino.Viewport, {
  layout : "fit"
  ,is_home_page : true
  ,initComponent : function(){
    Lino.Viewport.superclass.initComponent.call(this);
    this.on('render',function(){
      this.loadMask = new Ext.LoadMask(this.el,{msg:"Oota palun..."});
      //~ console.log("20121118 Lino.viewport.loadMask",this.loadMask);
    },this);
  }
  ,refresh : function() {
      var caller = this;
      // console.log("20140829 Lino.Viewport.refresh()");
      if (caller.loadMask) caller.loadMask.show();
      var success = function(response) {
        if (caller.loadMask) caller.loadMask.hide();
        if (response.responseText) {
          var result = Ext.decode(response.responseText);
          //~ console.log('Lino.do_action()',action.name,'result is',result);
          if (result.html) {
              var cmp = Ext.getCmp('dashboard');
              // cmp.removeAll(true);  // 20140829
              cmp.update(result.html, true);
          }
          if (result.message) {
              if (result.alert) {
                  //~ Ext.MessageBox.alert('Alert',result.alert_msg);
                  Ext.MessageBox.alert('Alert',result.message);
              } else {
                  Lino.notify(result.message);
              }
          }
          
          if (result.notify_msg) Lino.notify(result.notify_msg);
          if (result.js_code) { 
            var jsr = result.js_code(caller);
            //~ console.log('Lino.do_action()',action,'returned from js_code in',result);
          };
        }
      };
      var action = {
        url : '/api/main_html',
        waitMsg: "Oota palun...",
        failure: Lino.ajax_error_handler(caller),
        success: success,
        method: 'GET',
        params: {}
      };
      Lino.insert_subst_user(action.params);
      Ext.Ajax.request(action);
    
  }
});




Lino.open_window = function(win, st, requesting_panel) {
  // console.log("20140831 Lino.open_window()", win, win.el.getBox());
  var cw = Lino.current_window;
  if (cw) {
    // console.log("20140829 Lino.open_window() save current status",
    //             cw.main_item.get_status());
    Lino.window_history.push({
      window:cw,
      status:cw.main_item.get_status()
    });
  }
  Lino.current_window = win;
  //~ if (st.su) 
      //~ Lino.subst_user_field.setValue(st.su);
  win.main_item.set_status(st, requesting_panel);
  // win.toFront();
  win.show();
};

Lino.load_url = function(url) {
    //~ foo.bar.baz = 2; 
    //~ console.log("20121120 Lino.load_url()");
    //~ Lino.body_loadMask.show();
    Lino.viewport.loadMask.show();
    //~ location.replace(url);
    document.location = url;
}

Lino.close_window = function(status_update, norestore) {
  // norestore is used when called by handle_action_result() who 
  // will call set_status itself later
  var cw = Lino.current_window;
  var ww = Lino.window_history.pop();
  var retval = cw.main_item.requesting_panel;
  // console.log(
  //     "20150514 Lino.close_window() going to close", cw.title,
  //     "previous is", ww, 
  //     "norestore is", norestore,
  //     "retval is", retval);
  if (ww) {
    //~ if (status_update) Ext.apply(ww.status,status_update);
    if(!norestore) {
        if (status_update) status_update(ww);
        ww.window.main_item.set_status(ww.status , cw.id);
    }
    Lino.current_window = ww.window;
  } else {
      Lino.current_window = null;
      // new since 20140829:
      if(!norestore) { Lino.viewport.refresh(); }
  }
  if (cw) cw.hide_really();
  return retval;
};

Lino.kill_current_window = function() {
  // console.log("20140418 Lino.kill_current_window()");
  var cw = Lino.current_window;
  Lino.current_window = null;
  if (cw) cw.hide_really();
};

Lino.reload = function() {
    // First close all windows to ensure all changes are saved
    Lino.close_all_windows();

    // Then reload current view
    var url =  "/"

    var p = {};
    Lino.insert_subst_user(p)
    if (Ext.urlEncode(p))
        url = url + "?" + Ext.urlEncode(p);

    Lino.load_url(url);
}

Lino.handle_home_button = function() {
  if (Lino.window_history.length == 0)
      Lino.reload();
  else
      Lino.close_all_windows();
}

Lino.close_all_windows = function() {
    while (Lino.window_history.length > 0) {
        Lino.close_window();
    }
}

Lino.calling_window = function() {
    if (Lino.window_history.length) 
        return Lino.window_history[Lino.window_history.length-1];
}

//~ Lino.WindowAction = function(mainItemClass,windowConfig,mainConfig,ppf) {
Lino.WindowAction = function(windowConfig,main_item_fn) {
    //~ if(!mainConfig) mainConfig = {};
    //~ mainConfig.is_main_window = true;
    this.windowConfig = windowConfig;
    this.main_item_fn = main_item_fn;
    //~ if (ppf) mainConfig.params_panel.fields = ppf;
    //~ this.mainConfig = mainConfig;
    //~ this.mainItemClass = mainItemClass;
};

Lino.WindowAction = Ext.extend(Lino.WindowAction,{
    window : null,
    //~ mainItemClass: null,
    get_window : function() {
      //~ if(mainConfig) Ext.apply(this.mainConfig,mainConfig);
      // if (this.window == null || this.window.isDestroyed)  { // 20140829
      // if (this.window == null || this.window.getBox().width == 0)  { // 20140829
      if (this.window == null)  {
      // if (true)  {
          //~ this.windowConfig.main_item = new this.mainItemClass(this.mainConfig);
          this.windowConfig.main_item = this.main_item_fn();
          this.window = new Lino.Window(this.windowConfig);
      }
      return this.window;
    },
    run : function(requesting_panel, status) {
      // console.log('20140829 window_action.run()', this)
      Lino.open_window(this.get_window(), status, requesting_panel);
    }
  
});


Lino.PanelMixin = {
  get_containing_window : function (){
      if (this.containing_window) return this.containing_window;
      return this.containing_panel.get_containing_window();
  }
  ,set_window_title : function(title) {
    //~ this.setTitle(title);
    var cw = this.get_containing_window();

    //~ if (cw) {
    //~ if (cw && cw.closable) {
    if (cw && !cw.main_item.hide_window_title) {
      //~ console.log('20111202 set_window_title(',title,') for',this.containing_window);
      //~ if (! this.containing_window.rendered) console.log("WARNING: not rendered!");
      cw.setTitle(title);
    //~ } else {
      //~ document.title = title;
    }
    //~ else console.log('20111202 not set_window_title(',title,') for',this);
  }
  
};


// Lino.status_bar = new Ext.ux.StatusBar({defaultText:'Lino version 2016.12.0.'});






/* 
  Originally copied from Ext JS Library 3.3.1
  Modifications by Luc Saffre : 
  - rendering of phantom records
  - fire afteredit event
  - react on dblclcik, not on single click

 */
Lino.CheckColumn = Ext.extend(Ext.grid.Column, {

    processEvent : function(name, e, grid, rowIndex, colIndex){
        //~ console.log('20110713 Lino.CheckColumn.processEvent',name)
        if (name == 'click') {
        //~ if (name == 'mousedown') {
        //~ if (name == 'dblclick') {
            return this.toggleValue(grid, rowIndex, colIndex);
        } else {
            return Ext.grid.ActionColumn.superclass.processEvent.apply(this, arguments);
        }
    },
    
    toggleValue : function (grid,rowIndex,colIndex) {
        var record = grid.store.getAt(rowIndex);
        var dataIndex = grid.colModel.getDataIndex(colIndex);
        // 20120514
        //~ if(record.data.disabled_fields && record.data.disabled_fields[dataIndex]) {
          //~ Lino.notify("This field is disabled");
          //~ return false;
        //~ }
      
        //~ if (dataIndex in record.data['disabled_fields']) {
            //~ Lino.notify("This field is disabled.");
            //~ return false;
        //~ }
        var startValue = record.data[dataIndex];
        var value = !startValue;
        //~ record.set(this.dataIndex, value);
        var e = {
            grid: grid,
            record: record,
            field: dataIndex,
            originalValue: startValue,
            value: value,
            row: rowIndex,
            column: colIndex,
            cancel: false
        };
        if(grid.fireEvent("beforeedit", e) !== false && !e.cancel){
        //~ if(grid.fireEvent("validateedit", e) !== false && !e.cancel){
            record.set(dataIndex, value);
            delete e.cancel;
            grid.fireEvent("afteredit", e);
        }
        return false; // Cancel event propagation
    },

    renderer : function(v, p, record){
        if (record.phantom) return '';
        p.css += ' x-grid3-check-col-td'; 
        return String.format('<div class="x-grid3-check-col{0}">&#160;</div>', v ? '-on' : '');
    }

    // Deprecate use as a plugin. Remove in 4.0
    // init: Ext.emptyFn
});

// register ptype. Deprecate. Remove in 4.0
// Ext.preg('checkcolumn', Lino.CheckColumn);

// backwards compat. Remove in 4.0
// Ext.grid.CheckColumn = Lino.CheckColumn;

// register Column xtype
Ext.grid.Column.types.checkcolumn = Lino.CheckColumn;


/* 20110725 : 
Lino.on_tab_activate is necessary 
in contacts.Person.2.dtl 
(but don't ask me why...)
*/
Lino.on_tab_activate = function(item) {
  //~ console.log('activate',item); 
  if (item.rendered && item.doLayout) item.doLayout();
  //~ if (item.rendered) item.doLayout();
}

Lino.TimeField = Ext.extend(Ext.form.TimeField,{
  format: 'H:i',
  increment: 15
  });
Lino.DateField = Ext.extend(Ext.form.DateField,{
  //~ boxMinWidth: Lino.chars2width(15), // 20131005 changed from 11 to 15
  format: 'd.m.Y',
  altFormats: 'd/m/Y|Y-m-d'
  });
Lino.DatePickerField = Ext.extend(Ext.DatePicker,{
  //~ boxMinWidth: Lino.chars2width(11),
  format: 'd.m.Y',
  //~ altFormats: 'd/m/Y|Y-m-d'
  formatDate : function(date){
      //~ console.log("20121203 formatDate",this.name,date);
      return Ext.isDate(date) ? date.dateFormat(this.format) : date;
  }
  });
Lino.DateTimeField = Ext.extend(Ext.ux.form.DateTime,{
  dateFormat: 'd.m.Y',
  timeFormat: 'H:i'
  //~ ,hiddenFormat: 'd.m.Y H:i'
  });
Lino.URLField = Ext.extend(Ext.form.TriggerField,{
  triggerClass : 'x-form-search-trigger',
  //~ triggerClass : 'x-form-world-trigger',
  vtype: 'url',
  onTriggerClick : function() {
    //~ console.log('Lino.URLField.onTriggerClick',this.value)
    //~ document.location = this.value;
    window.open(this.getValue(),'_blank');
  }
});
Lino.IncompleteDateField = Ext.extend(Ext.form.TextField,{
  //~ regex: /^-?\d+-[01]\d-[0123]\d$/,
  //~ regex: /^[0123]\d\.[01]\d\.-?\d+$/,
  maxLength: 10,
  boxMinWidth: Lino.chars2width(10),
  regex: /^[0123]?\d\.[01]?\d\.-?\d+$/,
  regexText: 'Enter a date in format YYYY-MM-DD (use zeroes for unknown parts).'
  });


//~ Lino.make_dropzone = function(cmp) {
    //~ cmp.on('render', function(ct, position){
      //~ ct.el.on({
        //~ dragenter:function(event){
          //~ event.browserEvent.dataTransfer.dropEffect = 'move';
          //~ return true;
        //~ }
        //~ ,dragover:function(event){
          //~ event.browserEvent.dataTransfer.dropEffect = 'move';
          //~ event.stopEvent();
          //~ return true;
        //~ }
        //~ ,drop:{
          //~ scope:this
          //~ ,fn:function(event){
            //~ event.stopEvent();
            //~ console.log(20110516);
            //~ var files = event.browserEvent.dataTransfer.files;
            //~ if(files === undefined){
              //~ return true;
            //~ }
            //~ var len = files.length;
            //~ while(--len >= 0){
              //~ console.log(files[len]);
              //~ // this.processDragAndDropFileUpload(files[len]);
            //~ }
          //~ }
        //~ }
      //~ });
    //~ });
//~ };

//~ Lino.FileUploadField = Ext.ux.form.FileUploadField;

Lino.FileUploadField = Ext.extend(Ext.ux.form.FileUploadField,{
    unused_onRender : function(ct, position){
      Lino.FileUploadField.superclass.onRender.call(this, ct, position);
      this.el.on({
        dragenter:function(event){
          event.browserEvent.dataTransfer.dropEffect = 'move';
          return true;
        }
        ,dragover:function(event){
          event.browserEvent.dataTransfer.dropEffect = 'move';
          event.stopEvent();
          return true;
        }
        ,drop:{
          scope:this
          ,fn:function(event){
            event.stopEvent();
            //~ console.log(20110516);
            var files = event.browserEvent.dataTransfer.files;
            if(files === undefined){
              return true;
            }
            var len = files.length;
            while(--len >= 0){
              console.log(files[len]);
              //~ this.processDragAndDropFileUpload(files[len]);
            }
          }
        }
      });
    }
});

Lino.FileField = Ext.extend(Ext.form.TriggerField,{
  triggerClass : 'x-form-search-trigger',
  editable: false,
  onTriggerClick : function() {
    //~ console.log('Lino.URLField.onTriggerClick',this.value)
    //~ document.location = this.value;
    if (this.getValue()) window.open(MEDIA_URL + '/'+this.getValue(),'_blank');
  }
});

Lino.file_field_handler = function(panel,config) {
  if (panel.action_name == 'insert') {
      panel.has_file_upload = true;


      // config.value = '<br/><br/>';

      var f = new Lino.FileUploadField(config);
      //~ Lino.make_dropzone(f);
      return f;
      //~ return new Ext.ux.form.FileUploadField(config);
      //~ return new Lino.FileField(config);
      
  } else {
      //~ return new Lino.URLField(config);
      return new Lino.FileField(config);
  }
}

Lino.VBorderPanel = Ext.extend(Ext.Panel,{
    constructor : function(config) {
      config.layout = 'border';
      delete config.layoutConfig;
      Lino.VBorderPanel.superclass.constructor.call(this,config);
      for(var i=0; i < this.items.length;i++) {
        var item = this.items.get(i);
        if (this.isVertical(item) && item.collapsible) {
          item.on('collapse',this.onBodyResize,this);
          item.on('expand',this.onBodyResize,this);
        }
      }
    },
    isVertical : function(item) {
       return (item.region == 'north' || item.region == 'south' || item.region == 'center');
    },
    onBodyResize: function(w, h){
        //~ console.log('VBorderPanel.onBodyResize',this.title)
      if (this.isVisible()) { // to avoid "Uncaught TypeError: Cannot call method 'getHeight' of undefined."
        var sumflex = 0;
        var availableHeight = this.getInnerHeight();
        var me = this;
        this.items.each(function(item){
          if (me.isVertical(item)) {
              if (item.collapsed || item.flex == 0 || item.flex === undefined) {
                  if (item.rendered) availableHeight -= item.getHeight();
              } else {
                  sumflex += item.flex;
              }
          } 
          
        });
        //~ for(var i=0; i < this.items.length;i++) {
          //~ var item = this.items.get(i);
          //~ // if (this.isVertical(item) && item.getResizeEl()) {
          //~ if (this.isVertical(item)) {
              //~ if (item.collapsed || item.flex == 0 || item.flex === undefined) {
                  //~ // item.syncSize()
                  //~ // item.doLayout()
                  //~ // if (item.region == "north") console.log('region north',item.getHeight(),item.id, item);
                  //~ // if (item.getHeight() == 0) console.log(20100921,'both flex and getHeight() are 0!');
                  //~ availableHeight -= item.getHeight();
              //~ } else {
                  //~ sumflex += item.flex;
                  //~ // console.log(item.flex);
              //~ }
          //~ } 
          //~ // else console.log('non-vertical item in VBoderPanel:',item)
        //~ }
        var hunit = availableHeight / sumflex;
        //~ console.log('sumflex=',sumflex,'hunit=',hunit, 'availableHeight=',availableHeight);
        for(var i=0; i < this.items.length;i++) {
          var item = this.items.get(i);
          if (this.isVertical(item)) {
              if (item.flex != 0 && ! item.collapsed) {
                  item.setHeight(hunit * item.flex);
                  //~ console.log(item.region,' : height set to',item.getHeight());
              }
          }
          //~ else console.log('non-vertical item in VBoderPanel:',item)
        }
      }
      Lino.VBorderPanel.superclass.onBodyResize.call(this, w, h);
    }
});


/*
  modifications to the standard behaviour of a CellSelectionModel:
  
*/
Ext.override(Ext.grid.CellSelectionModel, {
//~ var dummy = {

    handleKeyDown : function(e){
        /* removed because F2 wouldn't pass
        if(!e.isNavKeyPress()){
            return;
        }
        */
        //~ console.log('handleKeyDown',e)
        var k = e.getKey(),
            g = this.grid,
            s = this.selection,
            sm = this,
            walk = function(row, col, step){
                return g.walkCells(
                    row,
                    col,
                    step,
                    g.isEditor && g.editing ? sm.acceptsNav : sm.isSelectable, 
                    sm
                );
            },
            cell, newCell, r, c, ae;

        switch(k){
            case e.ESC:
            case e.PAGE_UP:
            case e.PAGE_DOWN:
                break;
            default:
                // e.stopEvent(); // removed because Browser keys like Alt-Home, Ctrl-R wouldn't work
                break;
        }

        if(!s){
            cell = walk(0, 0, 1); 
            if(cell){
                this.select(cell[0], cell[1]);
            }
            return;
        }

        cell = s.cell;
        r = cell[0];    
        c = cell[1];    
        
        switch(k){
            case e.TAB:
                if(e.shiftKey){
                    newCell = walk(r, c - 1, -1);
                }else{
                    newCell = walk(r, c + 1, 1);
                }
                break;
            case e.HOME:
                if (! (g.isEditor && g.editing)) {
                  if (!e.hasModifier()){
                      newCell = [r, 0];
                      //~ console.log('home',newCell);
                      break;
                  }else if(e.ctrlKey){
                      var t = g.getTopToolbar();
                      var activePage = Math.ceil((t.cursor + t.pageSize) / t.pageSize);
                      if (activePage > 1) {
                          e.stopEvent();
                          t.moveFirst();
                          return;
                      }
                      newCell = [0, c];
                      break;
                  }
                }
            case e.END:
                if (! (g.isEditor && g.editing)) {
                  c = g.colModel.getColumnCount()-1;
                  if (!e.hasModifier()) {
                      newCell = [r, c];
                      //~ console.log('end',newCell);
                      break;
                  }else if(e.ctrlKey){
                      var t = g.getTopToolbar();
                      var d = t.getPageData();
                      if (d.activePage < d.pages) {
                          e.stopEvent();
                          var self = this;
                          t.on('change',function(tb,pageData) {
                              var r = g.store.getCount()-2;
                              self.select(r, c);
                              //~ console.log('change',r,c);
                          },this,{single:true});
                          t.moveLast();
                          return;
                      } else {
                          newCell = [g.store.getCount()-1, c];
                          //~ console.log('ctrl-end',newCell);
                          break;
                      }
                  }
                }
            case e.DOWN:
                newCell = walk(r + 1, c, 1);
                break;
            case e.UP:
                newCell = walk(r - 1, c, -1);
                break;
            case e.RIGHT:
                newCell = walk(r, c + 1, 1);
                break;
            case e.LEFT:
                newCell = walk(r, c - 1, -1);
                break;
            case e.F2:
                if (!e.hasModifier()) {
                    if (g.isEditor && !g.editing) {
                        g.startEditing(r, c);
                        e.stopEvent();
                        return;
                    }
                    break;
                }
            case e.INSERT:
                if (!e.hasModifier()) {
                    if (g.ls_insert_handler && !g.editing) {
                        e.stopEvent();
                        Lino.show_insert(g);
                        return;
                    }
                    break;
                }
            // case e.DELETE:
            //     if (!e.hasModifier()) {
            //         if (!g.editing) {
            //             e.stopEvent();
            //             Lino.delete_selected(g);
            //             return;
            //         }
            //         break;
            //     }

            case e.ENTER:
                e.stopEvent();
                g.onCellDblClick(r,c);
                break;

            default:
                g.handle_key_event(e);
                
        }
        

        if(newCell){
          e.stopEvent();
          r = newCell[0];
          c = newCell[1];
          this.select(r, c); 
          if(g.isEditor && g.editing){ 
            ae = g.activeEditor;
            if(ae && ae.field.triggerBlur){
                ae.field.triggerBlur();
            }
            g.startEditing(r, c);
          }
        //~ } else if (g.isEditor && !g.editing && e.charCode) {
        //~ // } else if (!e.isSpecialKey() && g.isEditor && !g.editing) {
            //~ g.set_start_value(String.fromCharCode(e.charCode));
            //~ // g.set_start_value(String.fromCharCode(k));
            //~ // g.set_start_value(e.charCode);
            //~ g.startEditing(r, c);
            //~ // e.stopEvent();
            //~ return;
        // } else {
          // console.log('20120513',e,g);
        }
        
    }


//~ };
});

 

function PseudoConsole() {
    this.log = function() {};
};
if (typeof(console) == 'undefined') console = new PseudoConsole();

Lino.notify = function(msg) {
  if (msg == undefined) msg = ''; else console.log(msg);
  
    if (msg == undefined) return;
    // Lino.alert(msg);
  
};

Lino.alert = function(msg) {
  Ext.MessageBox.alert('Notify',msg);
};


//~ Lino.show_about = function() {
  //~ new Ext.Window({
    //~ width: 400, height: 400,
    //~ title: "About",
    //~ html: '<a href="http://www.extjs.com" target="_blank">ExtJS</a> version ' + Ext.version
  //~ }).show();
//~ };

function obj2str(o) {
  if (typeof o != 'object') return String(o);
  var s = '';
  for (var p in o) {
    s += p + ': ' + obj2str(o[p]) + '\n';
  }
  return s;
}

Lino.on_store_exception = function (store,type,action,options,response,arg) {
  //~ throw response;
  console.log("on_store_exception: store=",store,
    "type=",type,
    "action=",action,
    "options=",options,
    "response=",response,
    "arg=",arg);
    if (arg != undefined && arg) { console.log(arg.stack)};
    Ext.Msg.alert("Database problem",
                  "There was a problem with the database connection. If the error persists, try reloading your browser.");
    
};

//~ Lino.on_submit_success = function(form, action) {
   //~ Lino.notify(action.result.message);
   //~ this.close();
//~ };

Lino.on_submit_failure = function(form, action) {
    //~ Lino.notify();
  // action may be undefined
    switch (action.failureType) {
        case Ext.form.Action.CLIENT_INVALID:
            Ext.Msg.alert('Client-side failure', 'Form fields may not be submitted with invalid values');
            break;
        case Ext.form.Action.CONNECT_FAILURE:
            Ext.Msg.alert('Connection failure', 'Ajax communication failed');
            break;
        case Ext.form.Action.SERVER_INVALID:
            Ext.Msg.alert('Server-side failure', action.result.message);
   }
};



/*
Lino.save_wc_handler = function(ww) {
  return function(event,toolEl,panel,tc) {
    var pos = panel.getPosition();
    var size = panel.getSize();
    wc = ww.get_window_config();
    Ext.applyIf(wc,{ 
      x:pos[0],y:pos[1],height:size.height,width:size.width,
      maximized:panel.maximized});
    Lino.do_action(ww,{url:'/window_configs/'+ww.config.permalink_name,params:wc,method:'POST'});
  }
};

*/

Lino.show_in_own_window_button = function(handler) {
  return {
    qtip: "Show this panel in own window", 
    id: "up",
    handler: function(event,toolEl,panel, tc) {
      //~ console.log('20111206 report_window_button',panel,handler);
      handler.run(null,{base_params:panel.containing_panel.get_master_params()});
    }
  }
}

Lino.action_handler = function (panel, on_success, on_confirm) {
  return function (response) {
      if (!panel) { 
          if (Lino.current_window) 
              panel = Lino.current_window.main_item;
          else panel = Lino.viewport;
      }
      
    if (panel.loadMask) panel.loadMask.hide(); // 20120211
    if (!response.responseText) return ;
    var result = Ext.decode(response.responseText);
    Lino.handle_action_result(panel, result, on_success, on_confirm);
  }
};

Lino.handle_action_result = function (panel, result, on_success, on_confirm) {

    // console.log('20150514 Lino.handle_action_result()', result);
    
    // if (panel instanceof Lino.GridPanel) {
    //     gridmode = true;
    // } else {
    //     gridmode = false;
    // }

    //~ if (result.goto_record) {
        //~ var js = "Lino." + result.goto_record[0] + '.detail.run';
        //~ var h = eval(js);
        //~ h(panel,{record_id:result.goto_record[1]});
    //~ }
    
    if (result.xcallback) {
        //~ var config = {title:"Kinnitus"};
        var config = {title:result.xcallback.title};
        //~ config.buttons = Ext.MessageBox.YESNOCANCEL;
        //~ config.buttons = Ext.MessageBox.YESNO;
        var p = {};
        Lino.insert_subst_user(p);
        config.buttons = result.xcallback.buttons;
        config.msg = result.message;
        config.fn = function(buttonId, text, opt) {
          panel.loadMask.show(); 
          //~ Lino.insert_subst_user(p);
          Ext.Ajax.request({
            method: 'GET',
            url: '/callbacks/'
                  + result.xcallback.id + '/' + buttonId,
            params: p,
            failure: Lino.ajax_error_handler(panel),
            success: Lino.action_handler(panel, on_success, on_confirm)
          });
        }
        Ext.MessageBox.show(config);
        return;
    }

    // `record_id` and/or `data_record` both mean "display the detail
    // of this record". 
    
    if(result.detail_handler_name) {
        // TODO: make sure that result.detail_handler_name is secure
        var detail_handler = eval("Lino." + result.detail_handler_name);
    }
    var ns = {};  // new status
    if (result.close_window) {
        
        // Subsequent processing expects that `panel` is "the current
        // panel". But if we close the window, `panel` must point
        // to the previous window. Note the case of an insert window
        // that has been invoked by double-clicking on the phantom row
        // of a slave table in a detail window. In that case we want
        // `panel` to become the grid panel of the slave table who
        // called the insert window, not the master's detail form
        // panel.  When the insert window has been called by an action
        // link (e.g. generated using ar.insert_button), then
        // Lino.close_window can return `undefined`.

        if(result.record_id || result.data_record) {
            var ww = Lino.calling_window();
            if (ww && ww.window.main_item instanceof Lino.FormPanel) {
                if (ww.window.main_item.ls_detail_handler == detail_handler) {
                    ns.record_id = result.record_id;
                    ns.data_record = result.data_record;
                    // console.log("20150514 use new status.");
                }
            }
        }

        panel = Lino.close_window(
            function(ww) { Ext.apply(ww.status, ns) }); 
        if (!panel) 
            // console.log("20150514 close_window returned no panel.");
            if (Lino.current_window)
                panel = Lino.current_window.main_item;

    }

    if(result.record_id || result.data_record) {
        if (! (ns.record_id || ns.data_record)) {
          // no close_window, so we must update record data in current
          // panel (if it is the detail_handler for this record) or
          // open the detail handler.
          var st = {
              record_id: result.record_id,
              data_record: result.data_record
          };
          if (result.active_tab) st.active_tab = result.active_tab;
          if (panel instanceof Lino.FormPanel 
              && panel.ls_detail_handler == detail_handler) 
            {
              // console.log("20150514 use panel.set_status().");
              panel.set_status(st);
          } else {
              // console.log("20150514 run detail_handler.");
              st.base_params = panel.get_base_params();
              detail_handler.run(null, st);
          }

          // if (panel instanceof Lino.FormPanel 
          //     && panel.ls_url == result.actor_url) {
          //     // console.log("20140506 case 2 it's a FormPanel:", panel);
          //     panel.set_status({
          //         record_id: result.record_id,
          //         data_record: result.data_record});
          // } else if (panel.ls_detail_handler 
          //            && panel.ls_url == result.actor_url) {
          //     // console.log("20140506 case 4");
          //     panel.ls_detail_handler.run(null, {
          //         record_id: result.record_id,
          //         data_record: result.data_record,
          //         base_params: panel.get_base_params()});
          // } else {
          //     result.refresh_all = true;
          //     console.log("20140604 case 6", result.actor_url);
          // }
        }
    }

    // `eval_js` must get handled after `close_window` because it
    // might ask to open a new window (and we don't want to close that
    // new window).  It must execute *before* any MessageBox,
    // otherwise the box would get hidden by a window that opens
    // afterwards.

    if (result.eval_js) {
        //~ console.log(20120618,result.eval_js);
        eval(result.eval_js);
    }
    
    if (on_success && result.success) {
        // console.log("20140430 handle_action_result calls on_success", 
        //             on_success);
        on_success(result);
    }
    
    if (result.info_message) {
        console.log(result.info_message);
    }
    
    if (result.warning_message) {
        if (!result.alert) result.alert = "Hoiatus";
        Ext.MessageBox.alert(result.alert, result.warning_message);
    }
    
    if (result.message) {
        //~ if (result.alert && ! gridmode) {
        if (result.alert) { // 20120628b 
            //~ Ext.MessageBox.alert('Alert',result.alert_msg);
            if (result.alert === true) result.alert = "Hoiatus";
            Ext.MessageBox.alert(result.alert, result.message);
        } else {
            Lino.notify(result.message);
        }
    }

    if(result.record_deleted && panel.ls_detail_handler == detail_handler) {
        panel.after_delete();
    }
    
    if (result.refresh_all) {
        var cw = Lino.current_window;
        // var cw = panel.get_containing_window();
        if (cw) {
            // console.log("20140917 refresh_all calls refresh on", cw.main_item);
            cw.main_item.refresh();
        } else { Lino.viewport.refresh(); }
        // else console.log("20140917 cannot refresh_all because ",
        //                  "there is no current_window");
    } else {
        if (result.refresh) {
            // console.log("20140917 Gonna call panel.refresh()", panel);
            panel.refresh();
        }
    }if (result.open_url) {
        //~ console.log(20111126,result.open_url);
        //~ if (!result.message)
            //~ Lino.notify('Open new window <a href="'+result.open_url+'" target="_blank">'+result.open_url+'</a>');
        window.open(result.open_url,'foo',"");
        //~ document.location = result.open_url;
    }
};

// obsolete but still used for deleting records.
Lino.do_action = function(caller,action) { 
  action.success = function(response) {
    if (caller.loadMask) caller.loadMask.hide();
    //~ console.log('Lino.do_action()',action,'action success',response);
    if (action.after_success) {
        //~ console.log('Lino.do_action() calling after_success');
        action.after_success();
    }
    if (response.responseText) {
      var result = Ext.decode(response.responseText);
      //~ console.log('Lino.do_action()',action.name,'result is',result);
      if (result.message) {
          if (result.alert) {
              //~ Ext.MessageBox.alert('Alert',result.alert_msg);
              Ext.MessageBox.alert('Alert',result.message);
          } else {
              Lino.notify(result.message);
          }
      }
      
      //~ if (result.alert_msg) Ext.MessageBox.alert('Alert',result.alert_msg);
      //~ if (result.message) Lino.notify(result.message);
      if (result.notify_msg) Lino.notify(result.notify_msg);
      if (result.js_code) { 
        //~ console.log('Lino.do_action()',action,'gonna call js_code in',result);
        var jsr = result.js_code(caller);
        //~ console.log('Lino.do_action()',action,'returned from js_code in',result);
        if (action.after_js_code) {
          //~ console.log('Lino.do_action()',action,'gonna call after_js_code');
          action.after_js_code(jsr);
          //~ console.log('Lino.do_action()',action,'returned from after_js_code');
        //~ } else {
          //~ console.log('Lino.do_action()',action,' : after_js_code is false');
        }
      };
    }
  };
  Ext.applyIf(action,{
    waitMsg: "Oota palun...",
    failure: Lino.ajax_error_handler(caller),
    params: {}
  });
  //~ action.params.su = Lino.subst_user;
  Lino.insert_subst_user(action.params);
  
  Ext.Ajax.request(action);
};

//~ Lino.gup = function( name )
//~ {
  //~ // Thanks to http://www.netlobo.com/url_query_string_javascript.html
  //~ name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");
  //~ var regexS = "[\\?&]"+name+"=([^&#]*)";
  //~ var regex = new RegExp( regexS );
  //~ var results = regex.exec( window.location.href );
  //~ if( results == null )
    //~ return "";
  //~ else
    //~ return results[1];
//~ };

//~ Lino.refresh_handler = function (ww) {
  //~ return function() { 
      //~ console.log('refresh',ww);
      //~ ww.main_item.doLayout(false,true);
      //~ ww.main_item.syncSize();
  //~ }
//~ };

//~ Lino.tools_close_handler = function (ww) {
  //~ return function() { 
      //~ ww.close();
  //~ }
//~ };
Lino.permalink_handler = function (ww) {
  return function() { 
    //~ document.location = ww.main_item.get_permalink();
    //~ console.log('20130723 Lino.permalink_handler',ww);
    
    /* Uncaught TypeError: Cannot read property 'main_item' of null  */
    if (ww) {
        var url = ww.main_item.get_permalink();
    } else {
        var url = Lino.viewport.get_permalink();
    }
    Lino.load_url(url);
  }
};
//~ Lino.run_permalink = function() {
  //~ var plink = Lino.gup('permalink');
  //~ if(plink) { eval('Lino.'+plink); }
//~ }


Lino.ajax_error_handler = function(panel) {
  return function(response,options) {
    console.log('Ajax failure:', response, options);
    if (panel.loadMask) panel.loadMask.hide();
    if (response.responseText) {
      var lines = response.responseText.split('\n');
      if (lines.length > 10) {
          line = lines.splice(5, lines.length-10, "(...)");
      }
      //~ console.log(20131005, response.statusText.toCamel());
      Ext.MessageBox.alert(
        response.statusText.toCamel(),
        lines.join('<br/>')
        //~ response.responseText.replace(/\n/g,'<br/>'))
      )
    } else {
      Ext.MessageBox.alert('Action failed',
        'Lino server did not respond to Ajax request');
    }
  }
}
// Ext.Ajax.on('requestexception',Lino.ajax_error_handler)
 


Ext.QuickTips.init();

/* setting QuickTips dismissDelay to 0 */
// Apply a set of config properties to the singleton
//~ Ext.apply(Ext.QuickTips.getQuickTip(), {
//~ Ext.apply(Ext.ToolTip, {
    //~ dismissDelay: 0
    //~ autoHide: false,
    //~ closable: true,
    //~ maxWidth: 200,
    //~ minWidth: 100,
    //~ showDelay: 50      // Show 50ms after entering target
    //~ ,trackMouse: true
//~ });


//~ Ext.apply(Ext.QuickTip, {
    //~ dismissDelay: 0,
//~ });
  
Lino.quicktip_renderer = function(title, body) {
  return function(c) {
    //~ if (c instanceof Ext.Panel) var t = c.bwrap; else // 20130129
      if (c instanceof Ext.Panel)
          var t = c.header;
      else // 20130129
          var t = c.getEl();
    // if (title == 'a2btn') console.log(20160829, c, t, body);
    //~ t.dismissDelay = 0;
    Ext.QuickTips.register({
      target: t,
      //~ cls: 'lino-quicktip-classical',
      dismissDelay: 0,
      //~ autoHide: false,
      showDelay: 50,      // Show 50ms after entering target
      //~ title: title,
      text: body
    });
  }
};


  
Lino.help_text_editor = function() {
  //~ var bp = {
      //~ mk:this.content_type,
      //~ mt:1
    //~ };
    //~ console.log(20120202,bp);
  //~ Lino.lino.ContentTypes.detail({},{base_params:bp});
  //~ Lino.lino.ContentTypes.detail.run(null,{record_id:this.content_type});
  Lino.lino.ContentTypes.detail.run(null,{record_id:this.content_type});
}

// Path to the blank image should point to a valid location on your server
//~ Ext.BLANK_IMAGE_URL = MEDIA_URL + '/extjs/resources/images/default/s.gif'; 


// used as Ext.grid.Column.renderer for id columns in order to hide the special id value -99999
Lino.id_renderer = function(value, metaData, record, rowIndex, colIndex, store) {
  //~ if (record.phantom) return '';
  return value;
}

Lino.raw_renderer = function(value, metaData, record, rowIndex, colIndex, store) {
  return value;
}

Lino.text_renderer = function(value, metaData, record, rowIndex, colIndex, store) {
  //~ return "not implemented"; 
  return value;
}

Lino.NullNumberColumn = Ext.extend(Ext.grid.Column, {
    align : 'right', 
    format : '0,00/i', 
    renderer : function(value, metaData, record, rowIndex, colIndex, store) {
        // if( colIndex == 3)
        //     console.log(20130128,"NullNumberColumn.renderer",value);
        if (value === null) return '';
        return Ext.util.Format.number(value, this.format);
    }
});


Lino.link_button = function(url) {
    // return '<a href="' + url + '"><img src="/media/lino/extjs/images/xsite/link.png" alt="link_button"></a>'
    return '<a href="' + url + '" style="text-decoration:none;">&#10138;</a>'
}

Lino.fk_renderer = function(fkname,handlername) {
  //~ console.log('Lino.fk_renderer handler=',handler);
  return function(value, metaData, record, rowIndex, colIndex, store) {
    //~ console.log('Lino.fk_renderer',fkname,rowIndex,colIndex,record,metaData,store);
    //~ if (record.phantom) return '';
    if (value) {
        return Lino.link_button('javascript:'+handlername + '.run(null,{record_id:\'' + String(record.data[fkname]) + '\'})")') + value;
        // until 20140822 (clickable foreign keys):
        // var s = '<a href="javascript:' ;
        // s += handlername + '.run(null,{record_id:\'' + String(record.data[fkname]) + '\'})">';
        // s += value + '</a>';
        // return s
    }
    return '';
  }
};

Lino.lfk_renderer = function(panel,fkname) {
  //~ console.log('Lino.fk_renderer handler=',handler);
  var handlername = 'console.log';
  return function(value, metaData, record, rowIndex, colIndex, store) {
    //~ console.log('Lino.fk_renderer',fkname,rowIndex,colIndex,record,metaData,store);
    if (record.phantom) return '';
    if (value) {
        var s = '<a href="javascript:' ;
        s += handlername + '({},{record_id:\'' + String(record.data[fkname]) + '\'})">';
        s += value + '</a>';
        //~ console.log('Lino.fk_renderer',value,'-->',s);
        return s
    }
    return '';
  }
};

//~ Lino.gfk_renderer = function() {
  //~ return function(value, metaData, record, rowIndex, colIndex, store) {
    //~ if (record.phantom) return '';
    //~ console.log('Lino.gfk_renderer',value,colIndex,record,metaData,store);
    //~ return value;
  //~ }
//~ };


Lino.build_buttons = function(panel,actions) {
  //~ console.log("20121006 Lino.build_buttons",actions);
  if (actions) {
    var buttons = Array(actions.length);
    var cmenu = Array(actions.length);
    var keyhandlers = {};
    for (var i=0; i < actions.length; i++) { 
      var a = actions[i];
      if (a.menu) a.menu = Lino.build_buttons(panel,a.menu).bbar;
      buttons[i] = a;
      cmenu[i] = {
            text : a.menu_item_text,
            iconCls : a.iconCls,
            menu : a.menu
          };
      if (a.panel_btn_handler) {
          var h = a.panel_btn_handler.createCallback(panel);
          if (a.auto_save == true) {
              h = panel.do_when_clean.createDelegate(panel,[true,h]);
          } else if (a.auto_save == null) {
              h = panel.do_when_clean.createDelegate(panel,[false,h]);
          } else if (a.auto_save == false) {
              // h = h;
          } else {
              console.log("20120703 unhandled auto_save value",a)
          }
          buttons[i].handler = h;
          cmenu[i].handler = h;
          if (a.keycode) {
              keyhandlers[a.keycode] = h;
          }
          //~ if (buttons[i].xtype == 'splitbutton') {
              //~ cmenu[i].menu = a.menu;
          //~ } else {
              //~ cmenu[i].handler = h;
          //~ }
      } else {
          console.log("action without panel_btn_handler",a)
          // cmenu[i].handler = a.handler;
      }
    }
    return {
        bbar:buttons, 
        cmenu:new Ext.menu.Menu(cmenu),
        keyhandlers: keyhandlers
    };
  }
}

Lino.do_when_visible = function(cmp,todo) {
  //~ if (cmp.el && cmp.el.dom) 
  if (cmp.isVisible()) { 
    // 'visible' means 'rendered and not hidden'
    //~ console.log(cmp.title,'-> cmp is visible now');
    todo(); 
  //~ } else {
      //~ cmp.on('resize',todo,cmp,{single:true});
  //~ }
  //~ if (false) { // 20120213
  } else { 
    //~ console.log('Lino.do_when_visible() must defer because not isVisible()',todo,cmp);
    if (cmp.rendered) {
      //~ console.log(cmp,'-> cmp is rendered but not visible: and now?');
      //~ console.log(cmp.title,'-> cmp is rendered but not visible: try again in a moment...');
      //~ var fn = function() {Lino.do_when_visible(cmp,todo)};
      //~ fn.defer(100);
      
      Lino.do_when_visible.defer(50,this,[cmp,todo]);
      //~ Lino.do_when_visible.defer(100,this,[cmp,todo]);
      
    } else {
      //~ console.log(cmp.title,'-> after render');
      cmp.on('afterrender',todo,cmp,{single:true});
    }
  }
  
};    

/*
*/
Lino.do_on_current_record = function(panel, fn, phantom_fn) {
  // console.log('20140930 do_on_current_record', arguments);
  var rec = panel.get_current_record();
  if (rec == undefined) {
    Lino.notify("There's no selected record.");
    return;
  }
  // 20120307 A VirtualTable with a Detail (lino.Models) has only "phantom" records.
  if (rec.phantom) {
    //~ if (!panel.editable) { console.log("20120312 not editable:",panel)}
    if (phantom_fn) {
      phantom_fn(panel);
    } else {
      Lino.notify("Action not available on phantom record.");
    }
    return;
  }
  return fn(rec);
};


Lino.call_ajax_action = function(
    panel, method, url, p, actionName, step, on_confirm, on_success) {
  p.an = actionName;
  if (!panel || !panel.isVisible()) {
  //~ if (true) { // 20131026 : workflow_actions of a newly created record detail executed but did't refresh the screen because their requesting panel was the insert (not the detail) formpanel.
      if (Lino.current_window) 
          panel = Lino.current_window.main_item;
      else panel = Lino.viewport;
  }
  // console.log("20150130 a", p.pv);
  // Ext.apply(p, panel.get_base_params());
  // console.log("20150130 b", p.pv);

  if (panel.get_selected) {
      var selected_recs = panel.get_selected();
      //~ console.log("20130831",selected_recs);
      var rs = Array(selected_recs.length);
      for(var i=0; i < selected_recs.length;i++) {
          rs[i] = selected_recs[i].data.id;
      };
      p.sr = rs;
  }
  
  // console.log("20140516 Lino.call_ajax_action", p, actionName, step);
  
  if (panel.loadMask) panel.loadMask.show(); 
    
  Ext.Ajax.request({
    method: method
    ,url: url
    ,params: p
    ,success: Lino.action_handler(panel, on_success, on_confirm)
    ,failure: Lino.ajax_error_handler(panel)
  });
};




Lino.row_action_handler = function(actionName, hm, pp) {
  var p = {};
  var fn = function(panel, btn, step) {
      // console.log('20150514 row_action_handler');
      if (pp) { p = pp(panel); if (! p) return; }
      
      if (!panel || panel.get_current_record == undefined) { // AFTER_20130725
        // console.log('20140930 row_action_handler 2', panel);
        panel = Ext.getCmp(panel);
        if (panel == undefined) {
          console.log("20160410 Invalid panel spec.", actionName, hm, pp);
          Lino.notify("Invalid panel spec.");
          return;
        }
      }
      
      Lino.do_on_current_record(panel, function(rec) {
          //~ console.log(panel);
          panel.add_param_values(p, true);
          Ext.apply(p, panel.get_base_params());
          Lino.call_ajax_action(
              panel, hm, panel.get_record_url(rec.id), 
              p, actionName, step, fn);
      });
  };
  return fn;
};

Lino.list_action_handler = function(ls_url,actionName,hm,pp) {
  var p = {};
  var url = '/api' + ls_url
  var fn = function(panel,btn,step) {
      //~ console.log("20121210 Lino.list_action_handler",arguments);
      if (pp) { p = pp(panel);  if (! p) return; }
      if (panel) { // may be undefined when called e.g. from quicklink
          panel.add_param_values(p, true);
          Ext.apply(p, panel.get_base_params());
      }
      Lino.call_ajax_action(panel, hm,url, p, actionName, step, fn);
  };
  return fn;
};

Lino.param_action_handler = function(window_action) { // 20121012
  var fn = function(panel,btn,step) {
    Lino.do_on_current_record(panel,function(rec) {
      window_action.run(panel.getId(),{}); 
    });
  };
  return fn;
};


Lino.run_row_action = function(
    requesting_panel, url, meth, pk, actionName, params, preprocessor) {
  //~ var panel = action.get_window().main_item;
  // console.log("20140930 Lino.run_row_action", params);
  url = '/api' + url  + '/' + pk;
  var panel = Ext.getCmp(requesting_panel);
  if (!params) params = {};
  if (preprocessor) {
      var p = preprocessor(); 
      Ext.apply(params, p);
  }
  if (panel) 
      Ext.apply(params, panel.get_base_params());
  var fn = function(panel, btn, step) {
    Lino.call_ajax_action(panel, meth, url, params, actionName, step, fn);
  }
  fn(panel, null, null);
}

Lino.put = function(requesting_panel, pk, data) {
    var panel = Ext.getCmp(requesting_panel);
    //~ var panel = null; // 20131026
    var p = {};
    p.an = 'put'; // SubmitDetail.action_name

    Ext.apply(p,data);
    var req = {
        params:p
        ,waitMsg: 'Saving your data...'
        ,scope: panel
        ,success: Lino.action_handler( panel, function(result) { 
            panel.refresh();
        })
        ,failure: Lino.ajax_error_handler(panel)
    };
    req.method = 'PUT';
    req.url = '/api' + panel.ls_url + '/' + pk;
    if (panel.loadMask) panel.loadMask.show(); 
    Ext.Ajax.request(req);
}



Lino.show_detail = function(panel, btn) {
  Lino.do_on_current_record(panel, 
    function(rec) {
      //~ panel.loadMask.show();
      Lino.run_detail_handler(panel, rec.id);
    },
    Lino.show_insert
  );
};

Lino.run_detail_handler = function(panel,pk) {
  var bp = panel.get_base_params();
  panel.add_param_values(bp); // 20120918
  var status = {
    record_id:pk,
    base_params:bp
  }
  //~ console.log("20120918 Lino.show_detail",status);
  panel.ls_detail_handler.run(null,status);
}

Lino.show_fk_detail = function(combo,detail_action,insert_action) {
    //~ console.log("Lino.show_fk_detail",combo,handler);
    pk = combo.getValue();
    if (pk) {
        detail_action.run(null,{record_id: pk})
      } else {
        insert_action.run(null);
        //~ Lino.notify("Cannot show detail for empty foreign key.");
      }
};

Lino.show_insert = function(panel,btn) {
  var bp = panel.get_base_params();
  //~ console.log('20120125 Lino.show_insert',bp)
  //~ panel.ls_insert_handler.run(null,{record_id:-99999,base_params:bp});
  panel.ls_insert_handler.run(panel.getId(),{base_params:bp});
};



if (Ext.ux.grid !== undefined) {
    Lino.GridFilters = Ext.extend(Ext.ux.grid.GridFilters,{
      encode:true,
      local:false
    });
} else {
    Lino.GridFilters = function() {}; // dummy
    Ext.override(Lino.GridFilters,{
      init : function() {}
    });
};



Lino.FieldBoxMixin = {
  before_init : function(config,params) {
    if (params) Ext.apply(config,params);
    var actions = Lino.build_buttons(this, config.ls_bbar_actions);
    if (actions) config.bbar = actions.bbar;
  },
  //~ constructor : function(ww,config,params){
    //~ this.containing_window = ww;
    //~ if (params) Ext.apply(config,params);
    //~ var actions = Lino.build_buttons(this,config.ls_bbar_actions);
    //~ if (actions) config.bbar = actions.bbar;
    //~ Lino.FieldBoxMixin.superclass.constructor.call(this, config);
  //~ },
  do_when_clean : function(auto_save,todo) { todo() },
  //~ format_data : function(html) { return '<div class="htmlText">' + html + '</div>' },
  format_data : function(html) { return html },
  get_base_params : function() {
    // needed for insert action
    var p = Ext.apply({}, this.base_params);
    Lino.insert_subst_user(p);
    return p;
  },
  set_base_params : function(p) {
    this.base_params = Ext.apply({},p);
    //~ if (p.param_values) this.set_param_values(p.param_values);  
  },
  clear_base_params : function() {
      this.base_params = {};
      Lino.insert_subst_user(this.base_params);
  },
  set_base_param : function(k,v) {
    this.base_params[k] = v;
  }
};

Ext.override(Ext.form.HtmlEditor, {
    fixKeys : function(){
        if(Ext.isIE){
            return function(e){
                var k = e.getKey(),
                    doc = this.getDoc(),
                        r;
                if(k == e.TAB){
                    e.stopEvent();
                    r = doc.selection.createRange();
                    if(r){
                        r.collapse(true);
                        r.pasteHTML('&nbsp;&nbsp;&nbsp;&nbsp;');
                        this.deferFocus();
                    }
                }else if(k == e.ENTER){
                    r = doc.selection.createRange();
                    if(r){
                        var target = r.parentElement();
                        if(!target || target.tagName.toLowerCase() != 'li'){
                            e.stopEvent();
                            r.pasteHTML('<br />');
                            r.collapse(false);
                            r.select();
                        }
                    }
                }
            };
        }else if(Ext.isOpera){
            return function(e){
                var k = e.getKey();
                if(k == e.TAB){
                    e.stopEvent();
                    this.win.focus();
                    this.execCmd('InsertHTML','&nbsp;&nbsp;&nbsp;&nbsp;');
                    this.deferFocus();
                }
            };
        }else if(Ext.isWebKit){
            // HKC : this is probably our most used case.
            return function(e){
                var k = e.getKey();
                if(k == e.TAB){
                    e.stopEvent();
                    this.execCmd('InsertText','\t');
                    this.deferFocus();
                }else if(k == e.ENTER){
                    e.stopEvent();
                    this.execCmd('InsertHtml','<br /><br />');
                    this.deferFocus();
                }
             //   HKC
               else if (k == e.S && e.ctrlKey){
                    e.stopEvent();
                    e.preventDefault();
                    //this.getWin.fireEvent('keyup');
                    // this.fireKey(e);
                    console.log('HTMLEditor is saving...');
                }
             };
        }
    }(),
    // bubbleEvents : ['keypress']
    // initComponent : function() {
    //     Ext.form.HtmlEditor.superclass.initComponent.call(this);
    //     this.addEvents('submit');
    // },
    // submit : function (event) {
    //     console.log("rrrrr");
    // },
    // initEditor : function() {
    //     Ext.form.HtmlEditor.superclass.initEditor.call(this);
    //     if (Ext.isGecko) {
    //         Ext.EventManager.on(this, 'keypress', this.fireSubmit, this);
    //     }
    //     if (Ext.isIE || Ext.isWebKit || Ext.isOpera) {
    //         Ext.EventManager.on(this, 'keydown', this.fireSubmit,
    //             this);
    //     }
    // },
    fireSubmit : function(e) {
        console.log("fireSubmit ...");
    }
});


Lino.HtmlBoxPanel = Ext.extend(Ext.Panel, Lino.PanelMixin);
Lino.HtmlBoxPanel = Ext.extend(Lino.HtmlBoxPanel, Lino.FieldBoxMixin);
Lino.HtmlBoxPanel = Ext.extend(Lino.HtmlBoxPanel, {
  disabled_in_insert_window : true,
  constructor : function(config,params) {
    this.before_init(config,params);
    Lino.HtmlBoxPanel.superclass.constructor.call(this, config);
  },
  //~ constructor : function(ww,config,params){
    //~ this.ww = ww;
    //~ if (params) Ext.apply(config,params);
    //~ var actions = Lino.build_buttons(this,config.ls_bbar_actions);
    //~ if (actions) config.bbar = actions.bbar;
    //~ Lino.FieldBoxMixin.constructor.call(this, ww,config,params);
  //~ },
  //~ constructor : function(ww,config,params){
    //~ this.ww = ww;
    //~ if (params) Ext.apply(config,params);
    //~ var actions = Lino.build_buttons(this,config.ls_bbar_actions);
    //~ if (actions) config.bbar = actions.bbar;
    //~ Lino.FieldBoxMixin.superclass.constructor.call(this, config);
  //~ },
  //~ disable : function() { var tb = this.getBottomToolbar(); if(tb) tb.disable()},
  //~ enable : function() { var tb = this.getBottomToolbar(); if(tb) tb.enable()},
  onRender : function(ct, position){
    Lino.HtmlBoxPanel.superclass.onRender.call(this, ct, position);
    //~ console.log(20111125,this.containing_window);
    if (this.containing_panel) {
      this.containing_panel.on('enable',this.enable,this);
      this.containing_panel.on('disable',this.disable,this);
    }
    this.el.on({
      dragenter:function(event){
        event.browserEvent.dataTransfer.dropEffect = 'move';
        return true;
      }
      ,dragover:function(event){
        event.browserEvent.dataTransfer.dropEffect = 'move';
        event.stopEvent();
        return true;
      }
      ,drop:{
        scope:this
        ,fn:function(event){
          event.stopEvent();
          //~ console.log(20110516);
          var files = event.browserEvent.dataTransfer.files;
          if(files === undefined){
            return true;
          }
          var len = files.length;
          while(--len >= 0){
            console.log(files[len]);
            //~ this.processDragAndDropFileUpload(files[len]);
          }
          Lino.show_insert(this);
        }
      }
    });
  },
  refresh : function(unused) { 
      // this.containing_panel.refresh();
      this.refresh_with_after();
  },
  /* HtmlBoxPanel */
  refresh_with_after : function(after) {
      // var todo = this.containing_panel.refresh();
      var box = this.items.get(0);
      var todo = function() {
        if (this.disabled) { return; }
        this.set_base_params(this.containing_panel.get_master_params());

        var el = box.getEl();
        if (el) {
            var record = this.containing_panel.get_current_record();
            var newcontent = record ? 
                this.format_data(record.data[this.name]) : '';
            // console.log('20140917 HtmlBox.refresh()',
            //             this.name, record.data.LinksByHuman);
            el.update(newcontent, true);
        // } else {
        //     console.log('20140502 cannot HtmlBox.refresh()',this.name);
        }
      };

      Lino.do_when_visible(box, todo.createDelegate(this));
  }
});
//~ Ext.override(Lino.HtmlBoxPanel,Lino.FieldBoxMixin);


Lino.ActionFormPanel = Ext.extend(Ext.form.FormPanel,Lino.MainPanel);
Lino.ActionFormPanel = Ext.extend(Lino.ActionFormPanel, Lino.PanelMixin);
Lino.ActionFormPanel = Ext.extend(Lino.ActionFormPanel, Lino.FieldBoxMixin);
Lino.ActionFormPanel = Ext.extend(Lino.ActionFormPanel, {
  //~ layout:'fit'
  //~ ,autoHeight: true
  //~ ,frame: true
  window_title : "Action Parameters",
  constructor : function(config){
    config.bbar = [
        {text: 'OK', handler: this.on_ok, scope: this},
        {text: 'Cancel', handler: this.on_cancel, scope: this}
    ];
    Lino.ActionFormPanel.superclass.constructor.call(this, config);
  }
  //~ ,initComponent : function(){
    //~ Lino.ActionFormPanel.superclass.initComponent.call(this);
  //~ }
  ,on_cancel : function() { 
    this.get_containing_window().close();
  }
  ,on_ok : function() { 
    var panel = this.requesting_panel;
    // var panel = this.get_containing_window().main_item;
    // console.log("20131004 on_ok",this,panel,arguments);
    var actionName = this.action_name;
    var pk = this.record_id || this.default_record_id;
    if (pk == undefined && this.base_params) { pk = this.base_params.mk; }
    if (pk == undefined && panel) {
        pk = panel.get_current_record().id;
    }
    if (pk == undefined) {
        // 20170101 VerifyUser action
        pk = '-99998';
        // Lino.alert("Sorry, dialog action without base_params.mk");
        // return;
    }
    var self = this;
    // function on_success() { self.get_containing_window().close(); };
    // see 20131004 and 20140430
    var url = '/api';

    // 20150119 : The OK button on AgentsByClient.create_visit went to
    // /api/pcsw/Clients/ instead of /api/pcsw/Coachings/
    // if (panel) 
    //     url += panel.ls_url;
    // else 
    //     url += this.ls_url;

    if (this.ls_url) 
        url += this.ls_url;
    else 
        url += panel.ls_url;
    url += '/' + pk;
    // wrap into function to prepare possible recursive call
    var fn = function(panel, btn, step) {
      var p = {};
      self.add_field_values(p)
      if (panel) Ext.apply(p, panel.get_base_params());
      delete p.pv;
      // console.log("20150130", p.pv);

      Lino.call_ajax_action(
          panel, 'GET', url, p, actionName, step, fn); //  , on_success);
    }
    fn(panel, null, null);
    
    
  }
  /* ActionFormPanel*/
  ,set_status : function(status, rp){
    this.requesting_panel = Ext.getCmp(rp);
    //~ console.log('20120918 ActionFormPanel.set_status()',status,rp,this.requesting_panel);
    this.clear_base_params();
    if (status == undefined) status = {};
    //~ if (status.param_values) 
    this.set_field_values(status.field_values);
    if (status.base_params) this.set_base_params(status.base_params);
    this.record_id = status.record_id;
  }
  
  ,before_row_edit : function(record) {}
  ,add_field_values : function (p) { // similar to add_param_values()
      /* LS 20160517 : Until now Lino tested whether the form is
       dirty, and if not, submitted only the values which had been set
       by set_status. But now status_field_values can be empty because
       Action.keep_user_values is True. In that case we must submit
       the current values even if the form is not dirty.  I don't
       remember why we had this feature of not submitting unmodified
       field values, so I remove this feature for now. */
      p.fv = this.get_field_values();
      // if (this.form.isDirty()) {
      //   p.fv = this.get_field_values();
      // }else{
      //   // console.log("20160517 add_param_values not dirty, status_field_values",
      //   //             this.status_field_values);
      //   if (this.status_field_values) 
      //     p.fv = Lino.fields2array(
      //         this.fields, this.status_field_values);
      // }
      //~ console.log("20120203 add_param_values added pv",pv,"to",p);
  }
  ,get_field_values : function() {
      return Lino.fields2array(this.fields);
  }
  ,set_field_values : function(pv) {
      // console.log('20160516 MainPanel.set_param_values', pv);
      // if Action.keep_user_values, we receive an empty dict ({})
      this.status_field_values = pv;
      if (pv) {
          this.form.my_loadRecord(pv);
          var record = { data: pv };
          this.before_row_edit(record);
      } else {
          this.form.reset(); 
          this.before_row_edit();
      }
  }
  ,config_containing_window : function(wincfg) { 
      wincfg.title = this.window_title;
      wincfg.keys = [
        { key: Ext.EventObject.ENTER, fn: this.on_ok }
      ]
      
      if (!wincfg.defaultButton) this.getForm().items.each(function(f){
          if(f.isFormField){ 
              wincfg.defaultButton = f;
              return false;
          }
      });

  }
});

    
Lino.fields2array = function(fields, values) {
    // console.log('20160517 fields2array gonna loop on', fields, values);
    var pv = Array(fields.length);
    for(var i=0; i < fields.length;i++) {
        var f = fields[i]
        if (values) 
          var v = values[f.name];
        else 
          var v = f.getValue();
        if (f.formatDate) {
            pv[i] = f.formatDate(v); 
        } else {
            pv[i] = v; // f.getValue(); 
        }
    }
    // console.log('20160517 fields2array returns', pv);
    return pv;
}


Lino.FormPanel = Ext.extend(Ext.form.FormPanel,Lino.MainPanel);
Lino.FormPanel = Ext.extend(Lino.FormPanel,Lino.PanelMixin);
Lino.FormPanel = Ext.extend(Lino.FormPanel,{
  params_panel_hidden : false,
  save_action_name : null, 
  //~ base_params : {},
  //~ trackResetOnLoad : true,
  //~ query_params : {},
  //~ 20110119b quick_search_text : '',
  constructor : function(config,params){
    if (params) Ext.apply(config,params);
    this.base_params = {};
    //~ ww.config.base_params.query = ''; // 20111018
    //~ console.log(config);
    //~ console.log('FormPanel.constructor() 1',config)
    //~ Ext.applyIf(config,{base_params:{}});
    //~ console.log('FormPanel.constructor() 2',config)
      
    config.trackResetOnLoad = true;
    
    Lino.FormPanel.superclass.constructor.call(this, config);
      
    //~ this.set_base_param('$URL_PARAM_FILTER',null); // 20111018
    //~ this.set_base_param('$URL_PARAM_FILTER',''); // 20111018
      
  },
  initComponent : function(){
    
    this.containing_panel = this;

    //~ console.log("20111201 containing_window",this.containing_window,this);


    var actions = Lino.build_buttons(this, this.ls_bbar_actions);
    if (actions) {
        this.bbar = actions.bbar;
        // console.log("20160829 tooltip", actions.bbar);
    //~ } else {
        //~ this.bbar = [];
    }
    //~ Ext.apply(config,Lino.build_buttons(this,config.ls_bbar_actions));
    //~ config.bbar = Lino.build_buttons(this,config.ls_bbar_actions);
    //~ var config = this;
    
    //~ if (this.containing_window instanceof Lino.DetailWrapper) {
    
    //~ console.log('20120121 initComponent', this.action_name);
    //~ if (this.action_name == 'detail' | this.action_name == 'show') {
    //~ if (this.action_name != 'insert') {
    if (! this.hide_top_toolbar) {
      this.tbar = [];
      // 20111015    
      if (! this.hide_navigator) {
        this.record_selector = new Lino.RemoteComboFieldElement({
          store: new Lino.ComplexRemoteComboStore({
            //~ baseParams: this.containing_window.config.base_params,
            baseParams: this.get_base_params(),
            //~ value: this.containing_window.config.base_params.query,
            proxy: new Ext.data.HttpProxy({
              url: '/choices' + this.ls_url,
              method:'GET'
            })
          }),
          pageSize:25,
          listeners: { 
            scope:this, 
            select:function(combo,record,index) {
              //~ console.log('jumpto_select',arguments);
              this.goto_record_id(record.id);
            }
          },
          emptyText: "Go to record"
        })
        this.tbar = this.tbar.concat([this.record_selector]);
        
        this.tbar = this.tbar.concat([
          this.first = new Ext.Toolbar.Button({
              tooltip:"First",disabled:true,
              handler:this.moveFirst,scope:this,iconCls:'x-tbar-page-first'}),
          this.prev = new Ext.Toolbar.Button({
              tooltip:"Previous",disabled:true,
              handler:this.movePrev,scope:this,iconCls:'x-tbar-page-prev'}),
          this.next = new Ext.Toolbar.Button({
              tooltip:"Next",disabled:true,
              handler:this.moveNext,scope:this,iconCls:'x-tbar-page-next'}),
          this.last = new Ext.Toolbar.Button({
              tooltip:"Last",disabled:true,
              handler:this.moveLast,scope:this,iconCls:'x-tbar-page-last'})
        ]);
      }
      this.tbar = this.add_params_panel(this.tbar);
      
      //~ console.log(20101117,this.containing_window.refresh);
      this.tbar = this.tbar.concat([
        {
          //~ text:'Refresh',
          handler:function(){ this.do_when_clean(false,this.refresh.createDelegate(this)) },
          iconCls: 'x-tbar-loading',
          tooltip:"Reload current record",
          scope:this}
      ]);
          
      if (this.bbar) { // since 20121016
        if (this.tbar) {
            this.tbar = this.tbar.concat(['-']) ;
        } else {
          this.tbar = [];
        }
        this.tbar = this.tbar.concat(this.bbar) ;
        this.bbar = undefined;
      }
    
      this.tbar = this.tbar.concat([
          '->',
          this.displayItem = new Ext.Toolbar.TextItem({})
      ]);
          
    }
    //~ if (this.content_type && this.action_name != 'insert') {
      //~ this.bbar = this.bbar.concat([
        //~ '->',
        //~ { text: "[$_('Help Text Editor')]",
          //~ handler: Lino.help_text_editor,
          //~ qtip: "$_('Edit help texts for fields on this model.')",
          //~ scope: this}
      //~ ])
    //~ }
    //~ this.before_row_edit = config.before_row_edit.createDelegate(this);
      
    //~ if (this.master_panel) {
        //~ this.set_base_params(this.master_panel.get_master_params());
    //~ }
      
    Lino.FormPanel.superclass.initComponent.call(this);

    // this.on('show',
    //         function(){ this.init_focus();}, 
    //         this);
    
    this.on('render',function(){
      this.loadMask = new Ext.LoadMask(this.bwrap,{msg:"Oota palun..."});
    },this);
    
    
    if (this.action_name == 'insert') {
      this.cascade(function(cmp){
        if (cmp.disabled_in_insert_window) {
            // console.log('20110613 disabled_in_insert_window', cmp);
            //~ cmp.disable();
            cmp.hide();
        }
      });
      
    }
    
  },
  
  unused_init_focus : function(){ 
    // set focus to the first field
    console.log("20140205 Lino.FormPanel.init_focus");
    // Lino.FormPanel.superclass.focus.call(this);
    this.getForm().items.each(function(f){
        if(f.isFormField && f.rendered){ 
            f.focus();
            console.log("20140205 focus", f);
            return false;
        }
    });
  },

  /* FormPanel */
  get_status : function(){
      var st = {
        base_params: this.get_base_params(),
        // data_record : this.get_current_record()
      }
      var rec = this.get_current_record();
      if (rec) st.record_id = rec.id;
      // 20140917 : get_status must not store the whole data_record
      // because that would prevent the form to actually reload
      // when set_status is called after a child window closed.
      
      var tp = this.items.get(0);
      if (tp instanceof Ext.TabPanel) {
        st.active_tab = tp.getActiveTab();
      }
      st.param_values = this.status_param_values;
      return st;
  },

  /* FormPanel */
  set_status : function(status, rp){
    this.requesting_panel = Ext.getCmp(rp);
    // console.log('20140917 FormPanel.set_status()', status);
    this.clear_base_params();
    if (status == undefined) status = {};
    //~ if (status.param_values) 
    this.set_param_values(status.param_values);
    if (status.base_params) this.set_base_params(status.base_params);
    var tp = this.items.get(0);
    if (tp instanceof Ext.TabPanel) {
      if (status.active_tab) {
        //~ console.log('20111201 active_tab',this.active_tab,this.items.get(0));
        //~ tp.activeTab = status.active_tab;
        tp.setActiveTab(status.active_tab);
        //~ this.main_item.items.get(0).activate(status.active_tab);
      } else {
        if (! status.data_record) {  // 20141206
            tp.setActiveTab(0);
        }
      }
    }
    
    if (status.data_record) {
      /* defer because set_window_title() didn't work otherwise */
      // 20140421 removed defer for bughunting to simplify side effects
      // this.set_current_record.createDelegate(
      //     this, [status.data_record]).defer(100);
      this.set_current_record(status.data_record);
      //~ return;
    } else {
        var record_id = status.record_id || this.default_record_id;
        if (record_id != undefined) { 
          /* possible values include 0 and null, 0 being a valid record id, 
          null the equivalent of undefined
          */
          this.load_record_id(record_id);
        } else {
            this.set_current_record(undefined);
        }
    }
    // this.init_focus()
  }
  ,get_base_params : function() {  /* FormPanel */
    // needed for insert_action
    var p = Ext.apply({}, this.base_params);
    Lino.insert_subst_user(p);
    return p;
  }
  ,set_base_params : function(p) {
    //~ this.base_params = Ext.apply({},this.base_params); // make sure it is an instance variable
    delete p['query'] // 20120725
    Ext.apply(this.base_params,p);
    if (this.record_selector) {
        var store = this.record_selector.getStore();
        for (k in p) store.setBaseParam(k,p[k]);
        delete this.record_selector.lastQuery;
        //~ console.log("20120725 record_selector.setBaseParam",p)
    }
  }
  ,clear_base_params : function() {
      this.base_params = {};
      Lino.insert_subst_user(this.base_params);
  }
  ,set_base_param : function(k,v) {
    this.base_params[k] = v;
  }
  ,after_delete : function() {
    if (this.current_record.navinfo.next)
      this.moveNext();
    else if (this.current_record.navinfo.prev)
      this.movePrev();
    else 
      this.abandon();
  }
  ,moveFirst : function() {this.goto_record_id(
      this.current_record.navinfo.first)}
  ,movePrev : function() {this.goto_record_id(
      this.current_record.navinfo.prev)}
  ,moveNext : function() {this.goto_record_id(
      this.current_record.navinfo.next)}
  ,moveLast : function() {this.goto_record_id(
      this.current_record.navinfo.last)}
  
  ,refresh : function(unused) { 
      this.refresh_with_after();
  }
  /* FormPanel */
  ,refresh_with_after : function(after) { 
    // console.log('20140917 Lino.FormPanel.refresh_with_after()',this);
    if (this.current_record) {
        this.load_record_id(this.current_record.id, after);
    } else {
        this.set_current_record(undefined, after);
    }
  }
  
  ,do_when_clean : function(auto_save, todo) {
    var this_ = this;
    if (this.form.isDirty()) {
        // console.log('20140421 do_when_clean : form is dirty')
        if (auto_save) {
            this_.save(todo);
        } else {
          //~ console.log('20111217 do_when_clean() form is dirty',this.form);
          var config = {title:"Kinnitus"};
          config.buttons = Ext.MessageBox.YESNOCANCEL;
          config.msg = "Save changes to current record ?";
          config.fn = function(buttonId,text,opt) {
            //~ console.log('do_when_clean',buttonId)
            if (buttonId == "yes") {
                //~ Lino.submit_detail(this_,undefined,todo);
                //~ this_.containing_window.save(todo);
                this_.save(todo);
            } else if (buttonId == "no") { 
              todo();
            }
          }
          Ext.MessageBox.show(config);
        }
    }else{
      // console.log('20140421 do_when_clean : now!')
      todo();
    }
  }
  
  ,goto_record_id : function(record_id) {
    // console.log('20140917 Lino.FormPanel.goto_record_id()',record_id);
    //~ var this_ = this;
    //~ this.do_when_clean(function() { this_.load_record_id(record_id) }
    this.do_when_clean(
        true, this.load_record_id.createDelegate(this, [record_id]));
  }
  
  ,load_record_id : function(record_id, after) {
    var this_ = this;
    var p = Ext.apply({}, this.get_base_params());
    if (this.action_name)
        p.an = this.action_name;
    p.rp = this.getId();
    p.fmt = 'json';
    this.add_param_values(p);
    if (this.loadMask) this.loadMask.show();
    Ext.Ajax.request({ 
      waitMsg: 'Loading record...',
      method: 'GET',
      params: p,
      scope: this,
      url: this.get_record_url(record_id),
      success: function(response) {   
        // todo: convert to Lino.action_handler.... but result 
        if (this.loadMask) this.loadMask.hide();
        if (response.responseText) {
          var rec = Ext.decode(response.responseText);
          // console.log('20150905 load_record_id success', rec);
          this.set_param_values(rec.param_values);
          this.set_current_record(rec, after);
        }
      },
      failure: Lino.ajax_error_handler(this)
    });
  }

  ,abandon : function () {
    Ext.MessageBox.alert('Note',
      "No more records to display. Detail window has been closed.");
    Lino.close_window();
  }
  
  ,set_current_record : function(record, after) {
    // console.log('20160825 set_current_record', record);
    if (this.record_selector) {
        this.record_selector.clearValue();
        // e.g. InsertWrapper FormPanel doesn't have a record_selector
    }
    this.current_record = record;
    if (record && record.data) {
      this.enable();
      this.form.my_loadRecord(record.data);
      this.set_window_title(record.title);
      //~ this.getBottomToolbar().enable();
      var da = record.data.disabled_actions;
      if (da) {
          //~ console.log('20120528 disabled_actions =',da,this.getBottomToolbar());
          //~ 20121016 this.getBottomToolbar().items.each(function(item,index,length){
          if(this.hide_top_toolbar) {
              var tb = this.getBottomToolbar();
          } else {
              var tb = this.getTopToolbar();
          }
          if (tb) tb.items.each(function(item,index,length){
              //~ console.log('20120528 ',item.itemId,'-->',da[item.itemId]);
              if (da[item.itemId]) item.disable(); else item.enable();
          });
      };
      if (this.disable_editing | record.data.disable_editing) {
          //~ console.log("20120202 disable_editing",record.title);
          this.form.items.each(function(cmp){
            if (!cmp.always_enabled) cmp.disable();
          },this);
      } else {
          this.form.items.each(function(cmp){
            //~ console.log("20120202",cmp);
            if (record.data.disabled_fields[cmp.name]) cmp.disable();
            else cmp.enable();
          },this);
        
          //~ if (record.data.disabled_fields) {
              //~ for (i = 0; i < record.data.disabled_fields.length; i++) {
                  //~ var flds = this.find('name',record.data.disabled_fields[i]);
                  //~ if (flds.length == 1) { 
                    //~ flds[0].disable(); 
                  //~ }
              //~ }
          //~ }
      };
      if (this.first) {
        if (record.navinfo  && ! this.hide_navigator) {
          this.first.setDisabled(!record.navinfo.first);
          this.prev.setDisabled(!record.navinfo.prev);
          this.next.setDisabled(!record.navinfo.next);
          this.last.setDisabled(!record.navinfo.last);
          this.displayItem.setText(record.navinfo.message);
        } else {
          this.first.setDisabled(true);
          this.prev.setDisabled(true);
          this.next.setDisabled(true);
          this.last.setDisabled(true);
        }
      }
    } else {
      if (this.form.rendered) 
        this.form.reset(); /* FileUploadField would fail when resetting a non-rendered form */
      //~ this.disable();
      //~ this.getBottomToolbar().disable();
      this.form.items.each(function(cmp){
        cmp.disable();
      },this);
      this.set_window_title(this.empty_title);
      //~ this.containing_window.window.setTitle(this.empty_title);
      if (!this.hide_navigator) {
        this.first.disable();
        this.prev.disable();
        this.next.disable();
        this.last.disable();
      }
    }
    // console.log('20140917 gonna call before_row_edit', record);
        var current_focus_fields = false;
        for (var i = 0; i < this.form.items.items.length;i++) {
            if (this.form.items.items[i].hasFocus) current_focus_fields = i;
        }
    this.before_row_edit(record);
        if (current_focus_fields != false){
            this.form.items.items[current_focus_fields].focus();
        }
    // console.log('20140917 gonna call after', after);
    if (after) after();
  },
  
  /* FormPanel */
  before_row_edit : function(record) {},
  search_change : function(field,oldValue,newValue) {
    //~ console.log('search_change',field.getValue(),oldValue,newValue)
    this.set_base_param('query',field.getValue()); 
    this.refresh();
  },
  
  get_selected : function() { return [ this.current_record ] },
  get_current_record : function() {  
    //~ console.log(20100714,this.current_record);
    return this.current_record 
  },
  
  get_permalink_url : function() {
      var rec = this.get_current_record();
      if (rec && ! rec.phantom && rec.id != -99998)
          return '/api' 
              + this.ls_url + '/' + rec.id;
      return '/api' + this.ls_url;
    
  },
  add_param_tab : function(p) {
    var main = this.items.get(0);
    if (main.activeTab) {
      var tab = main.items.indexOf(main.activeTab);
      // console.log('20150130 main.activeTab', tab, main.activeTab);
      if (tab) p.tab = tab;
    // } else {
    //   console.log('20150130 no main.activeTab');
    }
  },
  get_permalink_params : function() {
    var p = {};
    //~ var p = {an:'detail'};
    if (this.action_name)
        p.an = this.action_name;
    this.add_param_tab(p)
    this.add_param_values(p)
    return p;
  }
  
  ,validate_form : function() {  // not used. see actions.ValidateForm
      // var ov = {};
      // this.form.items.each(function(f){
      //     ov[f.name] = f.originalValue
      // });

      // console.log('20140509 FormPanel.validate_form', ov);
      // var after = function() { 
      //     this.form.items.each(function(f){
      //         f.originalValue = ov[f.name];
      //     });
      // }
      // this.save2(null, 'validate', after);
      this.save2(null, 'validate');
  }

  /* Lino.FormPanel */
  ,save : function(after) {
    var action_name = this.save_action_name;
    if (!action_name) 
        action_name = this.action_name;
    // console.log('20140503 FormPanel.save', action_name);
    this.save2(after, action_name);
  }

  ,save2 : function(after, action_name) {
    var rec = this.get_current_record();
    if (!rec) { 
        Lino.notify("Sorry, no current record."); 
        return; 
    }
    var panel = this;
    if (this.has_file_upload) this.form.fileUpload = true;
    this.loadMask.show();
    var p = {};
    Ext.apply(p, this.get_base_params());
    p.rp = this.getId();
    p.an = action_name;
    this.add_param_tab(p)
    // console.log('20150216 FormPanel.save()', rec, this.form);
    var submit_config = {
        params: p, 
        scope: this,
        success: function(form, action) {
          this.loadMask.hide();
          Lino.notify(action.result.message);
          Lino.handle_action_result(this, action.result, after);
        },
        failure: function(form,action) { 
          this.loadMask.hide();
          Lino.on_submit_failure(form, action);
        },
        clientValidation: true
    };
    if (rec.phantom) {  // it's a new record
      Ext.apply(submit_config, {
        url: '/api' + this.ls_url,
        method: 'POST'
      });
      // panel.refresh();
      // temporarily disabled. See 20151002
    } else {  // submit on existing row
      Ext.apply(submit_config, {
        url: '/api' 
              + this.ls_url + '/' + rec.id,
        method: 'PUT'
      })
    }
    this.form.submit(submit_config);
  }
  
  ,on_cancel : function() { 
    this.get_containing_window().close();
  }
  ,on_ok : function() { 
      // console.log("20140424");
      // this.save(null, true, this.save_action_name);
      this.save();
  }
  ,config_containing_window : function(wincfg) { 

      // Note that defaultButton means: which component should receive
      // focus when Window is focussed.  If no defaultButton set,
      // specify the first form field.

      if (!wincfg.defaultButton) this.getForm().items.each(function(f){
          if(f.isFormField){ 
              wincfg.defaultButton = f;
              // console.log("20140205 defaultButton", f);
              return false;
          }
      });

      wincfg.keys = [];

      wincfg.keys.push({
          key: Ext.EventObject.ESCAPE, 
          handler: this.on_cancel, scope:this });
      wincfg.keys.push({
          key: 's', ctrl: true, 
             stopEvent: true, handler: this.on_ok, scope:this });
  }

});



Lino.getRowClass = function(record, rowIndex, rowParams, store) {
    //~ console.log(20130816,record);
    //~ return 'x-grid3-row-green';
    //~ return record.data.row_class + ' auto-height';
    return record.data.row_class;
  //~ if (true) {
      //~ return 'x-grid3-row-red';
  //~ }
  //~ if (record.phantom) {
    //~ console.log(20101009,record);
    //~ rowParams.bodyStyle = "color:red;background-color:blue";
    //~ return 'lino-phantom-row';
    //~ }
  //~ console.log('20101009 not a phantom:',record);
  //~ return '';
}

//~ FOO = 0;



Lino.GridStore = Ext.extend(Ext.data.ArrayStore,{ 
  autoLoad: false
  ,load: function(options) {
    //~ foo.bar = baz; // 20120213
    if (!options) options = {};
    if (!options.params) options.params = {};
    options.params.fmt = 'json';
    options.params.rp = this.grid_panel.getId();
    Lino.insert_subst_user(options.params); // since 20121016
      
    var start = this.grid_panel.start_at_bottom ? -1 : 0;
    if (this.grid_panel.hide_top_toolbar) {
        //~ console.log("20120206 GridStore.load() toolbar is hidden");
        options.params.start = start;
        if (this.grid_panel.preview_limit) {
          options.params.limit = this.grid_panel.preview_limit;
        }
    } else {
        var ps = this.grid_panel.calculatePageSize();
        if (!ps) {
          // console.log("GridStore.load() failed to calculate pagesize");
          return false;
        } 
        options.params.limit = ps;
      
        this.grid_panel.getTopToolbar().pageSize =  ps;
        if (options.params.start == undefined)
            // if (start != -1) 
            //     start = this.grid_panel.getTopToolbar().cursor
            options.params.start = start;
      
        // console.log("20141108 GridStore.load() ", options.params);
    }
      
    this.grid_panel.add_param_values(options.params);
    //~ Lino.insert_subst_user(options.params);
    //~ console.log("20120814 GridStore.load()",options.params,this.baseParams);
    return Lino.GridStore.superclass.load.call(this, options);
  }
  // ,insert : function(index, records) {
  //   return Ext.data.Store.prototype.insert.call(this, index, records)
    // return Lino.GridStore.superclass.insert.call(this, index, records);
  // }
});

Lino.get_current_grid_config = function(panel) {
    return panel.get_current_grid_config();
}


// Like the default value for GridView.cellTpl but adds a class "lino-auto-height"
Lino.auto_height_cell_template = new Ext.Template(
'<td class="x-grid3-col x-grid3-cell x-grid3-td-{id} {css}" style="{style}" tabIndex="0" {cellAttr}>',
    '<div class="lino-auto-height x-grid3-cell-inner x-grid3-col-{id}" unselectable="on" {attr}>{value}</div>',
'</td>'
);

Lino.GridPanel = Ext.extend(Ext.grid.EditorGridPanel, Lino.MainPanel);
Lino.GridPanel = Ext.extend(Lino.GridPanel, Lino.PanelMixin);
Lino.GridPanel = Ext.extend(Lino.GridPanel, {
  quick_search_text : '',
  start_at_bottom : false,
  is_searching : false,
  disabled_in_insert_window : true,
  clicksToEdit:2,
  enableColLock: false,
  autoHeight: false,
  params_panel_hidden : false,
  preview_limit : undefined, 
  // fake_row_content: '<br>',
  row_height: 1,
  //~ loadMask: true,
  //~ viewConfig: {
          //~ getRowClass: Lino.getRowClass,
          //~ emptyText:"$_('No data to display.')"
        //~ },
        
        
  loadMask: {msg:"Oota palun..."},
  
  constructor : function(config){

    config.plugins = [new Lino.GridFilters()];
    
    
    Lino.GridPanel.superclass.constructor.call(this,config);
    
    //~ if (this.containing_window) {
        //~ console.log("20111206 install refresh");
        //~ this.containing_window.on('show',this.refresh,this);
    //~ }
    
  },
  
  init_containing_window : function(win) { 
    //~ console.log("20111206 install refresh");
    //~ win.on('show',this.refresh,this);
  }

  ,handle_key_event : function(e) {
    // console.log("20140514 handle_key_event", e, this.keyhandlers);
    var h = this.keyhandlers[e.keyCode];
    if (h) {
        h(this);
        e.stopEvent();
    }
  }
  
  ,initComponent : function(){
    
    /* 
    Problem 20111206:
    When a GridPanel is the main item of the window, then it doesn't 
    have it's own header but uses the window's header bar.
    We must do this in initComponent because e.g. in beforerender 
    it's already to late: a header element has been created because 
    there was a title.
    But Lino.Window adds itself as `this.containing_window` 
    only after the GridPanel has been initialized.
    Workaround is to generate a line "params.containing_window = true;" 
    in the handler function.
    */ 
    if (this.is_main_window) {
        //~ console.log(20111206, 'delete title',this.title,'from',this);
        this.tools = undefined;  
        this.title = undefined;  /* simply deleting it 
          isn't enough because that would only 
          unhide the title defined in some base class. */
    } 
    //~ else console.log(20111206, 'dont delete title',this.title,'from',this);
    
    /* e.g. when slave gridwindow called from a permalink */
    //~ if (this.base_params) Ext.apply(bp,this.base_params);  
    
    var proxy = new Ext.data.HttpProxy({ 
      // 20120814 
      url: '/api' + this.ls_url
      ,method: "GET"
      //~ ,url: ADMIN_URL + '/restful' + this.ls_url
      //~ ,restful: true 
      //~ ,listeners: {load:on_proxy_load} 
      //~ ,listeners: {write:on_proxy_write} 
    });
    //~ config.store = new Ext.data.JsonStore({ 
    //~ this.store = new Ext.data.ArrayStore({ 
    this.store = new Lino.GridStore({ 
      grid_panel: this
      ,listeners: { exception: Lino.on_store_exception }
      ,remoteSort: true
      ,totalProperty: "count"
      ,root: "rows"
      //~ ,id: "id" 
      ,proxy: proxy
      //~ autoLoad: this.containing_window ? true : false
      ,idIndex: this.pk_index
      //~ ,baseParams: bp
      ,fields: this.ls_store_fields
      ,idProperty: this.ls_id_property 
      // 20120814
      //~ ,writer : new Ext.data.JsonWriter({
        //~ writeAllFields: false
        //~ ,listful: true
      //~ })
      //~ ,restful : true
    });
      
    //~ console.log('config.pk_index',config.pk_index,config.store),
    delete this.ls_store_fields;
      
    var this_ = this;
    //~ var grid = this;
    this.store.on('load', function() {
        //~ console.log('20120814 GridStore.on(load)',this_.store);
        this_.set_param_values(this_.store.reader.arrayData.param_values);
        //~ this_.set_status(this_.store.reader.arrayData.status);
        //~ 20120918
        this.getView().getRowClass = Lino.getRowClass;
        
        if (this_.store.reader.arrayData.no_data_text) {
            //~ this.viewConfig.emptyText = this_.store.reader.arrayData.no_data_text;
            this.getView().emptyText = this_.store.reader.arrayData.no_data_text;
            this.getView().refresh();
        }
        if (this_.containing_window)
            this_.set_window_title(this_.store.reader.arrayData.title);
            //~ this_.containing_window.setTitle(this_.store.reader.arrayData.title);
        if (!this.is_searching) { // disabled 20121025: quick_search_field may not lose focus
          this.is_searching = false;
          if (this_.selModel.getSelectedCell){
              if (this_.getStore().getCount()) // there may be no data
                  this_.selModel.select(0,0); 
          } else {
              this_.selModel.selectFirstRow();
              this_.getView().focusEl.focus();
          }
        } 
        //~ else console.log("is_searching -> no focussing");
        //~ var t = this.getTopToolbar();
        //~ var activePage = Math.ceil((t.cursor + t.pageSize) / t.pageSize);
        //~ this.quick_search_field.focus(); // 20121024
      }, this
    );
    var actions = Lino.build_buttons(this, this.ls_bbar_actions);
    //~ Ext.apply(config,Lino.build_buttons(this,config.ls_bbar_actions));
    //~ config.bbar, this.cmenu = Lino.build_buttons(this,config.ls_bbar_actions);
    //~ this.cmenu = new Ext.menu.Menu({items: config.bbar});
    delete this.ls_bbar_actions
    if (actions) {
        this.cmenu = actions.cmenu;
        this.keyhandlers = actions.keyhandlers;
    }
    
    if (!this.hide_top_toolbar) {  
      var tbar = [ 
        this.quick_search_field = new Ext.form.TextField({ 
          //~ fieldLabel: "Search"
          listeners: { 
            scope:this_
            //~ ,change:this_.search_change
            
            ,render: Lino.quicktip_renderer("Kiirotsing","Enter a text to use as quick search filter")
            
            //~ ,keypress: this.search_keypress 
            ,blur: function() { this.is_searching = false}
          }
          ,validator:function(value) { return this_.search_validate(value) }
          //~ ,tooltip: "Enter a quick search text, then press TAB"
          //~ value: text
          //~ scope:this, 
          //~ ,enableKeyEvents: true
          //~ listeners: { keypress: this.search_keypress }, 
          //~ id: "seachString" 
      })];
      tbar = this.add_params_panel(tbar);
      var menu = [];
      var set_gc = function(index) {
        return function() {
          //~ console.log('set_gc() 20100812');
          this.getColumnModel().setConfig(
              this.apply_grid_config(index,this.ls_grid_configs,this.ls_columns));
        }
      }
      for (var i = 0; i < this.ls_grid_configs.length;i++) {
        var gc = this.ls_grid_configs[i];
        menu.push({text:gc.label,handler:set_gc(i),scope:this})
      }
      if(menu.length > 1) {
        tbar = tbar.concat([
          { text:"View",
            menu: menu,
            tooltip:"Select another view of this report"
          }
        ]);
      }
      
      if (actions) {
        tbar = tbar.concat(actions.bbar);
          //~ this.bbar = actions.bbar;
      }
      
      this.tbar = new Ext.PagingToolbar({ 
        store: this.store, 
        prependButtons: true, 
        //~ pageSize: this.page_length, 
        pageSize: 1, 
        displayInfo: true, 
        beforePageText: "Lehekülg",
        afterPageText: " / {0}",
        displayMsg: "Read  {0} - {1}  ({2}st)",
        firstText: "First page",
        lastText: "Last page",
        prevText: "Previous page",
        nextText: "Next page",
        items: tbar
      });
    }
      
    if (this.cell_edit) {
      this.selModel = new Ext.grid.CellSelectionModel()
      this.get_selected = function() {
        //~ console.log(this.getSelectionModel().selection);
        if (this.selModel.selection)
            return [ this.selModel.selection.record ];
        return [this.store.getAt(0)];
      };
      this.get_current_record = function() { 
        if (this.getSelectionModel().selection) 
          return this.selModel.selection.record;
        return this.store.getAt(0);
      };
    } else { 
      this.selModel = new Ext.grid.RowSelectionModel() 
      this.get_selected = function() {
        var sels = this.selModel.getSelections();
        if (sels.length == 0) sels = [this.store.getAt(0)];
        return sels
      };
      this.get_current_record = function() { 
        var rec = this.selModel.getSelected();
        if (rec == undefined) rec = this.store.getAt(0);
        return rec
      };
    };
    this.columns  = this.apply_grid_config(this.gc_name,this.ls_grid_configs,this.ls_columns);
    
    Lino.GridPanel.superclass.initComponent.call(this);
    
    this.on('resize', function(){
      //~ console.log("20120213 resize",arguments)
      this.refresh();
      },this);
    this.on('viewready', function(){
      //~ console.log("20120213 resize",arguments);
      this.view_is_ready = true;
      this.refresh(); // removed 20130911
      },this);
    this.on('afteredit', this.on_afteredit); // 20120814
    this.on('beforeedit', this.on_beforeedit);
    this.on('beforeedit',function(e) { this.before_row_edit(e.record)},this);
    if (this.cell_edit) {
        this.on('cellcontextmenu', Lino.cell_context_menu, this);
    } else {
        this.on('rowcontextmenu', Lino.row_context_menu, this);
    }
    //~ this.on('contextmenu', Lino.grid_context_menu, this);
    
    delete this.cell_edit;
    
  },
  
  //~ onResize : function(){
      //~ console.log("20120206 GridPanel.onResize",arguments);
      //~ Lino.GridPanel.superclass.onResize.apply(this, arguments);
      //~ this.refresh();
  //~ },
  
  
  get_status : function(){
    var st = { base_params : this.get_base_params()};
    if (!this.hide_top_toolbar) {
        // #866
        if (this.getStore().lastOptions != undefined && this.getStore().lastOptions.params != undefined){
            st.current_page = Math.round(this.getStore().lastOptions.params.start / this.getStore().lastOptions.params.limit ) + 1 ;
        }
    }
    st.param_values = this.status_param_values;
    //~ console.log("20120213 GridPanel.get_status",st);
    return st;
  },
  
  /* 
  Lino.GridPanel.set_status() 
  */
  set_status : function(status, rp){
    this.requesting_panel = Ext.getCmp(rp);
    // console.log("20140527 GridPanel.set_status", status);
    this.clear_base_params();
    if (status == undefined) status = {base_params:{}};
    this.set_param_values(status.param_values);
    if (status.base_params) { 
      this.set_base_params(status.base_params);
    }
    if (status.show_params_panel != undefined) {
        if (this.toggle_params_panel_btn) {
            //~ this.toggle_params_panel_btn.toggle(status.show_params_panel=='true');
            this.toggle_params_panel_btn.toggle(status.show_params_panel);
        }
    }
    if (!this.hide_top_toolbar) {
      //~ console.log("20120213 GridPanel.getTopToolbar().changePage",
          //~ status.current_page || 1);
      this.getTopToolbar().changePage(status.current_page || 1);
    }
    //~ this.fireEvent('resize');
    //~ this.refresh.defer(100,this); 
    //~ this.onResize.defer(100,this); 
    //~ this.refresh(); 
    //~ this.doLayout(); 
    //~ this.onResize(); 
    //~ this.store.load();
  },
  
  refresh : function(unused) { 
    this.refresh_with_after();
  },
  /* GridPanel */
  refresh_with_after : function(after) { 
    // console.log('20140504 Lino.GridPanel.refresh '+ this.store.proxy.url);
    //~ var bp = { fmt:'json' }
    if (! this.view_is_ready) return;
    
    if (this.containing_panel) {
        //~ Ext.apply(p,this.master_panel.get_master_params());
        //~ Ext.apply(options.params,this.containing_panel.get_master_params());
        this.set_base_params(this.containing_panel.get_master_params());
        // 20130911
        if (!this.store.baseParams.mk) {  
            return;
        }
    }
    
    //~ console.log('20130911 Lino.GridPanel.refresh_with_after',this.containing_panel.get_master_params());
    
    var options = {};
    if (after) {
        options.callback = function(r,options,success) {if(success) after()}
    }
      
    //~ if (!this.rendered) {
        //~ console.log("20120206 GridPanel.refresh() must wait until rendered",options);
        //~ this.grid_panel.on('render',this.load.createDelegate(this,options))
        //~ return;
    //~ }
    // Ticket 802
    if (this.store.lastOptions != undefined){
        var params = {};
        params.limit = this.store.lastOptions.params.limit;
        params.start = this.store.lastOptions.params.start;
        options.params = params;
    }
    this.store.load(options);
  },
  
  /* pageSize depends on grid height (Trying to remove scrollbar)
  Thanks to 
  - Christophe Badoit on http://www.sencha.com/forum/showthread.php?82647
  - http://www.sencha.com/forum/archive/index.php/t-37231.html
  */
  calculatePageSize : function(second_attempt) {
    //~ if (!this.rendered) { 
    if (!this.view_is_ready) { 
      //~ console.log('Cannot calculatePageSize() : not rendered');
      return false; }
    //~ if (!this.isVisible()) { 
      //~ console.log('calculatePageSize : not visible');
      //~ return false; }
      
    //~ console.log('getFrameHeight() is',this.getFrameHeight());
    //~ console.log('getView().scroller.getHeight() is',this.getView().scroller.getHeight());
    //~ console.log('mainBody.getHeight() is',this.getView().mainBody.getHeight());
    //~ console.log('getInnerHeight() is',this.getInnerHeight());
    //~ console.log('getHeight() is',this.getHeight());
    //~ console.log('el.getHeight() is',this.getEl().getHeight());
    //~ console.log('getGridEl().getHeight() is',this.getGridEl().getHeight());
    //~ console.log('getOuterSize().height is',this.getOuterSize().height);
    //~ console.log('getBox().height is',this.getBox().height);
    //~ console.log('getResizeEl.getHeight() is',this.getResizeEl().getHeight());
    //~ console.log('getLayoutTarget().getHeight() is',this.getLayoutTarget().getHeight());
      
    // var rowHeight = this.row_height * 11; experimental value 11
    // same as in ext_renderer.py that's not enough because it is the
    // height of one text line. But here we need the outer height of a
    // grid row containing that many text lines.

    var row_content = '&nbsp;'
    for (var i = 0; i < this.row_height;i++) {
        row_content += '<br>';
    }

    var Element = Ext.Element;
    var gv = this.view;
    var fakeBody = new Element(Element.fly(gv.scroller).child('div.x-grid3-body'));
    var rowTemplate = gv.templates.row;
    var cellTemplate = gv.templates.cell;
    var tstyle  = 'width:' + gv.getGridInnerWidth() + 'px;';
    // console.log("20160615", this.fake_row_content);
    var cells = cellTemplate.apply({value:row_content});
    var markup = rowTemplate.apply({
            tstyle: tstyle,
            cols  : 1,
            cells : cells,
            alt   : ''
        });        
    fakeBody.dom.innerHTML = gv.templates.body.apply({rows: markup});
    var row = fakeBody.dom.childNodes[0];
    var rowHeight = Ext.get(row).getHeight();

    //~ console.log('rowHeight is ',rowHeight,this,caller);
    //~ this.getView().syncScroll();
    //~ this.getView().initTemplates();
    var height = this.getView().scroller.getHeight();

    //~ console.log('getView().scroller.getHeight() is',this.getView().scroller.getHeight());
    //~ console.log('getInnerHeight() - getFrameHeight() is',
      //~ this.getInnerHeight(), '-',
      //~ this.getFrameHeight(), '=',
      //~ this.getInnerHeight() - this.getFrameHeight());
    //~ var height = this.getView().mainBody.getHeight();
    //~ var height = this.getView().mainWrap.getHeight();
    //~ var height = this.getView().resizeMarker.getHeight();
    //~ this.syncSize();
    //~ var height = this.getInnerHeight() - this.getFrameHeight();
    //~ var height = this.getHeight() - this.getFrameHeight();
    height -= Ext.getScrollBarWidth(); // leave room for a possible horizontal scrollbar... 
    //~ height -= this.getView().scrollOffset;
    var ps = Math.floor(height / rowHeight);
    //~ console.log('20130816 calculatePageSize():',height,'/',rowHeight,'->',ps);
    ps -= 1; // leave room for a possible phantom row
    //~ return (ps > 1 ? ps : false);
    if (ps > 1) return ps;
    //~ console.log('calculatePageSize() found less than 1 row:',height,'/',rowHeight,'->',ps);
    //~ foo.bar = baz; // 20120213
    return 5; // preview_limit
    //~ if (second_attempt) {
        //~ console.log('calculatePageSize() abandons after second attempt:',
          //~ height,'/',rowHeight,'->',ps);
      //~ return 5;
    //~ }
    //~ return this.calculatePageSize.defer(500,this,[true]);
  },
  
  onCellDblClick : function(grid, row, col){
      //~ console.log("20120307 onCellDblClick",this,grid, row, col);
      if (this.ls_detail_handler) {
          //~ Lino.notify('show detail');
          Lino.show_detail(this);
          return false;
      }else{
        //~ console.log('startEditing');
        this.startEditing(row,col);
      }
  },
  get_base_params : function() {  /* Lino.GridPanel */
    var p = Ext.apply({}, this.store.baseParams);
    Lino.insert_subst_user(p);
    // if (this.quick_search_field)
    //     if (this.quick_search_field.getValue())
    //         p.query = this.quick_search_field.getValue();
    return p;
  },
  set_base_params : function(p) {
    // console.log('20130911 GridPanel.set_base_params',p)
    for (k in p) this.store.setBaseParam(k,p[k]);
    //~ this.store.baseParams = p;
    if (this.quick_search_field)
      this.quick_search_field.setValue(p.query || "");
    //~ if (p.param_values) 
        //~ this.set_param_values(p.param_values);  
  },
  clear_base_params : function() {
      this.store.baseParams = {};
      Lino.insert_subst_user(this.store.baseParams);
  },
  set_base_param : function(k,v) {
    this.store.setBaseParam(k,v);
  },
  
  //~ get_permalink_params : function() {
    //~ var p = {};
    //~ return p;
  //~ },
  
  before_row_edit : function(record) {},
    
  //~ search_keypress : function(){
    //~ console.log("2012124 search_keypress",arguments);
  //~ },
  search_validate : function(value) {
    if (value == this.quick_search_text) return true;
    this.is_searching = true;
    //~ console.log('search_validate',value)
    this.quick_search_text = value;
    this.set_base_param('query',value); 
    //~ this.getTopToolbar().changePage(1);
    this.getTopToolbar().moveFirst();
    //~ this.refresh();
    return true;
  },
  
  search_change : function(field,oldValue,newValue) {
    //~ console.log('search_change',field.getValue(),oldValue,newValue)
    this.set_base_param('query',field.getValue()); 
    this.getTopToolbar().moveFirst();
    //~ this.refresh();
  },
  
  apply_grid_config : function(index,grid_configs,rpt_columns) {
    //~ var rpt_columns = this.ls_columns;
    var gc = grid_configs[index];    
    //~ console.log('apply_grid_config() 20100812',name,gc);
    this.gc_name = index;
    if (gc == undefined) {
      return rpt_columns;
      //~ config.columns = config.ls_columns;
      //~ return;
    } 
    //~ delete config.ls_filters
    
    //~ console.log(20100805,config.ls_columns);
    var columns = Array(gc.columns.length);
    for (var j = 0; j < rpt_columns.length;j++) {
      var col = rpt_columns[j];
      for (var i = 0; i < gc.columns.length; i++) {
        if (col.dataIndex == gc.ci[i]) {
          col.width = gc.cw[i];
          col.hidden = gc.ch[i];
          columns[i] = col;
          break;
        }
      }
    }
    
    //~ var columns = Array(rpt_columns.length);
    //~ for (var i = 0; i < rpt_columns.length; i++) {
      //~ columns[i] = rpt_columns[gc.columns[i]];
      //~ columns[i].width = gc.widths[i];
    //~ }
    
    //~ if (gc.hidden_cols) {
      //~ for (var i = 0; i < gc.hidden_cols.length; i++) {
        //~ var hc = gc.hidden_cols[i];
        //~ for (var j = 0; j < columns.length;j++) {
          //~ var col = columns[j];
          //~ if (col.dataIndex == hc) {
            //~ col.hidden = true;
            //~ break
          //~ }
        //~ }
      //~ }
    //~ }
    if (gc.filters) {
      //~ console.log(20100811,'config.ls_filters',config.ls_filters);
      //~ console.log(20100811,'config.ls_grid_config.filters',config.ls_grid_config.filters);
      for (var i = 0; i < gc.filters.length; i++) {
        var fv = gc.filters[i];
        for (var j = 0; j < columns.length;j++) {
          var col = columns[j];
          if (col.dataIndex == fv.field) {
            //~ console.log(20100811, f,' == ',fv);
            if (fv.type == 'string') {
              col.filter.value = fv.value;
              //~ if (fv.comparison !== undefined) f.comparison = fv.comparison;
            } else {
              //~ console.log(20100811, fv);
              col.filter.value = {};
              col.filter.value[fv.comparison] = fv.value;
            }
            break;
          }
        };
      }
    }
    
    return columns;
    //~ config.columns = cols;
    //~ delete config.ls_columns
  },
  
  get_current_grid_config : function () {
    var cm = this.getColumnModel();
    var widths = Array(cm.config.length);
    var hiddens = Array(cm.config.length);
    //~ var hiddens = Array(cm.config.length);
    var columns = Array(cm.config.length);
    //~ var columns = Array(cm.config.length);
    //~ var hidden_cols = [];
    //~ var filters = this.filters.getFilterValues();
    var p = this.filters.buildQuery(this.filters.getFilterData())
    for (var i = 0; i < cm.config.length; i++) {
      var col = cm.config[i];
      columns[i] = col.dataIndex;
      //~ hiddens[i] = col.hidden;
      widths[i] = col.width;
      hiddens[i] = col.hidden;
      //~ if (col.hidden) hidden_cols.push(col.dataIndex);
    }
    //~ p['hidden_cols'] = hidden_cols;
    p.cw = widths;
    p.ch = hiddens;
    p.ci = columns;
    //~ p['widths'] = widths;
    //~ p['hiddens'] = hiddens;
    //~ p['columns'] = columns;
    p['name'] = this.gc_name;
    //~ var gc = this.ls_grid_configs[this.gc_name];
    //~ if (gc !== undefined) 
        //~ p['label'] = gc.label
    //~ console.log('20100810 save_grid_config',p);
    return p;
  },
  
  unused_manage_grid_configs : function() {
    var data = [];
    for (k in this.ls_grid_configs) {
      var v = this.ls_grid_configs[k];
      var i = [k,String(v.columns),String(v.hidden_cols),String(v.filters)];
      data.push(i)
    }
    if (this.ls_grid_configs[this.gc_name] == undefined) {
      var v = this.get_current_grid_config();
      var i = [k,String(v.columns),String(v.hidden_cols),String(v.filters)];
      data.push(i);
    }
    //~ console.log(20100811, data);
    var main = new Ext.grid.GridPanel({
      store: new Ext.data.ArrayStore({
        idIndex:0,
        fields:['name','columns','hidden_cols','filters'],
        autoDestroy:true,
        data: data}),
      //~ autoHeight:true,
      selModel: new Ext.grid.RowSelectionModel(),
      listeners: { 
        rowdblclick: function(grid,rowIndex,e) {
          console.log('row doubleclicked',grid, rowIndex,e);
        },
        rowclick: function(grid,rowIndex,e) {
          console.log('row clicked',grid, rowIndex,e);
        }
      },
      columns: [ 
        {dataIndex:'name',header:'Name'}, 
        {dataIndex:'columns',header:'columns'}, 
        {dataIndex:'hidden_cols',header:'hidden columns'}, 
        {dataIndex:'filters',header:'filters'} 
      ]
    });
    var win = new Ext.Window({title:'GridConfigs Manager',layout:'fit',items:main,height:200});
    win.show();
  },
  
  unused_edit_grid_config : function(name) {
    gc = this.ls_grid_configs[name];
    var win = new Ext.Window({
      title:'Edit Grid Config',layout:'vbox', 
      //~ layoutConfig:'stretch'
      items:[
        {xtype:'text', value: gc.name},
        {xtype:'text', value: gc.columns},
        {xtype:'text', value: gc.hidden_cols},
        {xtype:'text', value: gc.filters}
      ]
    });
    win.show();
  },
  
  unused_save_grid_config : function () {
    //~ console.log('TODO: save_grid_config',this);
    //~ p.column_widths = Ext.pluck(this.colModel.columns,'width');
    var a = { 
      params:this.get_current_grid_config(), 
      method:'PUT',
      url:'/grid_config' + this.ls_url,
      success: Lino.action_handler(this),
      scope: this,
      failure: Lino.ajax_error_handler(this)
    };
    this.loadMask.show(); // 20120211
    Ext.Ajax.request(a);
    //~ Lino.do_action(this,a);
  },
  
  on_beforeedit : function(e) {
    //~ console.log('20130128 GridPanel.on_beforeedit()',e,e.record.data.disable_editing);
    if(this.disable_editing | e.record.data.disable_editing) {
      e.cancel = true;
      Lino.notify("This record is disabled");
      return;
    }
    if(e.record.data.disabled_fields && e.record.data.disabled_fields[e.field]) {
      e.cancel = true;
      Lino.notify("This field is disabled");
      return;
    }
    //~ if (e.record.data.disabled_fields) {
      //~ for (i in e.record.data.disabled_fields) {
        //~ if(e.record.data.disabled_fields[i] == e.field) {
          //~ e.cancel = true;
          //~ Lino.notify(String.format('Field "{0}" is disabled for this record',e.field));
          //~ return
        //~ }
      //~ }
    //~ }
  },
  save_grid_data : function() {
      //~ console.log("20120814 save_grid_data");
      this.getStore().commitChanges();
  },
  on_afteredit : function(e) {
    /*
    e.grid - The grid that fired the event
    e.record - The record being edited
    e.field - The field name being edited
    e.value - The value being set
    e.originalValue - The original value for the field, before the edit.
    e.row - The grid row index
    e.column - The grid column index
    */
    var p = {};
    // console.log('20140403 afteredit: ',e.record);
    //~ console.log('20101130 value: ',e.value);
    //~ var p = e.record.getChanges();
    //~ console.log('20101130 getChanges: ',e.record.getChanges());
    //~ this.before_row_edit(e.record);

    for(k in e.record.getChanges()) {
        var v = e.record.get(k);
    //~ for(k in e.record.modified) {
        //~ console.log('20101130',k,'=',v);
        //~ var cm = e.grid.getColumnModel();
        //~ var di = cm.getDataIndex(k);
        var f = e.record.fields.get(k);
        //~ console.log('20101130 f = ',f);
        //~ var v = e.record.get(di);
        if (f.type.type == 'date') {
            p[k] = Ext.util.Format.date(v, f.dateFormat);
        }else{
            p[k] = v;
            var v = e.record.get(k+'Hidden');
            if (v !== undefined) {
              p[k+'Hidden'] = v;
            }
        }
    }
    // add value used by ForeignKeyStoreField CHOICES_HIDDEN_SUFFIX
    // not sure whether this is still needed:
    p[e.field+'Hidden'] = e.value;
    //~ p.su = Lino.subst_user;
    Lino.insert_subst_user(p);
    // this one is needed so that this field can serve as choice context:
    e.record.data[e.field+'Hidden'] = e.value;
    // p[pk] = e.record.data[pk];
    // console.log("grid_afteredit:",e.field,'=',e.value);
    Ext.apply(p, this.get_base_params()); // needed for POST, ignored for PUT
    //~ Ext.apply(p,this.containing_window.config.base_params);
    //~ 20121109 p['$constants.URL_PARAM_ACTION_NAME'] = 'grid';
    var self = this;
    var req = {
        params:p,
        waitMsg: 'Saving your data...',
        success: Lino.action_handler( this, function(result) {
          // console.log("20140728 afteredit.success got ", result);
          //~ if (result.data_record) {
          if (result.refresh_all) {
              var cw = self.get_containing_window();
              if (cw) {
                  cw.main_item.refresh();
              }
              else console.log("20120123 cannot refresh_all",self);
          } else if (result.rows) {
              //~ self.getStore().loadData(result,true);
              var r = self.getStore().reader.readRecords(result);
              if (e.record.phantom) {
                  // console.log("20140728 gonna call Store.insert()", self.getStore(), e.row, r.records);
                  self.getStore().insert(e.row, r.records);
              }else{
                  // console.log("20140728 afteredit.success doUpdate", r.records[0]);
                  self.getStore().doUpdate(r.records[0]);
              }
              self.getStore().rejectChanges(); 
              /* 
              get rid of the red triangles without saving the record again
              */
              //~ self.getStore().commitChanges(); // get rid of the red triangles
          } else {
              self.getStore().commitChanges(); // get rid of the red triangles
              self.getStore().reload();        // reload our datastore.
          }
          }),
        scope: this,
        failure: Lino.ajax_error_handler(this)
    };
    if (e.record.phantom) {
      req.params.an = 'grid_post'; // CreateRow.action_name
      Ext.apply(req,{
        method: 'POST',
        url: '/api' + this.ls_url
      });
    } else {
      req.params.an = 'grid_put'; // SaveRow.action_name
      Ext.apply(req,{
        method: 'PUT',
        url: '/api' + this.ls_url + '/' + e.record.id
      });
    }
    //~ console.log('20110406 on_afteredit',req);
    this.loadMask.show(); // 20120211
    Ext.Ajax.request(req);
  },

  afterRender : function() {
    Lino.GridPanel.superclass.afterRender.call(this);
    // this.getView().mainBody.focus();
    // console.log(20100114,this.getView().getRows());
    // if (this.getView().getRows().length > 0) {
    //  this.getView().focusRow(1);
    // }
    //~ this.my_load_mask = new Ext.LoadMask(this.getEl(), {
        //~ msg:'$_("Please wait...")',
        //~ store:this.store});
      
    var tbar = this.getTopToolbar();
    // tbar.on('change',function() {this.getView().focusRow(1);},this);
    // tbar.on('change',function() {this.getSelectionModel().selectFirstRow();this.getView().mainBody.focus();},this);
    // tbar.on('change',function() {this.getView().mainBody.focus();},this);
    // tbar.on('change',function() {this.getView().focusRow(1);},this);
    this.nav = new Ext.KeyNav(this.getEl(),{
      pageUp: function() {tbar.movePrevious(); },
      pageDown: function() {tbar.moveNext(); },
      home: function() {tbar.moveFirst(); },
      end: function() {tbar.moveLast(); },
      scope: this
    });

  },
  after_delete : function() {
    //~ console.log('Lino.GridPanel.after_delete');
    this.refresh();
  },
  add_row_listener : function(fn,scope) {
    this.getSelectionModel().addListener('rowselect',fn,scope);
  },
  postEditValue : function(value, originalValue, r, field){
    value = Lino.GridPanel.superclass.postEditValue.call(this,value,originalValue,r,field);
    //~ console.log('GridPanel.postEdit()',value, originalValue, r, field);
    return value;
  },
  
  set_start_value : function(v) {
      this.start_value = v;
  },
  preEditValue : function(r, field){
      if (this.start_value) {
        var v = this.start_value;
        delete this.start_value;
        this.activeEditor.selectOnFocus = false;
        return v;
      }
      var value = r.data[field];
      return this.autoEncode && Ext.isString(value) ? Ext.util.Format.htmlDecode(value) : value;
  },
  
  on_master_changed : function() {
    //~ if (! this.enabled) return;
    //~ cmp = this;
    //~ console.log('20130911 Lino.GridPanel.on_master_changed()',this.title,this.rendered);
    if (! this.rendered) return; // 20120213
    var todo = function() {
      if (this.disabled) return;
      //~ if (this.disabled) return;
      //~ if (this.enabled) {
          //~ var src = caller.config.url_data + "/" + record.id + ".jpg"
          //~ console.log(20111125, this.containing_window);
          //~ for (k in p) this.getStore().setBaseParam(k,p[k]);
          //~ console.log('Lino.GridPanel.on_master_changed()',this.title,p);
          this.refresh();
          //~ this.set_base_params(this.master_panel.get_master_params());
          //~ this.getStore().load(); 
      //~ }
    };
    Lino.do_when_visible(this,todo.createDelegate(this));
  },
  load_record_id : function(record_id,after) {
      Lino.run_detail_handler(this,record_id)
  }
  
});
  

//~ Lino.MainPanelMixin = {
  //~ tbar_items : function() {
      //~ return ;
  //~ }
//~ };

//~ Ext.override(Lino.GridPanel,Lino.MainPanelMixin);
//~ Ext.override(Lino.FormPanel,Lino.MainPanelMixin);

//~ Lino.grid_context_menu = function(e) {
  //~ console.log('contextmenu',arguments);
//~ }

Lino.row_context_menu = function(grid,row,col,e) {
  console.log('20130927 rowcontextmenu',grid,row,col,e,grid.store.reader.arrayData.rows[row]);
}

Lino.cell_context_menu = function(grid,row,col,e) {
  //~ console.log('20120531 cellcontextmenu',grid,row,col,e,grid.store.reader.arrayData.rows[row]);
  e.stopEvent();
  //~ grid.getView().focusCell(row,col);
  grid.getSelectionModel().select(row,col);
  //~ console.log(grid.store.getAt(row));
  //~ grid.getView().focusRow(row);
  //~ return;
  if(!grid.cmenu.el){grid.cmenu.render(); }
  //~ if(e.record.data.disabled_fields) {
  
  var da = grid.store.reader.arrayData.rows[row][grid.disabled_actions_index];
  if (da) {
      this.cmenu.cascade(function(item){ 
        //~ console.log(20120531, item.itemId, da[item.itemId]);
        if (da[item.itemId]) item.disable(); else item.enable();
      });
  };
  
  var xy = e.getXY();
  xy[1] -= grid.cmenu.el.getHeight();
  grid.cmenu.showAt(xy);
}


Lino.chooser_handler = function(combo,name) {
  return function(cmp, newValue, oldValue) {
    //~ console.log('Lino.chooser_handler()',cmp,oldValue,newValue);
    combo.setContextValue(name, newValue);
  }
};



Lino.ComboBox = Ext.extend(Ext.form.ComboBox,{
  forceSelection: "yes but select on tab",
  // forceSelection: true,
  triggerAction: 'all',
  minListWidth:280, // 20131022
  autoSelect: false,
  selectOnFocus: true, // select any existing text in the field immediately on focus.
  submitValue: true,
  displayField: 'text', // 'text', 
  valueField: 'value', // 'value',
  
  //~ initComponent : Ext.form.ComboBox.prototype.initComponent.createSequence(function() {
  initComponent : function(){
      this.contextParams = {};
      //~ Ext.form.ComboBox.initComponent(this);
      Lino.ComboBox.superclass.initComponent.call(this);
  },
  setValue : function(v, record_data){
      /*
      Based on feature request developed in http://extjs.net/forum/showthread.php?t=75751
      */
      /* `record_data` is used to get the text corresponding to this value */
      //~ if(this.name == 'city') 
      //~ console.log('20120203', this.name,'.setValue(', v ,') this=', this,'record_data=',record_data);
      var text = v;
      if(this.valueField){
        if(v == null || v == '') { 
            //~ if (this.name == 'birth_country') 
                //~ console.log(this.name,'.setValue',v,'no lookup needed, value is empty');
            //~ v = undefined;
            v = '';
            //~ text = '';
        } else if (Ext.isDefined(record_data)) {
          text = record_data[this.name];
          //~ if (this.name == 'birth_country') 
            //~ console.log(this.name,'.setValue',v,'got text ',text,' from record ',record);
        } else {
          // if(this.mode == 'remote' && !Ext.isDefined(this.store.totalLength)){
          if(this.mode == 'remote' && ( this.lastQuery === null || (!Ext.isDefined(this.store.totalLength)))){
              //~ if (this.name == 'birth_country') console.log(this.name,'.setValue',v,'store not yet loaded');
              this.store.on('load', this.setValue.createDelegate(this, arguments), null, {single: true});
              if(this.store.lastOptions === null || this.lastQuery === null){
                  var params;
                  if(this.valueParam){
                      params = {};
                      params[this.valueParam] = v;
                  }else{
                      var q = this.allQuery;
                      this.lastQuery = q;
                      this.store.setBaseParam(this.queryParam, q);
                      params = this.getParams(q);
                  }
                  //~ if (this.name == 'birth_country') 
                    //~ console.log(this.name,'.setValue',v,' : call load() with params ',params);
                  this.store.load({params: params});
              //~ }else{
                  //~ if (this.name == 'birth_country') 
                    //~ console.log(this.name,'.setValue',v,' : but store is loading',this.store.lastOptions);
              }
              return;
          //~ }else{
              //~ if (this.name == 'birth_country') 
                //~ console.log(this.name,'.setValue',v,' : store is loaded, lastQuery is "',this.lastQuery,'"');
          }
          var r = this.findRecord(this.valueField, v);
          if(r){
              text = r.data[this.displayField];
          }else if(this.valueNotFoundText !== undefined){
              text = this.valueNotFoundText;
          }
        }
      }
      this.lastSelectionText = text;
      //~ this.lastSelectionText = v;
      if(this.hiddenField){
          //~ this.hiddenField.originalValue = v;
          this.hiddenField.value = v;
      }
      Ext.form.ComboBox.superclass.setValue.call(this, text);
      this.value = v; // needed for grid.afteredit
  },
  
  getParams : function(q){
    // p = Ext.form.ComboBox.superclass.getParams.call(this, q);
    // causes "Ext.form.ComboBox.superclass.getParams is undefined"
    var p = {};
    if(this.pageSize){
        p['start'] = 0;
        p['limit'] = this.pageSize;
    }
    // now my code:
    if(this.contextParams) Ext.apply(p, this.contextParams);
    return p;
  },
  setContextValue : function(name,value) {
    //~ console.log('setContextValue',this,this.name,':',name,'=',value);
    //~ if (this.contextValues === undefined) {
        //~ this.contextValues = Array(); // this.contextParams.length);
    //~ }
    if (this.contextParams[name] != value) {
      //~ console.log('setContextValue 1',this.contextParams);
      this.contextParams[name] = value;
      this.lastQuery = null;
      //~ console.log('setContextValue 2',this.contextParams);
    }
  }
});

Lino.ChoicesFieldElement = Ext.extend(Lino.ComboBox,{
  mode: 'local'
});


Lino.SimpleRemoteComboStore = Ext.extend(Ext.data.JsonStore,{
  // forceSelection: true,  20140206 why was this here?
  constructor: function(config){
      Lino.SimpleRemoteComboStore.superclass.constructor.call(this, Ext.apply(config, {
          totalProperty: 'count',
          root: 'rows',
          id: 'value', // 'value'
          fields: ['value' ], 
          listeners: { exception: Lino.on_store_exception }
      }));
  }
});

Lino.ComplexRemoteComboStore = Ext.extend(Ext.data.JsonStore,{
  constructor: function(config){
      Lino.ComplexRemoteComboStore.superclass.constructor.call(this, Ext.apply(config, {
          totalProperty: 'count',
          root: 'rows',
          id: 'value', // constants.CHOICES_VALUE_FIELD
          fields: ['value','text'], // constants.CHOICES_VALUE_FIELD, // constants.CHOICES_TEXT_FIELD
          listeners: { exception: Lino.on_store_exception }
      }));
  }
});

Lino.RemoteComboFieldElement = Ext.extend(Lino.ComboBox,{
  mode: 'remote',
  //~ forceSelection:false,
  minChars: 2, // default 4 is too much
  queryDelay: 300, // default 500 is maybe slow
  queryParam: 'query', 
  //~ typeAhead: true,
  //~ selectOnFocus: true, // select any existing text in the field immediately on focus.
  resizable: true
  ,initList : function() {
      Lino.RemoteComboFieldElement.superclass.initList.call(this);
      if (this.pageTb) {
          
          var me = this;
          this.pageTb.on("beforechange", function(toolbar, o){
              if(me.contextParams)
                  Ext.apply(o, me.contextParams);
          });
          
          //~ 
          //~ var btn = ls_buttons
          //~ this.pageTb.items = this.pageTb.items.concat([btn]);
          //~ console.log("20131022 pageTb.items is", this.pageTb.items)
      }
  }
});

/*
Thanks to Animal for posting the basic idea:
http://www.sencha.com/forum/showthread.php?15842-2.0-SOLVED-Combobox-twintrigger-clear&p=76130&viewfull=1#post76130

*/
Lino.TwinCombo = Ext.extend(Lino.RemoteComboFieldElement,{
    trigger2Class : 'x-form-search-trigger',
    //~ trigger2Class : 'x-tbar-detail',
    initComponent : function() {
        //~ Lino.TwinCombo.superclass.initComponent.call(this);
        Lino.ComboBox.prototype.initComponent.call(this);
        Ext.form.TwinTriggerField.prototype.initComponent.call(this);
    },
    onTrigger2Click : function() {
        //~ console.log('onTrigger2Click',this,arguments);
    }
  });
//~ Lino.TwinCombo.prototype.initComponent = Ext.form.TwinTriggerField.prototype.initComponent;
Lino.TwinCombo.prototype.getTrigger = Ext.form.TwinTriggerField.prototype.getTrigger;
Lino.TwinCombo.prototype.getOuterSize = Ext.form.TwinTriggerField.prototype.getOuterSize;
Lino.TwinCombo.prototype.initTrigger = Ext.form.TwinTriggerField.prototype.initTrigger;
Lino.TwinCombo.prototype.onTrigger1Click = Ext.form.ComboBox.prototype.onTriggerClick;
//~ Lino.TwinCombo.prototype.onTrigger2Click = function() {
    //~ console.log('onTrigger2Click',arguments);
//~ };



Lino.SimpleRemoteComboFieldElement = Ext.extend(Lino.RemoteComboFieldElement,{
  displayField: 'value', 
  valueField: null,
  forceSelection: false
});




Lino.Window = Ext.extend(Ext.Window,{
  //~ layout: "fit", 
  closeAction : 'hide',
  renderTo: 'main_area', 
  constrain: true,
  maximized: true,
  draggable: false,
  width: 700,
  height: 500,
  maximizable: false,
  constructor : function (config) {
    if (config.main_item.params_panel) {
        config.layout = 'border';
        config.main_item.region = 'center';
        config.main_item.params_panel.region = 'north';
        //~ config.main_item.params_panel.autoHeight = false; // 20130924
        config.main_item.params_panel.hidden = config.main_item.params_panel_hidden;
        config.items = [config.main_item.params_panel, config.main_item];
        //~ 20130923b
    } else {
        config.layout = 'fit';
        config.items = config.main_item;
    }
    this.main_item = config.main_item; 

    if (typeof config.width == "string" && config.width.slice(-1) == "%") {
        config.width = Lino.perc2width(parseInt(config.width.slice(0, -1)));
    }
    
    delete config.main_item;
    //~ delete config.params_item;
    
    //~ this.main_item = config.items.get(0);
    this.main_item.containing_window = this;
    
    //~ console.log('20120110 Lino.Window.constructor() 1');
    //~ if (Lino.current_window) { // all windows except the top are closable
    if (this.main_item.hide_window_title) { 
      config.closable = false;
      config.frame = false;
      config.shadow = false;
      //~ config.border = true;
      //~ config.title = undefined;
      //~ config.tools = null;
      delete config.title;
      delete config.tools;
    } else {
      config.title = this.main_item.empty_title;
      config.closable = true;
      config.tools = [ 
        { qtip: 'permalink', handler: Lino.permalink_handler(this), id: "pin" }
      ];
      if (this.main_item.content_type && this.main_item.action_name != 'insert') {
        config.tools = [ {
          handler: Lino.help_text_editor,
          qtip: "Edit help texts for fields on this model.",
          scope: this.main_item,
          id: "gear"
        }].concat(config.tools);
      }
        
    //~ { qtip: '', handler: Lino.save_wc_handler(this), id: "save" }, 
    //~ { qtip: this.config.qtip, handler: Lino.save_wc_handler(this), id: "save" }, 
    //~ { qtip: 'Call doLayout() on main Container.', handler: Lino.refresh_handler(this), id: "refresh" },
    //~ if (this.main_item.params_panel) {
        //~ config.tools = config.tools.concat([ 
          //~ { qtip: 'Show/hide parameter panel', handler: this.toggle_params_panel, id: "gear", scope:this } 
        //~ ]);
    //~ }
    //~ if (config.closable !== false) {
      // if undefined, will take default behaviour
      //~ config.tools = config.tools.concat([ 
        //~ { qtip: 'close', handler: this.hide, id: "close", scope:this } 
      //~ ]);
    }
    
    this.main_item.config_containing_window(config);
    
    // console.log('20150514 Lino.Window.constructor() 2');
    Lino.Window.superclass.constructor.call(this, config);
    
    //~ console.log('20120110 Lino.Window.constructor() 3');
    
  },
  initComponent : function() {
    this.main_item.init_containing_window(this);
    Lino.Window.superclass.initComponent.call(this);
  
  },
  hide : function() { 
      this.main_item.do_when_clean(false,function() { 
        Lino.close_window(); });
  },
  hide_really : function() { 
    Lino.Window.superclass.hide.call(this);
  },
  onRender : function(ct, position){
    // console.log('20140829 Lino.Window.onRender() 1');
    Lino.Window.superclass.onRender.call(this, ct, position);
    var main_area = Ext.getCmp('main_area')
    //~ console.log('20120110 Lino.Window.onRender() 2');
  
    this.on('show', function(win) {
        // console.log('20140829 Lino.Window.on(show) : add resize handler');
        main_area.on('resize', win.onWindowResize, win);
    });
    this.on('hide', function(win) {
        // console.log('20140829 Lino.Window.on(hide) : remove resize handler');
        main_area.un('resize', win.onWindowResize, win);
    });
    // console.log('20140829 Lino.Window.onRender() 3');
  }
});


Ext.override(Ext.form.BasicForm,{
    my_loadRecord : function(record_data){
    //~ loadRecord : function(record){
        /* Same as ExtJS's loadRecord() (setValues()), except that we
        forward also the record_data to field.setValue(). This second
        parameter is used by Lino.Combobox.
        */
        //~ console.log('20120918 my_loadRecord', record_data)
        if(Ext.isArray(record_data)){ 
            for(var i = 0, len = record_data.length; i < len; i++){
                var v = record_data[i];
                var f = this.findField(v.id);
                if(f){
                    f.setValue(v.value, record_data);
                    if(this.trackResetOnLoad){
                        f.originalValue = f.getValue();
                    }
                }
            }
        }else{ 
            var field, id;
            for(id in record_data){
                if(!Ext.isFunction(record_data[id]) && (field = this.findField(id))){
                    field.setValue(record_data[id], record_data);
                    if(this.trackResetOnLoad){
                        field.originalValue = field.getValue();
                        //~ if (field.hiddenField) {
                          //~ field.hiddenField.originalValue = field.hiddenField.value;
                        //~ }
                    }
                }
            }
        }
        return this;
    }
});




function initializeFooBarDropZone(cmp) {
    //~ console.log('initializeFooBarDropZone',cmp);
    cmp.dropTarget = new Ext.dd.DropTarget(cmp.bwrap, {
      //~ ddGroup     : 'gridDDGroup',
      notifyEnter : function(ddSource, e, data) {
        console.log('notifyEnter',ddSource,e,data);
        //Add some flare to invite drop.
        cmp.body.stopFx();
        cmp.body.highlight();
      },
      notifyDrop  : function(ddSource, e, data){
        console.log('notifyDrop',ddSource,e,data);
        // Reference the record (single selection) for readability
        //~ var selectedRecord = ddSource.dragData.selections[0];


        // Load the record into the form
        //~ formPanel.getForm().my_loadRecord(selectedRecord);


        // Delete record from the grid.  not really required.
        //~ ddSource.grid.store.remove(selectedRecord);

        return(true);
      }
    })
}



Lino.show_mti_child = function(fieldname,detail_handler) {
  //~ console.log('show_mti_child',this);
  //~ console.log('show_mti_child',panel.find("main_area"));
  rec = Lino.current_window.main_item.get_current_record();
  //~ rec = panel.get_current_record();
  if (rec) {
    //~ console.log('show_mti_child',Lino.current_window,rec);
    if (rec.phantom) {
      Lino.notify('Not allowed on phantom record.');
    }else if (rec.data[fieldname]) {
      //~ console.log('show_mti_child',rec.id);
      //~ detail_handler(Lino.current_window.main_item,{},{record_id:rec.id});
      detail_handler.run(null,{record_id:rec.id});
      //~ window.open(urlroot + '/' + rec.id);
      //~ document.location = urlroot + '/' + rec.id;
      //~ window.open(urlroot + '/' + rec.id,'_blank');
    } else {
      Lino.alert("Cannot show MTI child if checkbox is off.");
    }
  } else {
    Lino.notify('No current record.');
  }
};


/*
captureEvents utility by Aaron Conran
<http://www.sencha.com/learn/grid-faq/>

Ext.onReady(function(){
    var grid = new Ext.grid.GridPanel({
        ... 
    });
    captureEvents(grid);
});
*/
function captureEvents(observable) {
    Ext.util.Observable.capture(
        observable,
        function(eventName) {
            console.info(eventName);
        },
        this
    );		
}

// settings.SITE.get_plugin_snippets()




// from lino_xl.lib.extensible (media_name=extensible-1.0.1):snippets/extensible.js

/*
  This is the `extensible.js` snippet. 
  Used in lino.modlib.extensible.App.site_js_snippets
*/

/*
Mappings towards lino.modlib.extensible.models.PanelCalendars
*/
// Sset SS = Ssite.modules.extensible.PanelCalendars.get_handle(Sui).store
Ext.ensible.cal.CalendarMappings = {
    CalendarId:   {name:'ID',       mapping: 'id', type: 'int'},
    Title:        {name:'CalTitle', mapping: 'summary', type: 'string'},
    Description:  {name:'Desc',     mapping: 'description', type: 'string'},
    ColorId:      {name:'Color',    mapping: 'color', type: 'int'},
    IsHidden:     {name:'Hidden',   mapping: 'is_hidden', type: 'boolean'},    
};
Ext.ensible.cal.CalendarRecord.reconfigure();  


/*
Mappings towards lino.modlib.extensible.models.PanelEvents 
*/
// Sset SS = Ssite.modules.extensible.PanelEvents.get_handle(Sui).store
Ext.ensible.cal.EventMappings = {
    EventId:     {name: 'ID',        mapping: 'id', type:'int'},
    CalendarId:  {name: 'CalID',     mapping: 'calendarHidden', type: 'int'},
    Title:       {name: 'EvtTitle',  mapping: 'summary'},
    StartDate:   {name: 'StartDt',   mapping: 'start_dt', 
      type: 'date', 
      dateFormat: "Y-m-d\TH:i:s" },
    EndDate:     {name: 'EndDt',     mapping: 'end_dt', 
      type: 'date', 
      dateFormat: "Y-m-d\TH:i:s"},
    RRule:       {name: 'RecurRule', mapping: 'rsetHidden'},
    Location:    {name: 'Location',  mapping: 'placeHidden'},
    Notes:       {name: 'Desc',      mapping: 'description'},
    Url:         {name: 'LinkUrl',   mapping: 'url'},
    IsAllDay:    {name: 'AllDay',    mapping: 'all_day', type: 'boolean'},
    Reminder:    {name: 'Reminder',  mapping: 'reminder'}
    
};
Ext.ensible.cal.EventRecord.reconfigure();


//~ Lino.on_eventclick = 
    
Lino.on_editdetails = 

Lino.format_time = function(dt) {
    return dt.getHours() + ':' + dt.getMinutes();
}
    
Lino.on_eventdelete = function() {
  //~ console.log("Lino.on_eventdelete",arguments);
};

Lino.on_eventadd  = function(cp,rec,el) {
  //~ console.log("Lino.on_eventadd ",arguments);
  return false;
}
    
Lino.on_eventresize  = function(cp,rec,el) {
  //~ console.log("Lino.on_eventresize ",arguments);
  //~ Lino.cal.Events.insert(cp);
  //~ return false;
}
    
Lino.on_eventupdate  = function(cp,rec,el) {
  //~ console.log("Lino.on_eventupdate",arguments);
  //~ Lino.cal.Events.insert(cp);
  //~ return false;
}
    

//~ Lino.eventStore = new Ext.ensible.cal.EventStore({ 
//~ Lino.eventStore = new Ext.data.ArrayStore({ 
Lino.unused_eventStore = new Ext.data.JsonStore({ 
  listeners: { exception: Lino.on_store_exception }
  ,url: '/restful/extensible/PanelEvents'
  ,restful : true
  ,proxy: new Ext.data.HttpProxy({ 
      url: '/restful/extensible/PanelEvents', 
      disableCaching: false // no need for cache busting when loading via Ajax
      //~ disableCaching:true,
  })
  ,fields: Ext.ensible.cal.EventRecord.prototype.fields.getRange()
  ,totalProperty: "count"
  ,root: "rows"
  ,idProperty: Ext.ensible.cal.EventMappings.EventId.mapping
  ,writer : new Ext.data.JsonWriter({
    writeAllFields: false
  })
  ,load: function(options) {
    //~ foo.bar = baz; // 20120213
      if (!options) options = {};
      if (!options.params) options.params = {};
      //~ options.params.$constants.URL_PARAM_TEAM_VIEW = Lino.calendar_app.team_view_button.pressed;
      
      var view = this.cal_panel.getActiveView();
      var bounds = view.getViewBounds();
      //~ var p = {sd:'05.02.2012',ed:'11.02.2012'};
      //~ var p = {};
      options.params[view.dateParamStart] = bounds.start.format(view.dateParamFormat);
      options.params[view.dateParamEnd] = bounds.end.format(view.dateParamFormat);
      Lino.insert_subst_user(options.params);
      //~ Ext.apply(options.params,p)
      //~ console.log('20120710 eventStore.load()',this.baseParams,options);
    
    return Ext.data.JsonStore.prototype.load.call(this,options);
  }
});


Lino.CalendarCfg = {
    dateParamFormat: 'd.m.Y',
    dateParamStart:'sd',
    dateParamEnd:'ed'
};
//~ 20120704 Lino.CalendarPanel = Ext.extend(Ext.ensible.cal.CalendarPanel,Lino.MainPanel);
//~ Lino.CalendarPanel = Ext.extend(Lino.CalendarPanel,{
Ext.override(Ext.ensible.cal.CalendarPanel,Lino.MainPanel);
Ext.override(Ext.ensible.cal.CalendarPanel,{
  //~ empty_title : "\$ui.get_actor('cal.Panel').report.label",
  empty_title : "Kalender"
  ,activeItem: 1 // 0: day, 1: week
  ,ls_url: '/extensible/CalendarPanel'
  //~ ,disableCaching:true
  //~ ,eventStore: Lino.eventStore
  //~ ,calendarStore: Lino.calendarStore
  //~ ,initComponent : function(){
    //~ Ext.ensible.cal.CalendarPanel.superclass.initComponent.call(this);
    //~ this.eventStore.on('load',function(){
      //~ console.log("20130808",Lino.eventStore);
      //~ if (this.eventStore.reader.jsonData) {
        //~ console.log("20130808 b",this.eventStore.reader.jsonData.title);
        //~ this.set_window_title(this.eventStore.reader.jsonData.title);
      //~ }
    //~ },this);
  //~ }
  ,listeners: { 
    editdetails: function(cp,rec,el) {
      //~ console.log("Lino.on_editdetails",arguments);
      if (rec.data.ID)
          Lino.extensible.PanelEvents.detail.run(null,{
              record_id:rec.data.ID,
              base_params:this.app_instance.event_store.baseParams});
      return false;
    }
    ,eventclick: function(cp,rec,el) {
      //~ console.log("Lino.on_eventclick",arguments);
      //~ Lino.cal.Events.detail_action.run({record_id:rec.data.ID});
      Lino.extensible.PanelEvents.detail.run(null,{
            record_id:rec.data.ID,
                base_params:this.app_instance.event_store.baseParams});
      return false;
    }
    //~ ,eventadd: Lino.on_eventadd
    //~ ,eventdelete: Lino.on_eventdelete
    //~ ,eventresize: Lino.on_eventresize
    ,afterrender : function(config) {
      // console.log("20140402 CalendarPanel.afterrender");
      this.app_instance.calendar_store.cal_panel = this;
      // 20140402 this.app_instance.calendar_store.load();
      //~ console.log("20120704 afterrender calls eventStore.load()",p);
      this.app_instance.event_store.cal_panel = this;
      //~ Lino.eventStore.load({params:p});
      //~ 20130905 removed: this.app_instance.event_store.load();
      //~ Lino.CalendarPanel.superclass.constructor.call(this, config);
      //~ console.log(20120118, config,this);
    }
    }
  ,enableEditDetails: false
  //~ ,monthViewCfg: Lino.CalendarCfg
  //~ ,weekViewCfg: Lino.CalendarCfg
  //~ ,multiDayViewCfg: Lino.CalendarCfg
  //~ ,multiWeekViewCfg: Lino.CalendarCfg
  //~ ,dayViewCfg: Lino.CalendarCfg
  //~ ,initComponent : function() {
    //~ // this.on('eventadd',Lino.on_eventadd);
    //~ Lino.CalendarPanel.superclass.initComponent.call(this);
  //~ }
});




Lino.CalendarAppPanel = Ext.extend(Ext.Panel,Lino.MainPanel);
Lino.CalendarAppPanel = Ext.extend(Lino.CalendarAppPanel,Lino.PanelMixin);
Lino.CalendarAppPanel = Ext.extend(Lino.CalendarAppPanel,{
  app_instance : null
  //~ empty_title : "\$ui.get_actor('cal.Panel').report.label",
  ,empty_title : "Kalender"
  ,ls_url: '/extensible/CalendarPanel'
  ,set_status : function(status,rp) { 
      // console.log('20140402 CalendarAppPanel.set_status()', status);
      this.requesting_panel = Ext.getCmp(rp);
      this.clear_base_params();
      if (status == undefined) status = {};
      //~ if (status.param_values) 
      //~ this.set_field_values(status.field_values);
      if (status.base_params) this.set_base_params(status.base_params);
      this.refresh();
      }
  ,refresh : function() {
      //~ this.app_instance.event_store.reload(); 20130905
      this.app_instance.calendar_store.load();  // added 20140402
      this.app_instance.event_store.load();
  }
  ,layout: 'fit'
  ,get_base_params : function() {
    // console.log('20140402 getbase_params has', this.base_params);
    var p = Ext.apply({}, this.base_params);
    Lino.insert_subst_user(p);
    // console.log('20140402 getbase_params returns', p);
    return p;
  }
  ,set_base_params : function(p) {
    this.base_params = Ext.apply(this.app_instance.event_store.baseParams,p);
    this.app_instance.event_store.baseParams = this.base_params;
    // console.log('20140402 this.base_params is', this.base_params);
  }
  ,clear_base_params : function() {
      this.base_params = {};
      Lino.insert_subst_user(this.base_params);
  }
  ,set_base_param : function(k,v) {
      if (!this.base_params) this.base_params = {};
      this.base_params[k] = v;
  }
});

Lino.CalendarApp = function() { return {
  team_view_button : null 
  ,get_main_panel : function() {
      var cap = null;
      this.event_store = new Ext.data.JsonStore({ 
          listeners: { exception: Lino.on_store_exception }
          ,url: '/restful/extensible/PanelEvents'
          ,restful : true
          ,proxy: new Ext.data.HttpProxy({ 
              url: '/restful/extensible/PanelEvents', 
              disableCaching: false // no need for cache busting when loading via Ajax
              //~ disableCaching:true,
          })
          ,fields: Ext.ensible.cal.EventRecord.prototype.fields.getRange()
          ,totalProperty: "count"
          ,root: "rows"
          ,idProperty: Ext.ensible.cal.EventMappings.EventId.mapping
          ,writer : new Ext.data.JsonWriter({
            writeAllFields: false
          })
          ,load: function(options) {
            //~ foo.bar = baz; // 20120213
              if (!options) options = {};
              if (!options.params) options.params = {};
              //~ options.params.$constants.URL_PARAM_TEAM_VIEW = Lino.calendar_app.team_view_button.pressed;
              
              var view = this.cal_panel.getActiveView();
              var bounds = view.getViewBounds();
              //~ var p = {sd:'05.02.2012',ed:'11.02.2012'};
              //~ var p = {};
              options.params[view.dateParamStart] = bounds.start.format(view.dateParamFormat);
              options.params[view.dateParamEnd] = bounds.end.format(view.dateParamFormat);
              Lino.insert_subst_user(options.params);
              Ext.apply(options.params, cap.get_base_params());
              //~ this.cal_panel.base_params.su.toString();
              //~ if (this.cal_panel) {
                  // Ext.apply(options.params,this.cal_panel.base_params);
              //~ }
              //~ Ext.apply(options.params,p)
              //~ console.log('20130905 eventStore.load()',this.cal_panel,this.baseParams,options.params);
            
            return Ext.data.JsonStore.prototype.load.call(this,options);
          }
      });

      //~ Lino.calendarStore
      this.calendar_store = new Ext.data.JsonStore({ 
          listeners: { exception: Lino.on_store_exception }
          ,restful : true
          ,proxy: new Ext.data.HttpProxy({ 
              url: '/restful/extensible/PanelCalendars?fmt=json', 
              disableCaching: false // no need for cache busting when loading via Ajax
              //~ restful : true
              //~ method: "GET"
          })
          //~ ,autoLoad: true
          //~ ,remoteSort: true
          //~ ,baseParams: bp
          ,totalProperty: "count"
          ,root: "rows"
          ,fields: Ext.ensible.cal.CalendarRecord.prototype.fields.getRange()
          ,idProperty: Ext.ensible.cal.CalendarMappings.CalendarId.mapping
          //~ ,idIndex: Ext.ensible.cal.CalendarMappings.CalendarId.mapping
          ,load: function(options) {
              // new since 20140402 add substitute user when calling
              // calendars
              if (!options) options = {};
              if (!options.params) options.params = {};
              // Lino.insert_subst_user(options.params);
              Ext.apply(options.params, cap.get_base_params());
              // console.log("20140402 calendar_store.load", options.params, 
              //             this.cal_panel, cap.get_base_params());
            return Ext.data.JsonStore.prototype.load.call(this,options);
          }
      });
      
      cap = new Lino.CalendarAppPanel({ 
          app_instance: this, 
          items : 
        //~ [{
          //~ id: 'app-header',
          //~ region: 'north',
          //~ height: 35,
          //~ border: false,
          // contentEl: 'app-header-content'
        //~ },
      {
          id: 'app-center',
          title: '...', // will be updated to the current view's date range
          region: 'center',
          layout: 'border',
          listeners: {
              'afterrender': function(){
                  Ext.getCmp('app-center').header.addClass('app-center-header');
              }
          },
          items: [{
              id:'app-west',
              region: 'west',
              width: 176,
              border: false,
              items: [{
                  xtype: 'datepicker',
                  id: 'app-nav-picker',
                  cls: 'ext-cal-nav-picker',
                  listeners: {
                      'select': {
                          fn: function(dp, dt){
                              // console.log("20131017",dp);
                              //~ Lino.calendarPanel.setStartDate(dt);
                              //~ cap.setStartDate(dt);
                              Ext.getCmp('app-calendar').setStartDate(dt);
                          },
                          //~ scope: this
                      }
                  }
              //~ },{ 
                //~ layout:'fit',
                //~ items: [
                  //~ new Ext.form.Checkbox({
                    //~ boxLabel:"$_('Team view')",
                    //~ hideLabel:true
                    //~ listeners: { click: }
                  //~ })
                //~ ]
              //~ },{ 
                //~ layout:'form',
                //~ items: [
                  //~ this.team_view_button = new Ext.Button({
                    //~ text:"Team view",
                    //~ enableToggle:true,
                    //~ pressed:false,
                    //~ toggleHandler: function(btn,state) { 
                      //~ // console.log('20120716 teamView.toggle()');
                      //~ this.event_store.setBaseParam('tv',state);
                      //~ this.event_store.load();
                      //~ // console.log("team view",state);
                    //~ }
                  //~ })
                //~ ]
              },{
                  xtype: 'extensible.calendarlist',
                  store: this.calendar_store,
                  border: false,
                  width: 175
              }]
          },{
              xtype: 'extensible.calendarpanel', // Ext.ensible.cal.CalendarPanel
              eventStore: this.event_store,
              app_instance: this,
              calendarStore: this.calendar_store,
              border: false,
              id:'app-calendar',
              region: 'center',
              //~ activeItem: 3, // month view
              
              // Any generic view options that should be applied to all sub views:
              viewConfig: {
                  // Lino.CalendarCfg
                  dateParamFormat: 'd.m.Y',
                  dateParamStart:'sd',
                  dateParamEnd:'ed',
                
                  //enableFx: false,
                  //ddIncrement: 10, //only applies to DayView and subclasses, but convenient to put it here
                  viewStartHour: 8, // 8
                  viewEndHour: 18 // 18
                  //minEventDisplayMinutes: 15
              },
              
              // View options specific to a certain view (if the same options exist in viewConfig
              // they will be overridden by the view-specific config):
              monthViewCfg: {
                  showHeader: true,
                  showWeekLinks: true,
                  showWeekNumbers: true,
                  eventBodyMarkup: ['{Title}',
                    //~ '<tpl if="url">',
                        //~ '<a href="{url}">XX</a>',
                    //~ '</tpl>',
                    '<tpl if="_isReminder">',
                        '<i class="ext-cal-ic ext-cal-ic-rem">&#160;</i>',
                    '</tpl>',
                    '<tpl if="_isRecurring">',
                        '<i class="ext-cal-ic ext-cal-ic-rcr">&#160;</i>',
                    '</tpl>',
                    '<tpl if="spanLeft">',
                        '<i class="ext-cal-spl">&#160;</i>',
                    '</tpl>',
                    '<tpl if="spanRight">',
                        '<i class="ext-cal-spr">&#160;</i>',
                    '</tpl>'
                ].join('')
              },
              
              multiWeekViewCfg: {
                  //weekCount: 3
              },
              
              // Some optional CalendarPanel configs to experiment with:
              //readOnly: true,
              //showDayView: false,
              //showMultiDayView: true,
              //showWeekView: false,
              //showMultiWeekView: false,
              //showMonthView: false,
              //showNavBar: false,
              //showTodayText: false,
              //showTime: false,
              //editModal: true,
              //enableEditDetails: false,
              //title: 'My Calendar', // the header of the calendar, could be a subtitle for the app
              
              // Once this component inits it will set a reference to itself as an application
              // member property for easy reference in other functions within App.
              //~ initComponent: function() {
                  //~ Lino.calendarPanel = this;
                  //~ this.constructor.prototype.initComponent.apply(this, arguments);
              //~ },
              
              listeners: {
                  //~ 'eventclick': {
                      //~ fn: function(vw, rec, el){
                          //~ this.clearMsg();
                      //~ },
                      //~ scope: this
                  //~ },
                  'eventover': function(vw, rec, el){
                      //console.log('Entered evt rec='+rec.data[Ext.ensible.cal.EventMappings.Title.name]', view='+ vw.id +', el='+el.id);
                  },
                  'eventout': function(vw, rec, el){
                      //console.log('Leaving evt rec='+rec.data[Ext.ensible.cal.EventMappings.Title.name]+', view='+ vw.id +', el='+el.id);
                  },
                  'eventadd': {
                      fn: function(cp, rec){
                          this.showMsg('Event '+ rec.data[Ext.ensible.cal.EventMappings.Title.name] +' was added');
                      },
                      scope: this
                  },
                  'eventupdate': {
                      fn: function(cp, rec){
                          this.showMsg('Event '+ rec.data[Ext.ensible.cal.EventMappings.Title.name] +' was updated');
                      },
                      scope: this
                  },
                  'eventdelete': {
                      fn: function(cp, rec){
                          //this.eventStore.remove(rec);
                          this.showMsg('Event '+ rec.data[Ext.ensible.cal.EventMappings.Title.name] +' was deleted');
                      },
                      scope: this
                  },
                  'eventcancel': {
                      fn: function(cp, rec){
                          // edit canceled
                      },
                      scope: this
                  },
                  'viewchange': {
                      fn: function(p, vw, dateInfo){
                          if(this.editWin){
                              this.editWin.hide();
                          };
                          if(dateInfo !== null){
                              // will be null when switching to the event edit form so ignore
                              Ext.getCmp('app-nav-picker').setValue(dateInfo.activeDate);
                              this.updateTitle(dateInfo.viewStart, dateInfo.viewEnd);
                          }
                          
                      },
                      scope: this
                  },
                  'dayclick': {
                      fn: function(vw, dt, ad, el){
                          this.clearMsg();
                      },
                      scope: this
                  },
                  'rangeselect': {
                      fn: function(vw, dates, onComplete){
                          this.clearMsg();
                      },
                      scope: this
                  },
                  'eventmove': {
                      fn: function(vw, rec){
                          rec.commit();
                          var time = rec.data[Ext.ensible.cal.EventMappings.IsAllDay.name] ? '' : ' \\a\\t g:i a';
                          this.showMsg('Event '+ rec.data[Ext.ensible.cal.EventMappings.Title.name] +' was moved to '+
                              rec.data[Ext.ensible.cal.EventMappings.StartDate.name].format('F jS'+time));
                      },
                      scope: this
                  },
                  'eventresize': {
                      fn: function(vw, rec){
                          rec.commit();
                          this.showMsg('Event '+ rec.data[Ext.ensible.cal.EventMappings.Title.name] +' was updated');
                      },
                      scope: this
                  },
                  'eventdelete': {
                      fn: function(win, rec){
                          this.event_store.remove(rec);
                          this.showMsg('Event '+ rec.data[Ext.ensible.cal.EventMappings.Title.name] +' was deleted');
                      },
                      scope: this
                  },
                  'initdrag': {
                      fn: function(vw){
                          if(this.editWin && this.editWin.isVisible()){
                              this.editWin.hide();
                          }
                      },
                      scope: this
                  }
              }
          }]
        }
        //~ ]
        
      });
      
      this.event_store.on('load',function(){
        //~ console.log("20130905 on event_store load",this.event_store.reader.jsonData);
        if (this.event_store.reader.jsonData) {
          //~ console.log("20130808 b",this.event_store.reader.jsonData.title);
          //~ console.log("20130808 c",this);
          cap.set_window_title(this.event_store.reader.jsonData.title);
        }
      },this);
      
      //~ cap.app_instance = this;
      return cap;
      
  }
  ,updateTitle: function(startDt, endDt){
      var p = Ext.getCmp('app-center');
      
      if(startDt.clearTime().getTime() == endDt.clearTime().getTime()){
          p.setTitle(startDt.format('F j, Y'));
      }
      else if(startDt.getFullYear() == endDt.getFullYear()){
          if(startDt.getMonth() == endDt.getMonth()){
              p.setTitle(startDt.format('F j') + ' - ' + endDt.format('j, Y'));
          }
          else{
              p.setTitle(startDt.format('F j') + ' - ' + endDt.format('F j, Y'));
          }
      }
      else{
          p.setTitle(startDt.format('F j, Y') + ' - ' + endDt.format('F j, Y'));
      }
  }
  // This is an application-specific way to communicate CalendarPanel event messages back to the user.
  // This could be replaced with a function to do "toast" style messages, growl messages, etc. This will
  // vary based on application requirements, which is why it's not baked into the CalendarPanel.
  ,showMsg: function(msg){
      Lino.notify(msg);
      //~ Ext.fly('app-msg').update(msg).removeClass('x-hidden');
  }
  
  ,clearMsg: function(){
      Lino.notify('');
      //~ Ext.fly('app-msg').update('').addClass('x-hidden');
  }
}
};


// from lino.modlib.comments (needed_by=lino_noi.lib.tickets):comments/comments.js

function toggle_visibility(id) {
   var e = document.getElementById(id);
   if(e.style.display == 'block'|| (e.style.display != 'block' && e.style.display != 'none'))
      e.style.display = 'none';
   else
      e.style.display = 'block';
}

// from lino.modlib.tinymce (media_name=tinymce-3.5.11):tinymce/tinymce.js

/* Copyright 2009-2015 Luc Saffre */


Lino.edit_tinymce_text = function(panel, tinymce_options) {
  // edit the text in own window.
  // `panel` is the RichTextPanel
  // console.log(20150520, panel);
  //~ var rec = panel.get_current_record();
  var rec = panel.containing_panel.get_current_record();
  var value = rec ? rec.data[panel.editor.name] : '';
  var saving = false;
  var todo_after_save = false;
  var discard_changes = false;
  
  
  function save() {
    if (saving) {alert('tried to save again'); return; }
    var url = panel.containing_panel.get_record_url(rec.id);
    var params = Ext.apply({}, panel.containing_panel.get_base_params());
    params[panel.editor.name] = editor.getValue();
    //~ params.su = Lino.subst_user;
    //~ Lino.insert_subst_user(params);

    // 20150325 http://trac.lino-framework.org/ticket/131
    var action_name = panel.containing_panel.save_action_name;
    if (!action_name) 
        action_name = panel.containing_panel.action_name;
    params.an = action_name;

    var a = { 
      params: params, 
      method: 'PUT',
      url: url,
      failure: function() {
          //~ if (editor.ed.getContainer()) 
          editor.ed.setProgressState(0);
          todo_after_save = false;
          saving = false;
          console.log('tinymce.save() failed. sorry.',arguments);
        },
      success: function() {
        saving = false;
        //~ if (editor.ed.getContainer()) 
        editor.ed.setProgressState(0);
        rec.data[panel.editor.name] = editor.getValue();
        if(todo_after_save) {
            var fn = todo_after_save;
            todo_after_save = false;
            fn();
        }
        //~ panel.containing_window.set_current_record(rec);
        panel.refresh();
      }
    };
    //~ if (editor.ed.getContainer()) 
    editor.ed.setProgressState(1); // Show progress
    saving = true;
    //~ console.log(a);
    Ext.Ajax.request(a);
  };
  function save_callback() {
      save();
      //~ save(function(){editor.ed.setDirty(false);})
      /* return true have the save button disabled.  
      That's not perfect because the PUT is asynchronous 
      and the response is not yet known.
      */
      return true;
  }
  //~ var actions = [
    //~ {text:"Save",handler:save}
  //~ ]; 
  //~ console.log(20110610,panel.editor.disabled);
  var settings = {};
  Ext.apply(settings,{
        readonly: panel.editor.disabled,
        //~ language: "de",
        plugins : "save,emotions,spellchecker,advhr,insertdatetime,preview,table,searchreplace,template", 
        // Theme options - button# indicated the row# only
        theme_advanced_buttons1 : "save,cancel,|,bold,italic,underline,|,justifyleft,justifycenter,justifyright,fontselect,fontsizeselect,formatselect,|,search,replace",
        theme_advanced_buttons2 : "cut,copy,paste,template,|,bullist,numlist,|,outdent,indent,|,undo,redo,|,link,unlink,anchor,image,|,code,preview,|,forecolor,backcolor",
        theme_advanced_buttons3 : "insertdate,inserttime,|,spellchecker,advhr,,removeformat,|,sub,sup,|,charmap,emotions,|,tablecontrols",
        theme_advanced_resizing : false,
        convert_urls : false,
        save_onsavecallback : save_callback,
        save_enablewhendirty : true
        //~ save_oncancelcallback: on_cancel
  });
  Ext.apply(settings, tinymce_options);
  var editor = new Ext.ux.TinyMCE({
      value : value,
      tinymceSettings: settings
    });
  var win = new Ext.Window({
    title: rec.title, 
    //~ bbar: actions,
    layout: 'fit',
    items: editor,
    width: 500, 
    height: 400,
    minWidth: 100,
    minHeight: 100,
    modal: true,
    resizable: true,
    maximizable: true,
    //~ maximized: true,
    //~ closeAction: "close"
    closeAction: "hide"
    //~ hideMode: "offsets",
    //~ constrainHeader: true,
    //~ bodyStyle: 'padding: 10px'
  });

  //~ win.on('beforeclose',function() {
  win.on('beforehide',function() {
    if (todo_after_save) return false;
    if (discard_changes) return true;
    if (editor.isDirty()) {
        //~ var ok = false;
        //~ var allowClose = true;
        var config = {title:"Kinnitus"};
        config.buttons = Ext.MessageBox.YESNOCANCEL;
        config.msg = "Save changes to text ?";
        config.modal = true;
        config.fn = function(buttonId,text,opt) {
          //~ console.log('do_when_clean',buttonId)
          if (buttonId == "yes") {
              /* we cancel this close, but save()'s onSuccess will call again.*/
              //~ allowClose = false;
              todo_after_save = function(){win.hide();}
              editor.ed.execCommand('mceSave');
              //~ editor.ed.save(function(){win.close();});
          } else if (buttonId == "no") { 
              discard_changes = true;
              win.hide()
          //~ } else if (buttonId == "cancel") { 
            //~ ok = true;
              //~ allowClose = false;
          //~ } else { 
            //~ console.log('unknwon buttonId:',buttonId);
          }
        }
        Ext.MessageBox.show(config);
        return false;
        //~ return allowClose;
    }
  });
  win.show();
}


Lino.RichTextPanel = Ext.extend(Ext.Panel,Lino.PanelMixin);
Lino.RichTextPanel = Ext.extend(Lino.RichTextPanel,Lino.FieldBoxMixin);
Lino.RichTextPanel = Ext.extend(Lino.RichTextPanel,{
    
  //~ initComponent : function(){
    //~ Lino.RichTextPanel.superclass.initComponent.call(this);
  //~ },
  constructor : function(config, params) {
      // console.log('20150520a Lino.RichTextPanel.initComponent', this);
    //~ var url = TEMPLATES_URL + config.ls_url + "/" + String(rec.id) + "/" + config.name;
    //~ var url = TEMPLATES_URL + config.ls_url + "/" + config.name;
    var t = this;
    var tinymce_options = {
        theme : "advanced",
        content_css: '/static/extjs/lino.css,/static/tinymce_content.css',

        theme_advanced_font_sizes : "12px,13px,14px,16px,18px,20px,24px",
        font_size_style_values : "12px,13px,14px,16px,18px,20px,24px",
        language: 'et',
        //~ template_external_list_url : url,
        theme_advanced_toolbar_location : "top",
        theme_advanced_toolbar_align : "left",
        theme_advanced_statusbar_location : "bottom",
        template_popup_width : 500,
        template_popup_height : 400,
        template_replace_values : { 
            data_field : function(element){ 
                //~ console.log(20110722,fieldName,t.containing_window.get_current_record()); 
                var fieldName = element.innerHTML;
                element.innerHTML = t.containing_panel.get_current_record().data[fieldName];
            } 
        }
      };
      
    var editorConfig = {
      tinymceSettings: {
        plugins : "noneditable,template", 
        // Theme options - button# indicated the row# only
        theme_advanced_buttons1 : "bold,italic,underline,|,justifyleft,justifycenter,justifyright,|,bullist,numlist,|,outdent,indent,|,undo,redo,|,removeformat,template",
        theme_advanced_buttons2 : "",
        theme_advanced_buttons3 : "", // ,|,sub,sup,|,charmap",      
        theme_advanced_resizing : false
        //~ save_onsavecallback : save_callback,
        //~ save_enablewhendirty : true
        //~ save_oncancelcallback: on_cancel
        
    }};
    Ext.apply(editorConfig.tinymceSettings, tinymce_options);
    //~ editorConfig.name = config.action_name;
    editorConfig.name = config.name;
    delete config.name;
    //~ config.title = config.label;
    //~ delete config.label;
    this.before_init(config,params);
    
    // console.log('20150520b Lino.RichTextPanel.initComponent', this);

    this.editor = new Ext.ux.TinyMCE(editorConfig);
    var t = this;
    function save_cmd() { 
        // console.log("20150902 save_cmd()", arguments);            
        var cw = t.get_containing_window();
        if (cw) {
            cw.main_item.save();
        }
    }
    this.editor.withEd(function(){
        if (!t.editor.ed.addShortcut(
            'ctrl+s', 'Save the content', save_cmd)) {
            console.log("20150902 addShortcut() failed");            
        };
        // t.editor.ed.onKeyDown.add(function(ed, e) {
        //     if (e.keyCode == 13 && e.ctrlKey) {
        //         save_cmd(); 
        //         return tinymce.dom.Event.cancel(e); 
        //         // e.preventDefault();
        //         // http://stackoverflow.com/questions/18971284/event-preventdefault-vs-return-false-no-jquery
        //     }
        // });
    });
    config.tools = [{
                      qtip: "Edit text in own window", 
                      id: "up",
                      handler: function(){
                        if(t.editor.isDirty()) {
                            var record = t.containing_panel.get_current_record();
                            record.data[t.editor.name] = t.editor.getValue();
                        }
                        Lino.edit_tinymce_text(t, tinymce_options)
                      }
                    }];
    
    config.items = this.editor;
    config.layout = "fit";
    // console.log('20150520c Lino.RichTextPanel.initComponent', this);
    Lino.RichTextPanel.superclass.constructor.call(this, config);
    // console.log('20150520d Lino.RichTextPanel.initComponent', this);
  },
  getValue : function(v) {
      return this.editor.getValue(v);
  },
  refresh : function(unused) { 
      this.refresh_with_after();
  },
  /* RichTextPanel */
  refresh_with_after : function(after) {
    // when called from the dashboard:    
    if (!this.containing_panel.get_current_record) { return; }
    var record = this.containing_panel.get_current_record();
    // console.log('20140504 RichTextPanel.refresh()',
    //             this.title,record.title, record);
    var todo = function() {
      if (record) {
        var url = '/tinymce/templates' 
              + this.containing_panel.ls_url + "/" 
              + String(record.id) + "/" + this.editor.name;
        // console.log('20150415 RichTextPanel.refresh()',url);
        if (this.editor.ed)
            this.editor.ed.settings.template_external_list_url = url;
            // else {console.log("20150415 no editor")}
        this.set_base_params(this.containing_panel.get_master_params());
        //~ var v = record ? this.format_data(record.data[this.editor.name]) : ''
        var v = this.format_data(record.data[this.editor.name])
        this.editor.setValue(v);
      } else {
        this.editor.setValue('(no data)');
      }
    };
    Lino.do_when_visible(this,todo.createDelegate(this));
  }
});
//~ Ext.override(Lino.RichTextPanel,Lino.FieldBoxMixin);

Lino.main_menu = [ { "menu": { "items": [ { "handler": function() {Lino.contacts.Persons.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","List of all Persons.") }, "text": "Inimesed" }, { "handler": function() {Lino.contacts.Companies.grid.run(null)}, "text": "Organisatsioonid" }, { "handler": function() {Lino.lists.Lists.grid.run(null)}, "text": "Partnerite nimekirjad" } ] }, "text": "Kontaktid" }, { "menu": { "items": [ { "handler": function() {Lino.cal.MyEntries.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Table of my appointments.") }, "text": "My appointments" }, { "handler": function() {Lino.cal.OverdueAppointments.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows overdue appointments, i.e. appointments whose date is\nover but who are still in a nonstable state.") }, "text": "Overdue appointments" }, { "handler": function() {Lino.cal.MyUnconfirmedAppointments.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows appointments in the near future which are still in draft\nstate.") }, "text": "Unconfirmed appointments" }, { "handler": function() {Lino.cal.MyTasks.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Table of all my tasks.") }, "text": "My tasks" }, { "handler": function() {Lino.cal.MyGuests.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The default table for Guest.") }, "text": "My guests" }, { "handler": function() {Lino.cal.MyPresences.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows all my presences in calendar events, independently of their\nstate.") }, "text": "Minu kohalolekud" }, { "handler": function() {Lino.cal.MyOverdueAppointments.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Like OverdueAppointments, but only for myself.") }, "text": "My overdue appointments" }, { "handler": function() {Lino.extensible.CalendarPanel.grid.run(null)}, "iconCls": "x-tbar-calendar", "listeners": { "render": Lino.quicktip_renderer("Foo","Displays your events in a \"calendar view\"     with the possibility to switch between daily, weekly, monthly view.") }, "text": "Kalender" } ] }, "text": "Kalender" }, { "menu": { "items": [ { "handler": function() {Lino.courses.MyActivities.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Base table for all activities.") }, "text": "Minu Tegevused" }, { "handler": function() {Lino.courses.Courses.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Base table for all activities.") }, "text": "Tegevused" }, "-", { "handler": function() {Lino.courses.Lines.grid.run(null)}, "text": "Tegevuste sarjad" }, { "handler": function() {Lino.courses.PendingRequestedEnrolments.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Show all requested enrolments.") }, "text": "Pending requested enrolments" }, { "handler": function() {Lino.courses.PendingConfirmedEnrolments.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Show all confirmed enrolments.") }, "text": "Pending confirmed enrolments" } ] }, "text": "Tegevused" }, { "menu": { "items": [ { "handler": function() {Lino.excerpts.MyExcerpts.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Base class for all tables on Excerpt.") }, "text": "Minu V\u00e4ljav\u00f5ted" }, { "handler": function() {Lino.comments.MyComments.grid.run(null)}, "text": "Minu Comments" }, { "handler": function() {Lino.blogs.MyEntries.grid.run(null)}, "text": "Minu Blog Entries" }, { "handler": function() {Lino.notify.MyMessages.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows messages emitted to you.") }, "text": "Minu Teaded" }, { "handler": function() {Lino.uploads.MyUploads.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows only my Uploads (i.e. those whose author is current user).") }, "text": "Minu Uploads" }, { "handler": function() {Lino.outbox.MyOutbox.grid.run(null)}, "text": "My Outbox" } ] }, "text": "B\u00fcroo" }, { "menu": { "items": [ { "handler": function() {Lino.tickets.MyTickets.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Show all active tickets reported by me.") }, "text": "Minu Lipikud" }, { "handler": function() {Lino.tickets.SuggestedTicketsByEndUser.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows the tickets of other users which need help on a faculty for\nwhich I am competent.") }, "text": "Kus ma saan aidata" }, { "handler": function() {Lino.tickets.ActiveTickets.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Show all tickets that are in an active state.") }, "text": "Active tickets" }, { "handler": function() {Lino.tickets.AllTickets.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Global list of all tickets.") }, "text": "K\u00f5ik lipikud" }, { "handler": function() {Lino.tickets.UnassignedTickets.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Global list of all tickets.") }, "text": "Unassigned Tickets" }, { "handler": function() {Lino.tickets.RefTickets.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Tickets that have a reference.") }, "text": "Reference Tickets" } ] }, "text": "Lipikud" }, { "menu": { "items": [ { "handler": function() {Lino.clocking.MySessions.grid.run(null)}, "text": "Istungid" }, { "handler": function() {Lino.clocking.ServiceReports.grid.run(null)}, "text": "Service Reports" } ] }, "text": "T\u00f6\u00f6aeg" }, { "menu": { "items": [ { "handler": function() {Lino.meetings.MyMeetings.grid.run(null)}, "text": "Meetings" } ] }, "text": "Meetings" }, { "menu": { "items": [ { "menu": { "items": [ { "handler": function() {Lino.countries.Countries.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The table of all countries.") }, "text": "Riigid" }, { "handler": function() {Lino.countries.Places.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","\n    The table of known geographical places.\n    A geographical place can be a city, a town, a suburb,\n    a province, a lake... any named geographic entity,\n    except for countries because these have their own table.\n    ") }, "text": "Asumid" } ] }, "text": "Asumid" }, { "menu": { "items": [ { "handler": function() {Lino.system.SiteConfigs.detail.run(null,{ "record_id": 1 })}, "iconCls": "x-tbar-application_form", "text": "Site Parameters" }, { "handler": function() {Lino.users.AllUsers.grid.run(null)}, "text": "Users" }, { "handler": function() {Lino.gfks.HelpTexts.grid.run(null)}, "text": "Help Texts" } ] }, "text": "S\u00fcsteem" }, { "menu": { "items": [ { "handler": function() {Lino.contacts.CompanyTypes.grid.run(null)}, "text": "Organisatsiooniliiged" }, { "handler": function() {Lino.contacts.RoleTypes.grid.run(null)}, "text": "Functions" }, { "handler": function() {Lino.topics.AllTopics.grid.run(null)}, "text": "Teemad" }, { "handler": function() {Lino.topics.TopicGroups.grid.run(null)}, "text": "Topic groups" }, { "handler": function() {Lino.lists.ListTypes.grid.run(null)}, "text": "Listiliigid" } ] }, "text": "Kontaktid" }, { "menu": { "items": [ { "handler": function() {Lino.cal.Calendars.grid.run(null)}, "text": "Calendars" }, { "handler": function() {Lino.cal.AllRooms.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","List of rooms where calendar events can happen.") }, "text": "Ruumid" }, { "handler": function() {Lino.cal.Priorities.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","List of possible priorities of calendar events.") }, "text": "Priorities" }, { "handler": function() {Lino.cal.RecurrentEvents.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The list of all recurrent events (RecurrentEvent).") }, "text": "Recurring events" }, { "handler": function() {Lino.cal.GuestRoles.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The role of a guest expresses what the partner is going to do there.") }, "text": "Guest Roles" }, { "handler": function() {Lino.cal.EventTypes.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The list of Event Types defined on this system.\n    An EventType is a list of events which have certain things in common,\n    especially they are displayed in the same colour in the calendar panel.\n    ") }, "text": "S\u00fcndmuseliigid" }, { "handler": function() {Lino.cal.EventPolicies.grid.run(null)}, "text": "Recurrency policies" }, { "handler": function() {Lino.cal.RemoteCalendars.grid.run(null)}, "text": "Remote Calendars" } ] }, "text": "Kalender" }, { "menu": { "items": [ { "handler": function() {Lino.courses.Topics.grid.run(null)}, "text": "Teemad" }, { "handler": function() {Lino.courses.Slots.grid.run(null)}, "text": "Timetable Slots" } ] }, "text": "Tegevused" }, { "menu": { "items": [ { "handler": function() {Lino.excerpts.ExcerptTypes.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Displays all rows of ExcerptType.") }, "text": "V\u00e4ljav\u00f5teliigid" }, { "handler": function() {Lino.comments.CommentTypes.grid.run(null)}, "text": "Comment Types" }, { "handler": function() {Lino.uploads.UploadTypes.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The table with all existing upload types.") }, "text": "Upload Types" }, { "handler": function() {Lino.tinymce.MyTextFieldTemplates.grid.run(null)}, "text": "Minu Text Field Templates" } ] }, "text": "B\u00fcroo" }, { "menu": { "items": [ { "handler": function() {Lino.tickets.AllProjects.grid.run(null)}, "text": "Eesm\u00e4rgid" }, { "handler": function() {Lino.tickets.TopLevelProjects.grid.run(null)}, "text": "Projects (tree)" }, { "handler": function() {Lino.tickets.ProjectTypes.grid.run(null)}, "text": "Project Types" }, { "handler": function() {Lino.tickets.TicketTypes.grid.run(null)}, "text": "Lipikuliigid" } ] }, "text": "Lipikud" }, { "menu": { "items": [ { "handler": function() {Lino.faculties.TopLevelSkills.grid.run(null)}, "text": "Oskused (puu)" }, { "handler": function() {Lino.faculties.AllSkills.grid.run(null)}, "text": "Oskused (k\u00f5ik)" }, { "handler": function() {Lino.faculties.SkillTypes.grid.run(null)}, "text": "Oskuseliigid" } ] }, "text": "Oskused" }, { "menu": { "items": [ { "handler": function() {Lino.clocking.SessionTypes.grid.run(null)}, "text": "Istungiliigid" } ] }, "text": "T\u00f6\u00f6aeg" }, { "menu": { "items": [ { "handler": function() {Lino.blogs.EntryTypes.grid.run(null)}, "text": "Blog Entry Types" } ] }, "text": "Blog" } ] }, "text": "Seaded" }, { "menu": { "items": [ { "menu": { "items": [ { "handler": function() {Lino.contacts.Roles.grid.run(null)}, "text": "Contact Persons" }, { "handler": function() {Lino.contacts.Partners.grid.run(null)}, "text": "Partnerid" }, { "handler": function() {Lino.addresses.AddressTypes.grid.run(null)}, "text": "Aadressiliike" }, { "handler": function() {Lino.addresses.Addresses.grid.run(null)}, "text": "Aadressid" }, { "handler": function() {Lino.topics.AllInterests.grid.run(null)}, "text": "Interests" }, { "handler": function() {Lino.lists.AllMembers.grid.run(null)}, "text": "Listi tellimused" } ] }, "text": "Kontaktid" }, { "menu": { "items": [ { "handler": function() {Lino.users.Authorities.grid.run(null)}, "text": "Authorities" }, { "handler": function() {Lino.users.UserTypes.grid.run(null)}, "text": "Kasutajaliigid" }, { "handler": function() {Lino.gfks.ContentTypes.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Default table for django.contrib.ContentType.") }, "text": "sisut\u00fc\u00fcbid" }, { "handler": function() {Lino.changes.Changes.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The default table for Change.") }, "text": "Changes" }, { "handler": function() {Lino.notify.AllMessages.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The gobal list of all messages.") }, "text": "Teaded" }, { "handler": function() {Lino.dashboard.AllWidgets.grid.run(null)}, "text": "All dashboard widgets" } ] }, "text": "S\u00fcsteem" }, { "menu": { "items": [ { "handler": function() {Lino.cal.AllEntries.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Table which shows all calendar events.") }, "text": "events" }, { "handler": function() {Lino.cal.Tasks.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","A calendar task is something you need to do.") }, "text": "Tasks" }, { "handler": function() {Lino.cal.AllGuests.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The default table for Guest.") }, "text": "Kohalolekud" }, { "handler": function() {Lino.cal.Subscriptions.grid.run(null)}, "text": "Subscriptions" }, { "handler": function() {Lino.cal.EntryStates.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The possible states of a calendar event.") }, "text": "Event states" }, { "handler": function() {Lino.cal.GuestStates.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Possible values for the state of a Guest. The list of choices for\nthe Guest.state field.") }, "text": "Guest states" }, { "handler": function() {Lino.cal.TaskStates.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Possible values for the state of a Task. The list of\nchoices for the Task.state field. By default it contains\nthe following values (which can be redefined in\nworkflows_module):") }, "text": "Task states" } ] }, "text": "Kalender" }, { "menu": { "items": [ { "handler": function() {Lino.courses.AllActivities.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Base table for all activities.") }, "text": "Tegevused" }, { "handler": function() {Lino.courses.AllEnrolments.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Show global list of all enrolments.") }, "text": "Osav\u00f5tud" }, { "handler": function() {Lino.courses.EnrolmentStates.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","The list of possible states of an enrolment.") }, "text": "Enrolment states" } ] }, "text": "Tegevused" }, { "menu": { "items": [ { "handler": function() {Lino.excerpts.AllExcerpts.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Base class for all tables on Excerpt.") }, "text": "V\u00e4ljav\u00f5ted" }, { "handler": function() {Lino.comments.AllComments.grid.run(null)}, "text": "Comments" }, { "handler": function() {Lino.uploads.AllUploads.grid.run(null)}, "listeners": { "render": Lino.quicktip_renderer("Foo","Shows all Uploads") }, "text": "Uploads" }, { "handler": function() {Lino.uploads.UploadAreas.grid.run(null)}, "text": "Upload Areas" }, { "handler": function() {Lino.outbox.Mails.grid.run(null)}, "text": "Outgoing Mails" }, { "handler": function() {Lino.outbox.Attachments.grid.run(null)}, "text": "Attachments" }, { "handler": function() {Lino.tinymce.TextFieldTemplates.grid.run(null)}, "text": "Text Field Templates" } ] }, "text": "B\u00fcroo" }, { "menu": { "items": [ { "handler": function() {Lino.tickets.Links.grid.run(null)}, "text": "Dependencies" }, { "handler": function() {Lino.tickets.TicketStates.grid.run(null)}, "text": "Lipikuolekud" }, { "handler": function() {Lino.deploy.Deployments.grid.run(null)}, "text": "Wishes" } ] }, "text": "Lipikud" }, { "menu": { "items": [ { "handler": function() {Lino.faculties.Offers.grid.run(null)}, "text": "Oskuse pakkumised" }, { "handler": function() {Lino.faculties.Demands.grid.run(null)}, "text": "Oskuste vajadused" } ] }, "text": "Oskused" }, { "menu": { "items": [ { "handler": function() {Lino.clocking.Sessions.grid.run(null)}, "text": "Istungid" } ] }, "text": "T\u00f6\u00f6aeg" }, { "menu": { "items": [ { "handler": function() {Lino.blogs.AllEntries.grid.run(null)}, "text": "Blog Entries" }, { "handler": function() {Lino.blogs.AllTaggings.grid.run(null)}, "text": "Taggings" } ] }, "text": "Blog" }, { "menu": { "items": [ { "handler": function() {Lino.meetings.AllMeetings.grid.run(null)}, "text": "Meetings" } ] }, "text": "Meetings" } ] }, "text": "Explorer" }, { "menu": { "items": [ { "handler": function() {Lino.about.About.show.run(null,{ "record_id": -99998 })}, "listeners": { "render": Lino.quicktip_renderer("Foo","Show information about this site.") }, "text": "About" } ] }, "text": "Site" }, { "handler": function() {Lino.handle_home_button()}, "text": "Home" } ];
Ext.namespace('Lino.countries.Countries')
Ext.namespace('Lino.countries.Places')
Ext.namespace('Lino.system.SiteConfigs')
Ext.namespace('Lino.contacts.Partners')
Ext.namespace('Lino.contacts.Persons')
Ext.namespace('Lino.contacts.CompanyTypes')
Ext.namespace('Lino.contacts.Companies')
Ext.namespace('Lino.contacts.RoleTypes')
Ext.namespace('Lino.contacts.Roles')
Ext.namespace('Lino.cal.RemoteCalendars')
Ext.namespace('Lino.cal.Rooms')
Ext.namespace('Lino.cal.AllRooms')
Ext.namespace('Lino.cal.Priorities')
Ext.namespace('Lino.cal.Calendars')
Ext.namespace('Lino.cal.Subscriptions')
Ext.namespace('Lino.cal.Tasks')
Ext.namespace('Lino.cal.MyTasks')
Ext.namespace('Lino.cal.GuestRoles')
Ext.namespace('Lino.cal.Guests')
Ext.namespace('Lino.cal.AllGuests')
Ext.namespace('Lino.cal.MyPresences')
Ext.namespace('Lino.cal.MyPendingPresences')
Ext.namespace('Lino.cal.MyGuests')
Ext.namespace('Lino.cal.EventTypes')
Ext.namespace('Lino.cal.RecurrentEvents')
Ext.namespace('Lino.cal.Events')
Ext.namespace('Lino.cal.AllEntries')
Ext.namespace('Lino.cal.PublicEntries')
Ext.namespace('Lino.cal.EntriesByDay')
Ext.namespace('Lino.cal.OneEvent')
Ext.namespace('Lino.cal.MyEntries')
Ext.namespace('Lino.cal.MyEntriesToday')
Ext.namespace('Lino.cal.MyAssignedEvents')
Ext.namespace('Lino.cal.OverdueAppointments')
Ext.namespace('Lino.cal.MyOverdueAppointments')
Ext.namespace('Lino.cal.MyUnconfirmedAppointments')
Ext.namespace('Lino.cal.EventPolicies')
Ext.namespace('Lino.extensible.PanelCalendars')
Ext.namespace('Lino.extensible.PanelEvents')
Ext.namespace('Lino.addresses.Addresses')
Ext.namespace('Lino.topics.TopicGroups')
Ext.namespace('Lino.topics.Topics')
Ext.namespace('Lino.topics.AllTopics')
Ext.namespace('Lino.topics.Interests')
Ext.namespace('Lino.topics.AllInterests')
Ext.namespace('Lino.votes.Votes')
Ext.namespace('Lino.votes.AllVotes')
Ext.namespace('Lino.votes.MyVotes')
Ext.namespace('Lino.votes.MyInvitations')
Ext.namespace('Lino.votes.MyOffers')
Ext.namespace('Lino.votes.MyTasks')
Ext.namespace('Lino.votes.MyWatched')
Ext.namespace('Lino.gfks.ContentTypes')
Ext.namespace('Lino.gfks.HelpTexts')
Ext.namespace('Lino.excerpts.ExcerptTypes')
Ext.namespace('Lino.excerpts.Excerpts')
Ext.namespace('Lino.excerpts.AllExcerpts')
Ext.namespace('Lino.excerpts.MyExcerpts')
Ext.namespace('Lino.comments.CommentTypes')
Ext.namespace('Lino.comments.Comments')
Ext.namespace('Lino.comments.MyComments')
Ext.namespace('Lino.comments.CommentsByX')
Ext.namespace('Lino.comments.AllComments')
Ext.namespace('Lino.comments.RecentComments')
Ext.namespace('Lino.changes.Changes')
Ext.namespace('Lino.tickets.ProjectTypes')
Ext.namespace('Lino.tickets.TicketTypes')
Ext.namespace('Lino.tickets.Projects')
Ext.namespace('Lino.tickets.AllProjects')
Ext.namespace('Lino.tickets.TopLevelProjects')
Ext.namespace('Lino.tickets.Links')
Ext.namespace('Lino.tickets.Tickets')
Ext.namespace('Lino.tickets.AllTickets')
Ext.namespace('Lino.tickets.RefTickets')
Ext.namespace('Lino.tickets.UnassignedTickets')
Ext.namespace('Lino.tickets.PublicTickets')
Ext.namespace('Lino.tickets.TicketsToTriage')
Ext.namespace('Lino.tickets.TicketsToTalk')
Ext.namespace('Lino.tickets.ActiveTickets')
Ext.namespace('Lino.tickets.MyTickets')
Ext.namespace('Lino.users.Users')
Ext.namespace('Lino.users.AllUsers')
Ext.namespace('Lino.users.UsersOverview')
Ext.namespace('Lino.users.MySettings')
Ext.namespace('Lino.users.Authorities')
Ext.namespace('Lino.faculties.SkillTypes')
Ext.namespace('Lino.faculties.Skills')
Ext.namespace('Lino.faculties.AllSkills')
Ext.namespace('Lino.faculties.TopLevelSkills')
Ext.namespace('Lino.faculties.Offers')
Ext.namespace('Lino.faculties.MyOffers')
Ext.namespace('Lino.faculties.Demands')
Ext.namespace('Lino.clocking.SessionTypes')
Ext.namespace('Lino.clocking.Sessions')
Ext.namespace('Lino.clocking.MySessions')
Ext.namespace('Lino.clocking.MySessionsByDate')
Ext.namespace('Lino.clocking.ServiceReports')
Ext.namespace('Lino.lists.ListTypes')
Ext.namespace('Lino.lists.Lists')
Ext.namespace('Lino.lists.Members')
Ext.namespace('Lino.lists.AllMembers')
Ext.namespace('Lino.blogs.EntryTypes')
Ext.namespace('Lino.blogs.Entries')
Ext.namespace('Lino.blogs.MyEntries')
Ext.namespace('Lino.blogs.AllEntries')
Ext.namespace('Lino.blogs.LatestEntries')
Ext.namespace('Lino.blogs.Taggings')
Ext.namespace('Lino.blogs.AllTaggings')
Ext.namespace('Lino.notify.Messages')
Ext.namespace('Lino.notify.AllMessages')
Ext.namespace('Lino.notify.MyMessages')
Ext.namespace('Lino.uploads.UploadTypes')
Ext.namespace('Lino.uploads.Uploads')
Ext.namespace('Lino.uploads.AllUploads')
Ext.namespace('Lino.uploads.MyUploads')
Ext.namespace('Lino.uploads.AreaUploads')
Ext.namespace('Lino.outbox.Recipients')
Ext.namespace('Lino.outbox.Mails')
Ext.namespace('Lino.outbox.Attachments')
Ext.namespace('Lino.tinymce.TextFieldTemplates')
Ext.namespace('Lino.tinymce.MyTextFieldTemplates')
Ext.namespace('Lino.dashboard.Widgets')
Ext.namespace('Lino.dashboard.AllWidgets')
Ext.namespace('Lino.users.OtherUsers')
Ext.namespace('Lino.users.Register')
Ext.namespace('Lino.users.NewUsers')
Ext.namespace('Lino.courses.Slots')
Ext.namespace('Lino.courses.Topics')
Ext.namespace('Lino.courses.Lines')
Ext.namespace('Lino.courses.Activities')
Ext.namespace('Lino.courses.Courses')
Ext.namespace('Lino.courses.AllActivities')
Ext.namespace('Lino.courses.MyActivities')
Ext.namespace('Lino.courses.DraftCourses')
Ext.namespace('Lino.courses.ActiveCourses')
Ext.namespace('Lino.courses.InactiveCourses')
Ext.namespace('Lino.courses.ClosedCourses')
Ext.namespace('Lino.courses.Enrolments')
Ext.namespace('Lino.courses.AllEnrolments')
Ext.namespace('Lino.courses.PendingRequestedEnrolments')
Ext.namespace('Lino.courses.PendingConfirmedEnrolments')
Ext.namespace('Lino.deploy.Deployments')
Ext.namespace('Lino.meetings.Meetings')
Ext.namespace('Lino.meetings.AllMeetings')
Ext.namespace('Lino.meetings.MyMeetings')
Ext.namespace('Lino.meetings.ActiveMeetings')
Ext.namespace('Lino.meetings.InactiveMeetings')
Ext.namespace('Lino.sessions.SessionTable')
Ext.namespace('Lino.countries.PlacesByPlace')
Ext.namespace('Lino.countries.PlacesByCountry')
Ext.namespace('Lino.contacts.PartnersByCity')
Ext.namespace('Lino.contacts.PartnersByCountry')
Ext.namespace('Lino.contacts.RolesByCompany')
Ext.namespace('Lino.contacts.RolesByPerson')
Ext.namespace('Lino.contacts.CompaniesByCompany')
Ext.namespace('Lino.cal.SubscriptionsByUser')
Ext.namespace('Lino.cal.SubscriptionsByCalendar')
Ext.namespace('Lino.cal.TasksByUser')
Ext.namespace('Lino.cal.GuestsByEvent')
Ext.namespace('Lino.cal.GuestsByRole')
Ext.namespace('Lino.cal.GuestsByPartner')
Ext.namespace('Lino.cal.EntriesByType')
Ext.namespace('Lino.cal.ConflictingEvents')
Ext.namespace('Lino.cal.EntriesByRoom')
Ext.namespace('Lino.addresses.AddressesByPartner')
Ext.namespace('Lino.topics.TopicsByGroup')
Ext.namespace('Lino.topics.InterestsByPartner')
Ext.namespace('Lino.topics.InterestsByTopic')
Ext.namespace('Lino.votes.VotesByVotable')
Ext.namespace('Lino.excerpts.ExcerptsByType')
Ext.namespace('Lino.comments.CommentsByType')
Ext.namespace('Lino.tickets.ProjectsByParent')
Ext.namespace('Lino.tickets.ProjectsByType')
Ext.namespace('Lino.tickets.ProjectsByCompany')
Ext.namespace('Lino.tickets.ProjectsByPerson')
Ext.namespace('Lino.tickets.LinksByTicket')
Ext.namespace('Lino.tickets.DuplicatesByTicket')
Ext.namespace('Lino.tickets.SuggestedTicketsByEndUser')
Ext.namespace('Lino.tickets.TicketsByEndUser')
Ext.namespace('Lino.tickets.TicketsByType')
Ext.namespace('Lino.tickets.TicketsByTopic')
Ext.namespace('Lino.tickets.TicketsFixed')
Ext.namespace('Lino.tickets.TicketsReported')
Ext.namespace('Lino.tickets.TicketsByReporter')
Ext.namespace('Lino.tickets.TicketsBySite')
Ext.namespace('Lino.tickets.TicketsByProject')
Ext.namespace('Lino.users.AuthoritiesGiven')
Ext.namespace('Lino.users.AuthoritiesTaken')
Ext.namespace('Lino.faculties.SkillsByParent')
Ext.namespace('Lino.faculties.SkillsByType')
Ext.namespace('Lino.faculties.OffersByEndUser')
Ext.namespace('Lino.faculties.OffersBySkill')
Ext.namespace('Lino.faculties.DemandsBySkill')
Ext.namespace('Lino.faculties.DemandsByDemander')
Ext.namespace('Lino.faculties.OffersByDemander')
Ext.namespace('Lino.faculties.AssignableWorkersByTicket')
Ext.namespace('Lino.clocking.SessionsByTicket')
Ext.namespace('Lino.clocking.SessionsByReport')
Ext.namespace('Lino.clocking.TicketsByReport')
Ext.namespace('Lino.clocking.ProjectsByReport')
Ext.namespace('Lino.clocking.ReportsByPartner')
Ext.namespace('Lino.lists.MembersByList')
Ext.namespace('Lino.lists.MembersByPartner')
Ext.namespace('Lino.blogs.EntriesByType')
Ext.namespace('Lino.blogs.TaggingsByEntry')
Ext.namespace('Lino.blogs.TaggingsByTopic')
Ext.namespace('Lino.uploads.UploadsByType')
Ext.namespace('Lino.outbox.RecipientsByMail')
Ext.namespace('Lino.outbox.MyOutbox')
Ext.namespace('Lino.outbox.MailsByUser')
Ext.namespace('Lino.outbox.SentByPartner')
Ext.namespace('Lino.outbox.AttachmentsByMail')
Ext.namespace('Lino.dashboard.WidgetsByUser')
Ext.namespace('Lino.courses.LinesByTopic')
Ext.namespace('Lino.courses.EntriesByTeacher')
Ext.namespace('Lino.courses.CoursesByTeacher')
Ext.namespace('Lino.courses.MyCoursesGiven')
Ext.namespace('Lino.courses.CoursesByLine')
Ext.namespace('Lino.courses.CoursesByTopic')
Ext.namespace('Lino.courses.CoursesBySlot')
Ext.namespace('Lino.courses.EnrolmentsByPupil')
Ext.namespace('Lino.courses.EnrolmentsByCourse')
Ext.namespace('Lino.courses.MyEnrolments')
Ext.namespace('Lino.deploy.DeploymentsByMilestone')
Ext.namespace('Lino.deploy.DeploymentsByTicket')
Ext.namespace('Lino.meetings.MembersByMeeting')
Ext.namespace('Lino.uploads.UploadsByController')
Ext.namespace('Lino.cal.EntriesByController')
Ext.namespace('Lino.changes.ChangesByObject')
Ext.namespace('Lino.cal.TasksByController')
Ext.namespace('Lino.gfks.HelpTextsByModel')
Ext.namespace('Lino.outbox.MailsByController')
Ext.namespace('Lino.changes.ChangesByMaster')
Ext.namespace('Lino.comments.CommentsByRFC')
Ext.namespace('Lino.outbox.AttachmentsByController')
Ext.namespace('Lino.excerpts.ExcerptsByOwner')
Ext.namespace('Lino.blogs.EntriesByController')
Ext.namespace('Lino.about.Models')
Ext.namespace('Lino.about.FieldsByModel')
Ext.namespace('Lino.about.Inspector')
Ext.namespace('Lino.about.SourceFiles')
Ext.namespace('Lino.gfks.BrokenGFKs')
Ext.namespace('Lino.gfks.BrokenGFKsByModel')
Ext.namespace('Lino.about.About')
Ext.namespace('Lino.extensible.CalendarPanel')
Ext.namespace('Lino.courses.StatusReport')
Ext.namespace('Lino.notify.MailModes')
Ext.namespace('Lino.changes.ChangeTypes')
Ext.namespace('Lino.cal.DurationUnits')
Ext.namespace('Lino.uploads.UploadAreas')
Ext.namespace('Lino.cal.TaskStates')
Ext.namespace('Lino.addresses.DataSources')
Ext.namespace('Lino.cal.Weekdays')
Ext.namespace('Lino.outbox.RecipientTypes')
Ext.namespace('Lino.excerpts.Shortcuts')
Ext.namespace('Lino.system.PeriodEvents')
Ext.namespace('Lino.clocking.ReportingTypes')
Ext.namespace('Lino.notify.MessageTypes')
Ext.namespace('Lino.tickets.LinkTypes')
Ext.namespace('Lino.cal.Recurrencies')
Ext.namespace('Lino.system.Genders')
Ext.namespace('Lino.uploads.Shortcuts')
Ext.namespace('Lino.courses.EnrolmentStates')
Ext.namespace('Lino.tickets.ProjectEvents')
Ext.namespace('Lino.cal.EventEvents')
Ext.namespace('Lino.votes.Ratings')
Ext.namespace('Lino.cal.GuestStates')
Ext.namespace('Lino.meetings.MeetingStates')
Ext.namespace('Lino.votes.VoteStates')
Ext.namespace('Lino.addresses.AddressTypes')
Ext.namespace('Lino.printing.BuildMethods')
Ext.namespace('Lino.cal.EntryStates')
Ext.namespace('Lino.tickets.TicketEvents')
Ext.namespace('Lino.cal.AccessClasses')
Ext.namespace('Lino.system.YesNo')
Ext.namespace('Lino.votes.VoteEvents')
Ext.namespace('Lino.users.UserTypes')
Ext.namespace('Lino.deploy.WishTypes')
Ext.namespace('Lino.tickets.TicketStates')
Ext.namespace('Lino.courses.CourseAreas')
Ext.namespace('Lino.contacts.PartnerEvents')
Ext.namespace('Lino.courses.CourseStates')
Ext.namespace('Lino.countries.PlaceTypes')
Ext.namespace('Lino.users.UserStates')

// ChoiceLists: 
Lino.notify.MailModes = [ [ "never", "Never" ], [ "often", "tihti" ], [ "daily", "kord p\u00e4evas" ], [ "weekly", "kord n\u00e4dalas" ] ];
Lino.changes.ChangeTypes = [ [ "C", "Loo" ], [ "U", "Update" ], [ "D", "Kustuta" ], [ "R", "Remove child" ], [ "A", "Add child" ], [ "M", "Merge" ] ];
Lino.cal.DurationUnits = [ [ "s", "seconds" ], [ "m", "minutes" ], [ "h", "hours" ], [ "D", "days" ], [ "W", "weeks" ], [ "M", "months" ], [ "Y", "years" ] ];
Lino.uploads.UploadAreas = [ [ "90", "Uploads" ] ];
Lino.cal.TaskStates = [ [ "10", "To do" ], [ "15", "Important" ], [ "20", "Started" ], [ "30", "Done" ], [ "50", "T\u00fchistatud" ] ];
Lino.addresses.DataSources = [ [ "01", "Manually entered" ], [ "02", "Read from eID" ] ];
Lino.cal.Weekdays = [ [ "1", "esmasp\u00e4ev" ], [ "2", "teisip\u00e4ev" ], [ "3", "kolmap\u00e4ev" ], [ "4", "neljap\u00e4ev" ], [ "5", "reede" ], [ "6", "laup\u00e4ev" ], [ "7", "p\u00fchap\u00e4ev" ] ];
Lino.outbox.RecipientTypes = [ [ "to", "to" ], [ "cc", "cc" ], [ "bcc", "bcc" ] ];
Lino.excerpts.Shortcuts = [  ];
Lino.system.PeriodEvents = [ [ "10", "Starts" ], [ "20", "Is active" ], [ "30", "Ends" ] ];
Lino.clocking.ReportingTypes = [ [ "10", "Regular" ], [ "20", "Extra" ], [ "30", "Free" ] ];
Lino.notify.MessageTypes = [ [ "100", "System event" ], [ "200", "Change" ], [ "300", "Action" ] ];
Lino.tickets.LinkTypes = [ [ "10", "Requires" ], [ "20", "Triggers" ], [ "30", "Suggests" ], [ "40", "Obsoletes" ] ];
Lino.cal.Recurrencies = [ [ "O", "once" ], [ "D", "daily" ], [ "W", "weekly" ], [ "M", "monthly" ], [ "Y", "yearly" ], [ "P", "per weekday" ], [ "E", "Relative to Easter" ] ];
Lino.system.Genders = [ [ "M", "Mees" ], [ "F", "Naine" ] ];
Lino.uploads.Shortcuts = [  ];
Lino.courses.EnrolmentStates = [ [ "10", "Taotlus" ], [ "11", "Katseaeg" ], [ "20", "Kinnitatud" ], [ "30", "T\u00fchistatud" ] ];
Lino.tickets.ProjectEvents = [ [ "started", "Starts" ], [ "active", "Is active" ], [ "ended", "Ends" ], [ "modified", "Muudatud" ], [ "clocking", "Has been worked on" ] ];
Lino.cal.EventEvents = [ [ "10", "Stable" ], [ "20", "Unstable" ] ];
Lino.votes.Ratings = [ [ "10", "Very good" ], [ "20", "Good" ], [ "30", "Satisfying" ], [ "40", "Deficient" ], [ "50", "Insufficient" ], [ "90", "Unratable" ] ];
Lino.cal.GuestStates = [ [ "10", "Kutsutud" ], [ "40", "Kohal" ], [ "50", "Puudus" ], [ "60", "Excused" ] ];
Lino.meetings.MeetingStates = [ [ "10", "Kavand" ], [ "20", "Alanud" ], [ "30", "Inactive" ], [ "40", "Finished" ] ];
Lino.votes.VoteStates = [ [ "00", "Autor" ], [ "05", "Kutsutud" ], [ "10", "Huvi" ], [ "20", "Kandidaat" ], [ "30", "Assigned" ], [ "40", "Done" ], [ "50", "Hinnatud" ], [ "60", "T\u00fchistatud" ] ];
Lino.addresses.AddressTypes = [ [ "01", "Official address" ], [ "02", "Unverified address" ], [ "03", "Declared address" ], [ "04", "Reference address" ], [ "98", "Obsolete" ], [ "99", "Other" ] ];
Lino.printing.BuildMethods = [ [ "latex", "LatexBuildMethod" ], [ "pisa", "PisaBuildMethod" ], [ "rtf", "RtfBuildMethod" ], [ "weasy2html", "WeasyHtmlBuildMethod" ], [ "weasy2pdf", "WeasyPdfBuildMethod" ] ];
Lino.cal.EntryStates = [ [ "10", "Ettepanek" ], [ "20", "Kavand" ], [ "50", "Leidis aset" ], [ "70", "T\u00fchistatud" ] ];
Lino.tickets.TicketEvents = [ [ "created", "Loodud" ], [ "modified", "Muudatud" ], [ "todo", "To do" ], [ "clocking", "Has been worked on" ] ];
Lino.cal.AccessClasses = [ [ "10", "Private" ], [ "20", "Show busy" ], [ "30", "Public" ] ];
Lino.system.YesNo = [ [ "y", "Jah" ], [ "n", "Ei" ] ];
Lino.votes.VoteEvents = [ [ "created", "Loodud" ] ];
Lino.users.UserTypes = [ [ "000", "000 (Anon\u00fc\u00fcmne)" ], [ "100", "100 (Kasutaja)" ], [ "200", "200 (Collector)" ], [ "300", "300 (Project manager)" ], [ "800", "800 (Staff)" ], [ "900", "900 (Administraator)" ] ];
Lino.deploy.WishTypes = [ [ "10", "Agenda item" ], [ "20", "New feature" ], [ "22", "Optimization" ], [ "25", "Bugfix" ], [ "30", "Gimmick" ], [ "40", "Side effect" ], [ "50", "Resolution" ], [ "60", "Aftermath" ] ];
Lino.tickets.TicketStates = [ [ "10", "Uus" ], [ "15", "Arutusel" ], [ "20", "Avatud" ], [ "22", "Alanud" ], [ "30", "Magab" ], [ "40", "Valmis" ], [ "50", "L\u00f5petatud" ], [ "60", "Refused" ] ];
Lino.courses.CourseAreas = [ [ "C", "Tegevused" ] ];
Lino.contacts.PartnerEvents = [  ];
Lino.courses.CourseStates = [ [ "10", "Kavand" ], [ "20", "Alanud" ], [ "30", "Inactive" ], [ "40", "L\u00f5petatud" ] ];
Lino.countries.PlaceTypes = [ [ "10", "Liikmeriik" ], [ "11", "Division" ], [ "12", "Region" ], [ "13", "Community" ], [ "14", "Territory" ], [ "20", "Maakond" ], [ "21", "Provints" ], [ "22", "Shire" ], [ "23", "Subregion" ], [ "24", "Department" ], [ "25", "Arrondissement" ], [ "26", "Prefecture" ], [ "27", "District" ], [ "28", "Sector" ], [ "50", "Linn" ], [ "51", "Linn" ], [ "52", "Vald" ], [ "54", "Parish" ], [ "55", "Linnaosa" ], [ "56", "Linnaosa" ], [ "61", "Alevik" ], [ "62", "Alevik" ], [ "70", "K\u00fcla" ] ];
Lino.users.UserStates = [ [ "10", "Uus" ], [ "20", "Active" ], [ "30", "Inactive" ] ];

Lino.cal.Tasks.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var start_date1 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(cal.Tasks.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date2 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(cal.Tasks.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var user3 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Managed by</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Managed by","(cal.Tasks.user) Only rows managed by this user.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Tasks/user" }) }) });
    var state4 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(cal.Tasks.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.TaskStates) });
    var main_1_panel5 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": start_date1, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": end_date2, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": user3, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": state4, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel5 ];
    this.fields = [ start_date1, end_date2, user3, state4 ];
    Lino.cal.Tasks.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Tickets.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user11 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(tickets.Tickets.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/user" }) }) });
    var end_user12 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">End user</span>", "hiddenName": "end_userHidden", "listeners": { "render": Lino.quicktip_renderer("End user","(tickets.Tickets.end_user) Only rows concerning this end user.") }, "name": "end_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/end_user" }) }) });
    var assigned_to13 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Voted by</span>", "hiddenName": "assigned_toHidden", "listeners": { "render": Lino.quicktip_renderer("Voted by","(tickets.Tickets.assigned_to) Only tickets having a vote by this user.") }, "name": "assigned_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/assigned_to" }) }) });
    var not_assigned_to14 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Not voted by</span>", "hiddenName": "not_assigned_toHidden", "listeners": { "render": Lino.quicktip_renderer("Not voted by","(tickets.Tickets.not_assigned_to) Only tickets having no vote by this user.") }, "name": "not_assigned_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/not_assigned_to" }) }) });
    var interesting_for15 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Interesting for</span>", "hiddenName": "interesting_forHidden", "listeners": { "render": Lino.quicktip_renderer("Interesting for","(tickets.Tickets.interesting_for) Only tickets interesting for this partner.") }, "name": "interesting_for", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/interesting_for" }) }) });
    var site16 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Ruum</span>", "hiddenName": "siteHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(tickets.Tickets.site) Select a site if you want to see only tickets for this site.") }, "name": "site", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/site" }) }) });
    var project17 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Eesm\u00e4rk", "hiddenName": "projectHidden", "listeners": { "render": Lino.quicktip_renderer("Mission","(tickets.Tickets.project) ") }, "name": "project", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Projects.detail,Lino.tickets.Projects.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/project" }) }) });
    var state18 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(tickets.Tickets.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var deployed_to19 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "deployed_toHidden", "listeners": { "render": Lino.quicktip_renderer("Activity","(tickets.Tickets.deployed_to) ") }, "name": "deployed_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/deployed_to" }) }) });
    var main_1_panel20 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 11, "items": user11, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": end_user12, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": assigned_to13, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": not_assigned_to14, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": interesting_for15, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": site16, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": project17, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 6, "items": state18, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": deployed_to19, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var has_project30 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Has project</span>", "forceSelection": true, "hiddenName": "has_projectHidden", "listeners": { "render": Lino.quicktip_renderer("Has project","(tickets.Tickets.has_project) Show only (or hide) tickets which have a project assigned.") }, "name": "has_project", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var show_assigned31 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Assigned</span>", "forceSelection": true, "hiddenName": "show_assignedHidden", "listeners": { "render": Lino.quicktip_renderer("Assigned","(tickets.Tickets.show_assigned) Show only (or hide) tickets that are assigned to somebody.") }, "name": "show_assigned", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var show_active32 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Active</span>", "forceSelection": true, "hiddenName": "show_activeHidden", "listeners": { "render": Lino.quicktip_renderer("Active","(tickets.Tickets.show_active) Show only (or hide) tickets which are active (i.e. state is Talk\nor ToDo).") }, "name": "show_active", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var show_deployed33 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Deployed</span>", "forceSelection": true, "hiddenName": "show_deployedHidden", "listeners": { "render": Lino.quicktip_renderer("Deployed","(tickets.Tickets.show_deployed) Whether to show tickets with at least one deployment") }, "name": "show_deployed", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var show_todo34 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">To do</span>", "forceSelection": true, "hiddenName": "show_todoHidden", "listeners": { "render": Lino.quicktip_renderer("To do","(tickets.Tickets.show_todo) Show only (or hide) tickets which are todo (i.e. state is New\nor ToDo).") }, "name": "show_todo", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var show_private35 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Private</span>", "forceSelection": true, "hiddenName": "show_privateHidden", "listeners": { "render": Lino.quicktip_renderer("Private","(tickets.Tickets.show_private) Show only (or hide) tickets that are marked private.") }, "name": "show_private", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_2_panel36 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": has_project30, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_assigned31, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_active32, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_deployed33, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_todo34, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_private35, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date43 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(tickets.Tickets.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date44 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(tickets.Tickets.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event45 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Observed event", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(tickets.Tickets.observed_event) ") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketEvents) });
    var topic46 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(tickets.Tickets.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.topics.Topics.detail,Lino.topics.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/topic" }) }) });
    var feasable_by47 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Feasable by</span>", "hiddenName": "feasable_byHidden", "listeners": { "render": Lino.quicktip_renderer("Feasable by","(tickets.Tickets.feasable_by) Show only tickets for which the given supplier is competent.") }, "name": "feasable_by", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/feasable_by" }) }) });
    var has_ref48 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Has reference", "forceSelection": true, "hiddenName": "has_refHidden", "listeners": { "render": Lino.quicktip_renderer("Has reference","(tickets.Tickets.has_ref) ") }, "name": "has_ref", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_3_panel49 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 13, "items": start_date43, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": end_date44, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event45, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": topic46, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": feasable_by47, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": has_ref48, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel20, main_2_panel36, main_3_panel49 ];
    this.fields = [ user11, end_user12, assigned_to13, not_assigned_to14, interesting_for15, site16, project17, state18, deployed_to19, has_project30, show_assigned31, show_active32, show_deployed33, show_todo34, show_private35, start_date43, end_date44, observed_event45, topic46, feasable_by47, has_ref48 ];
    Lino.tickets.Tickets.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.Votes.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user57 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "S\u00f5nav\u00f5tja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Voter","(votes.Votes.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/Votes/user" }) }) });
    var mail_mode58 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Email notification mode</span>", "forceSelection": true, "hiddenName": "mail_modeHidden", "listeners": { "render": Lino.quicktip_renderer("Email notification mode","(votes.Votes.mail_mode) Only rows having this mail mode.") }, "name": "mail_mode", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.notify.MailModes) });
    var state59 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(votes.Votes.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.votes.VoteStates) });
    var votable_state60 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Lipik state</span>", "forceSelection": true, "hiddenName": "votable_stateHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket state","(votes.Votes.votable_state) Only rows whose Ticket has this state.") }, "name": "votable_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var ticket_user61 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Autor</span>", "hiddenName": "ticket_userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(votes.Votes.ticket_user) Only rows on votables whose author is this user.") }, "name": "ticket_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/Votes/ticket_user" }) }) });
    var main_1_panel62 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 27, "items": user57, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": mail_mode58, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": state59, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": votable_state60, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": ticket_user61, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date68 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(votes.Votes.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date69 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(votes.Votes.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event70 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Observed event</span>", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(votes.Votes.observed_event) There are two class attributes for defining a filter conditions\nwhich canot be removed by the user:") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.votes.VoteEvents) });
    var exclude_ticket_user71 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Exclude author</span>", "hiddenName": "exclude_ticket_userHidden", "listeners": { "render": Lino.quicktip_renderer("Exclude author","(votes.Votes.exclude_ticket_user) Only rows on votables whose author is not this user.") }, "name": "exclude_ticket_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/Votes/exclude_ticket_user" }) }) });
    var main_2_panel72 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 23, "items": start_date68, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": end_date69, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 17, "items": observed_event70, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 35, "items": exclude_ticket_user71, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel62, main_2_panel72 ];
    this.fields = [ user57, mail_mode58, state59, votable_state60, ticket_user61, start_date68, end_date69, observed_event70, exclude_ticket_user71 ];
    Lino.votes.Votes.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.CoursesByTopic.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 126,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var line78 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "fieldLabel": "Tegevuste sari", "hiddenName": "lineHidden", "listeners": { "render": Lino.quicktip_renderer("Activity line","(courses.CoursesByTopic.line) ") }, "name": "line", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Lines.detail,Lino.courses.Lines.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/line" }) }) });
    var teacher79 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "\u00dcrituse juht", "hiddenName": "teacherHidden", "listeners": { "render": Lino.quicktip_renderer("Instructor","(courses.CoursesByTopic.teacher) ") }, "name": "teacher", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/teacher" }) }) });
    var user80 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.CoursesByTopic.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/user" }) }) });
    var state81 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(courses.CoursesByTopic.state) ") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.courses.CourseStates) });
    var can_enroll82 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "can enroll", "forceSelection": true, "hiddenName": "can_enrollHidden", "listeners": { "render": Lino.quicktip_renderer("can enroll","(courses.CoursesByTopic.can_enroll) ") }, "name": "can_enroll", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    this.items = [ { "autoHeight": true, "flex": 24, "items": line78, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": teacher79, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": user80, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": state81, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": can_enroll82, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ line78, teacher79, user80, state81, can_enroll82 ];
    Lino.courses.CoursesByTopic.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Events.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var start_date89 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(cal.Events.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date90 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(cal.Events.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event91 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Observed event", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(cal.Events.observed_event) ") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.EventEvents) });
    var state92 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(cal.Events.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.EntryStates) });
    var main_1_panel93 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 26, "items": start_date89, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": end_date90, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event91, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": state92, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user98 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Managed by</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Managed by","(cal.Events.user) Only rows managed by this user.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/user" }) }) });
    var assigned_to99 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Assigned to</span>", "hiddenName": "assigned_toHidden", "listeners": { "render": Lino.quicktip_renderer("Assigned to","(cal.Events.assigned_to) Only events assigned to this user.") }, "name": "assigned_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/assigned_to" }) }) });
    var event_type100 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "S\u00fcndmuseliik", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(cal.Events.event_type) ") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/event_type" }) }) });
    var room101 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(cal.Events.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/room" }) }) });
    var show_appointments102 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kokku leppitud ajad</span>", "forceSelection": true, "hiddenName": "show_appointmentsHidden", "listeners": { "render": Lino.quicktip_renderer("Appointments","(cal.Events.show_appointments) Whether only appointments should be\nshown.  \"Yes\" means only appointments, \"No\"\nmeans no appointments and leaving it to blank shows both types\nof events.") }, "name": "show_appointments", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_2_panel103 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": user98, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": assigned_to99, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": event_type100, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": room101, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": show_appointments102, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel93, main_2_panel103 ];
    this.fields = [ start_date89, end_date90, observed_event91, state92, user98, assigned_to99, event_type100, room101, show_appointments102 ];
    Lino.cal.Events.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.Uploads.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 108,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var start_date110 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(uploads.Uploads.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date111 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(uploads.Uploads.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var user112 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Uploaded by", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Uploaded by","(uploads.Uploads.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/user" }) }) });
    var upload_type113 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Upload Type...", "fieldLabel": "Upload Type", "hiddenName": "upload_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Type","(uploads.Uploads.upload_type) ") }, "name": "upload_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.uploads.UploadTypes.detail,Lino.uploads.UploadTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/upload_type" }) }) });
    this.items = [ { "autoHeight": true, "flex": 19, "items": start_date110, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date111, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": user112, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": upload_type113, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date110, end_date111, user112, upload_type113 ];
    Lino.uploads.Uploads.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.Comments.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user119 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(comments.Comments.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user119, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user119 ];
    Lino.comments.Comments.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.Entries.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user122 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(blogs.Entries.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user122, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user122 ];
    Lino.blogs.Entries.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var topic125 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(courses.Activities.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Topics.detail,Lino.courses.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/topic" }) }) });
    var line126 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "fieldLabel": "Tegevuste sari", "hiddenName": "lineHidden", "listeners": { "render": Lino.quicktip_renderer("Activity line","(courses.Activities.line) ") }, "name": "line", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Lines.detail,Lino.courses.Lines.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/line" }) }) });
    var user127 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.Activities.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/user" }) }) });
    var teacher128 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "\u00dcrituse juht", "hiddenName": "teacherHidden", "listeners": { "render": Lino.quicktip_renderer("Instructor","(courses.Activities.teacher) ") }, "name": "teacher", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/teacher" }) }) });
    var state129 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(courses.Activities.state) ") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.courses.CourseStates) });
    var main_1_panel130 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": topic125, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": line126, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": user127, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": teacher128, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": state129, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var room136 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(courses.Activities.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/room" }) }) });
    var can_enroll137 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "can enroll", "forceSelection": true, "hiddenName": "can_enrollHidden", "listeners": { "render": Lino.quicktip_renderer("can enroll","(courses.Activities.can_enroll) ") }, "name": "can_enroll", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var start_date138 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(courses.Activities.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date139 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(courses.Activities.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var show_active140 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Active</span>", "forceSelection": true, "hiddenName": "show_activeHidden", "listeners": { "render": Lino.quicktip_renderer("Active","(courses.Activities.show_active) Whether to show rows in some active state") }, "name": "show_active", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_2_panel141 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 31, "items": room136, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": can_enroll137, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": start_date138, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": end_date139, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": show_active140, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel130, main_2_panel141 ];
    this.fields = [ topic125, line126, user127, teacher128, state129, room136, can_enroll137, start_date138, end_date139, show_active140 ];
    Lino.courses.Activities.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.meetings.Meetings.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user148 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("User","(meetings.Meetings.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/user" }) }) });
    var room149 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(meetings.Meetings.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/room" }) }) });
    var state150 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(meetings.Meetings.state) ") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.meetings.MeetingStates) });
    var show_active151 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Active</span>", "forceSelection": true, "hiddenName": "show_activeHidden", "listeners": { "render": Lino.quicktip_renderer("Active","(meetings.Meetings.show_active) Whether to show rows in some active state") }, "name": "show_active", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var member152 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Member</span>", "forceSelection": true, "hiddenName": "memberHidden", "listeners": { "render": Lino.quicktip_renderer("Member","(meetings.Meetings.member) Whether to show rows that you are a member of") }, "name": "member", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_1_panel153 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": user148, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": room149, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": state150, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": show_active151, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": member152, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date159 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(meetings.Meetings.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date160 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(meetings.Meetings.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var main_2_panel161 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": start_date159, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": end_date160, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel153, main_2_panel161 ];
    this.fields = [ user148, room149, state150, show_active151, member152, start_date159, end_date160 ];
    Lino.meetings.Meetings.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.MyEnrolments.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 162,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var start_date165 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(courses.MyEnrolments.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date166 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(courses.MyEnrolments.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var author167 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "authorHidden", "listeners": { "render": Lino.quicktip_renderer("User","(courses.MyEnrolments.author) ") }, "name": "author", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyEnrolments/author" }) }) });
    var state168 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(courses.MyEnrolments.state) ") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.courses.EnrolmentStates) });
    var active169 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Active</span>", "forceSelection": true, "hiddenName": "activeHidden", "listeners": { "render": Lino.quicktip_renderer("Active","(courses.MyEnrolments.active) Filter courses that are either active/draft or inactive/closed") }, "name": "active", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var participants_only170 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Participants only", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Participants only","(courses.MyEnrolments.participants_only) Hide cancelled enrolments. Ignored if you specify an explicit enrolment state.") }, "name": "participants_only", "selectOnFocus": true });
    this.items = [ { "autoHeight": true, "flex": 17, "items": start_date165, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 17, "items": end_date166, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": author167, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": state168, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": active169, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": participants_only170, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date165, end_date166, author167, state168, active169, participants_only170 ];
    Lino.courses.MyEnrolments.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Guests.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  labelWidth: 72,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var start_date178 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(cal.Guests.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date179 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(cal.Guests.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var user180 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Responsible user</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Responsible user","(cal.Guests.user) Only rows managed by this user.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/user" }) }) });
    var event_state181 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Event state</span>", "forceSelection": true, "hiddenName": "event_stateHidden", "listeners": { "render": Lino.quicktip_renderer("Event state","(cal.Guests.event_state) Only rows having this event state.") }, "name": "event_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.EntryStates) });
    var guest_state182 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Guest state</span>", "forceSelection": true, "hiddenName": "guest_stateHidden", "listeners": { "render": Lino.quicktip_renderer("Guest state","(cal.Guests.guest_state) Only rows having this guest state.") }, "name": "guest_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.GuestStates) });
    var main_1_panel183 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 18, "items": start_date178, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": end_date179, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": user180, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": event_state181, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": guest_state182, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var partner189 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "Partner", "hiddenName": "partnerHidden", "listeners": { "render": Lino.quicktip_renderer("Partner","(cal.Guests.partner) ") }, "name": "partner", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/partner" }) }) });
    this.items = [ main_1_panel183, { "anchor": "-20", "autoHeight": true, "items": partner189, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date178, end_date179, user180, event_state181, guest_state182, partner189 ];
    Lino.cal.Guests.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.dashboard.Widgets.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user192 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(dashboard.Widgets.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/Widgets/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user192, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user192 ];
    Lino.dashboard.Widgets.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Offers.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 45,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user195 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("User","(faculties.Offers.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user195, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user195 ];
    Lino.faculties.Offers.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.tinymce.TextFieldTemplates.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user198 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(tinymce.TextFieldTemplates.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tinymce/TextFieldTemplates/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user198, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user198 ];
    Lino.tinymce.TextFieldTemplates.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.MyTickets.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user201 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(tickets.MyTickets.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/user" }) }) });
    var end_user202 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">End user</span>", "hiddenName": "end_userHidden", "listeners": { "render": Lino.quicktip_renderer("End user","(tickets.MyTickets.end_user) Only rows concerning this end user.") }, "name": "end_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/end_user" }) }) });
    var site203 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Ruum</span>", "hiddenName": "siteHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(tickets.MyTickets.site) Select a site if you want to see only tickets for this site.") }, "name": "site", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/site" }) }) });
    var project204 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Eesm\u00e4rk", "hiddenName": "projectHidden", "listeners": { "render": Lino.quicktip_renderer("Mission","(tickets.MyTickets.project) ") }, "name": "project", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Projects.detail,Lino.tickets.Projects.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/project" }) }) });
    var state205 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(tickets.MyTickets.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var main_1_panel206 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": user201, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": end_user202, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": site203, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": project204, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": state205, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date212 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(tickets.MyTickets.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date213 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(tickets.MyTickets.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event214 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Observed event", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(tickets.MyTickets.observed_event) ") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketEvents) });
    var topic215 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(tickets.MyTickets.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.topics.Topics.detail,Lino.topics.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/topic" }) }) });
    var feasable_by216 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Feasable by</span>", "hiddenName": "feasable_byHidden", "listeners": { "render": Lino.quicktip_renderer("Feasable by","(tickets.MyTickets.feasable_by) Show only tickets for which the given supplier is competent.") }, "name": "feasable_by", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/feasable_by" }) }) });
    var show_active217 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Active</span>", "forceSelection": true, "hiddenName": "show_activeHidden", "listeners": { "render": Lino.quicktip_renderer("Active","(tickets.MyTickets.show_active) Show only (or hide) tickets which are active (i.e. state is Talk\nor ToDo).") }, "name": "show_active", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_2_panel218 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 13, "items": start_date212, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": end_date213, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event214, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": topic215, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": feasable_by216, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": show_active217, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel206, main_2_panel218 ];
    this.fields = [ user201, end_user202, site203, project204, state205, start_date212, end_date213, observed_event214, topic215, feasable_by216, show_active217 ];
    Lino.tickets.MyTickets.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.OneEvent.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var start_date226 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(cal.OneEvent.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date227 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(cal.OneEvent.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event228 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Observed event", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(cal.OneEvent.observed_event) ") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.EventEvents) });
    var state229 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(cal.OneEvent.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.EntryStates) });
    var main_1_panel230 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 26, "items": start_date226, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": end_date227, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event228, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": state229, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user235 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Managed by</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Managed by","(cal.OneEvent.user) Only rows managed by this user.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/user" }) }) });
    var assigned_to236 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Assigned to</span>", "hiddenName": "assigned_toHidden", "listeners": { "render": Lino.quicktip_renderer("Assigned to","(cal.OneEvent.assigned_to) Only events assigned to this user.") }, "name": "assigned_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/assigned_to" }) }) });
    var event_type237 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "S\u00fcndmuseliik", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(cal.OneEvent.event_type) ") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/event_type" }) }) });
    var room238 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(cal.OneEvent.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/room" }) }) });
    var show_appointments239 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kokku leppitud ajad</span>", "forceSelection": true, "hiddenName": "show_appointmentsHidden", "listeners": { "render": Lino.quicktip_renderer("Appointments","(cal.OneEvent.show_appointments) Whether only appointments should be\nshown.  \"Yes\" means only appointments, \"No\"\nmeans no appointments and leaving it to blank shows both types\nof events.") }, "name": "show_appointments", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_2_panel240 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": user235, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": assigned_to236, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": event_type237, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": room238, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": show_appointments239, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel230, main_2_panel240 ];
    this.fields = [ start_date226, end_date227, observed_event228, state229, user235, assigned_to236, event_type237, room238, show_appointments239 ];
    Lino.cal.OneEvent.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Subscriptions.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user247 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(cal.Subscriptions.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Subscriptions/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user247, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user247 ];
    Lino.cal.Subscriptions.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.SuggestedTicketsByEndUser.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var end_user250 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">End user</span>", "hiddenName": "end_userHidden", "listeners": { "render": Lino.quicktip_renderer("End user","(tickets.SuggestedTicketsByEndUser.end_user) Only rows concerning this end user.") }, "name": "end_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/end_user" }) }) });
    var feasable_by251 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Feasable by</span>", "hiddenName": "feasable_byHidden", "listeners": { "render": Lino.quicktip_renderer("Feasable by","(tickets.SuggestedTicketsByEndUser.feasable_by) Show only tickets for which the given supplier is competent.") }, "name": "feasable_by", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/feasable_by" }) }) });
    var site252 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Ruum</span>", "hiddenName": "siteHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(tickets.SuggestedTicketsByEndUser.site) Select a site if you want to see only tickets for this site.") }, "name": "site", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/site" }) }) });
    var project253 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Eesm\u00e4rk", "hiddenName": "projectHidden", "listeners": { "render": Lino.quicktip_renderer("Mission","(tickets.SuggestedTicketsByEndUser.project) ") }, "name": "project", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Projects.detail,Lino.tickets.Projects.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/project" }) }) });
    var state254 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(tickets.SuggestedTicketsByEndUser.state) Only rows having this state.") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var main_1_panel255 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": end_user250, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": feasable_by251, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": site252, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": project253, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": state254, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var show_assigned261 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Assigned</span>", "forceSelection": true, "hiddenName": "show_assignedHidden", "listeners": { "render": Lino.quicktip_renderer("Assigned","(tickets.SuggestedTicketsByEndUser.show_assigned) Show only (or hide) tickets that are assigned to somebody.") }, "name": "show_assigned", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var show_active262 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Active</span>", "forceSelection": true, "hiddenName": "show_activeHidden", "listeners": { "render": Lino.quicktip_renderer("Active","(tickets.SuggestedTicketsByEndUser.show_active) Show only (or hide) tickets which are active (i.e. state is Talk\nor ToDo).") }, "name": "show_active", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var topic263 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(tickets.SuggestedTicketsByEndUser.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.topics.Topics.detail,Lino.topics.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/topic" }) }) });
    var main_2_panel264 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 20, "items": show_assigned261, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": show_active262, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 58, "items": topic263, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel255, main_2_panel264 ];
    this.fields = [ end_user250, feasable_by251, site252, project253, state254, show_assigned261, show_active262, topic263 ];
    Lino.tickets.SuggestedTicketsByEndUser.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.ServiceReports.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 108,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var user269 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(clocking.ServiceReports.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/user" }) }) });
    var end_date270 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(clocking.ServiceReports.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var start_date271 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(clocking.ServiceReports.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    this.items = [ { "autoHeight": true, "flex": 43, "items": user269, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": end_date270, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": start_date271, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user269, end_date270, start_date271 ];
    Lino.clocking.ServiceReports.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Persons.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 135,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var observed_event276 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Observed event</span>", "listeners": { "render": Lino.quicktip_renderer("Observed event","(contacts.Persons.observed_event) Extended filter criteria") }, "maxLength": 50, "name": "observed_event", "selectOnFocus": true });
    var start_date277 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(contacts.Persons.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date278 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(contacts.Persons.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var skill279 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(contacts.Persons.skill) ") }, "name": "skill", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Persons/skill" }) }) });
    var company280 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "Organisatsioon", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organization","(contacts.Persons.company) ") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Persons/company" }) }) });
    this.items = [ { "autoHeight": true, "flex": 24, "items": observed_event276, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": start_date277, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": end_date278, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": skill279, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": company280, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ observed_event276, start_date277, end_date278, skill279, company280 ];
    Lino.contacts.Persons.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.Excerpts.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  autoHeight: true,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var start_date287 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(excerpts.Excerpts.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date288 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(excerpts.Excerpts.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var pcertifying289 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Certifying excerpts", "forceSelection": true, "hiddenName": "pcertifyingHidden", "listeners": { "render": Lino.quicktip_renderer("Certifying excerpts","(excerpts.Excerpts.pcertifying) ") }, "name": "pcertifying", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var main_1_panel290 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": start_date287, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": end_date288, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": pcertifying289, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user294 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(excerpts.Excerpts.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/user" }) }) });
    var excerpt_type295 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "fieldLabel": "V\u00e4ljav\u00f5teliik", "hiddenName": "excerpt_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Excerpt Type","(excerpts.Excerpts.excerpt_type) ") }, "name": "excerpt_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.excerpts.ExcerptTypes.detail,Lino.excerpts.ExcerptTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/excerpt_type" }) }) });
    var main_2_panel296 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": user294, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": excerpt_type295, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel290, main_2_panel296 ];
    this.fields = [ start_date287, end_date288, pcertifying289, user294, excerpt_type295 ];
    Lino.excerpts.Excerpts.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.changes.Changes.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var date300 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Only changes from", "listeners": { "render": Lino.quicktip_renderer("Only changes from","(changes.Changes.date) ") }, "name": "date", "selectOnFocus": true });
    var user301 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("User","(changes.Changes.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/user" }) }) });
    var change_type302 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Change Type", "forceSelection": false, "hiddenName": "change_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Change Type","(changes.Changes.change_type) ") }, "name": "change_type", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.changes.ChangeTypes) });
    var object_type303 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "fieldLabel": "Object type", "hiddenName": "object_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Object type","(changes.Changes.object_type) ") }, "name": "object_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.gfks.ContentTypes.detail,Lino.gfks.ContentTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/object_type" }) }) });
    var object_id304 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Object ID", "hiddenName": "object_idHidden", "listeners": { "render": Lino.quicktip_renderer("Object ID","(changes.Changes.object_id) ") }, "name": "object_id", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/object_id" }) }) });
    var main_1_panel305 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": date300, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": user301, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": change_type302, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": object_type303, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": object_id304, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel305 ];
    this.fields = [ date300, user301, change_type302, object_type303, object_id304 ];
    Lino.changes.Changes.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Projects.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 144,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var interesting_for312 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Interesting for</span>", "hiddenName": "interesting_forHidden", "listeners": { "render": Lino.quicktip_renderer("Interesting for","(tickets.Projects.interesting_for) Only projects interesting for this partner.") }, "name": "interesting_for", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/interesting_for" }) }) });
    var start_date313 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(tickets.Projects.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date314 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(tickets.Projects.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event315 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Observed event", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(tickets.Projects.observed_event) ") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.ProjectEvents) });
    this.items = [ { "autoHeight": true, "flex": 29, "items": interesting_for312, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_date313, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date314, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": observed_event315, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ interesting_for312, start_date313, end_date314, observed_event315 ];
    Lino.tickets.Projects.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Users.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 135,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var profile321 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajaliik", "forceSelection": true, "hiddenName": "profileHidden", "listeners": { "render": Lino.quicktip_renderer("User type","(users.Users.profile) ") }, "name": "profile", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var end_date322 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(users.Users.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var gender323 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Sugu</span>", "forceSelection": true, "hiddenName": "genderHidden", "listeners": { "render": Lino.quicktip_renderer("Gender","(users.Users.gender) Show only persons with the given gender.") }, "name": "gender", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var company324 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "Organisatsioon", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organization","(users.Users.company) ") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/company" }) }) });
    var observed_event325 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Observed event</span>", "listeners": { "render": Lino.quicktip_renderer("Observed event","(users.Users.observed_event) Extended filter criteria") }, "maxLength": 50, "name": "observed_event", "selectOnFocus": true });
    var aged_from326 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Aged from</span>", "listeners": { "render": Lino.quicktip_renderer("Aged from","(users.Users.aged_from) Select only persons aged at least the given number of years.") }, "name": "aged_from", "selectOnFocus": true });
    var user_state327 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutaja olek", "forceSelection": true, "hiddenName": "user_stateHidden", "listeners": { "render": Lino.quicktip_renderer("User state","(users.Users.user_state) ") }, "name": "user_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserStates) });
    var skill328 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(users.Users.skill) ") }, "name": "skill", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/skill" }) }) });
    var start_date329 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(users.Users.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var aged_to330 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Aged to</span>", "listeners": { "render": Lino.quicktip_renderer("Aged to","(users.Users.aged_to) Select only persons aged at most the given number of years.") }, "name": "aged_to", "selectOnFocus": true });
    this.items = [ { "autoHeight": true, "flex": 17, "items": profile321, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": end_date322, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 6, "items": gender323, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": company324, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": observed_event325, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 3, "items": aged_from326, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": user_state327, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": skill328, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": start_date329, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 3, "items": aged_to330, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ profile321, end_date322, gender323, company324, observed_event325, aged_from326, user_state327, skill328, start_date329, aged_to330 ];
    Lino.users.Users.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.notify.Messages.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 108,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var user342 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("User","(notify.Messages.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/Messages/user" }) }) });
    var show_seen343 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Seen", "forceSelection": true, "hiddenName": "show_seenHidden", "listeners": { "render": Lino.quicktip_renderer("Seen","(notify.Messages.show_seen) ") }, "name": "show_seen", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    var start_date344 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(notify.Messages.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date345 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(notify.Messages.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    this.items = [ { "autoHeight": true, "flex": 37, "items": user342, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": show_seen343, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": start_date344, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": end_date345, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user342, show_seen343, start_date344, end_date345 ];
    Lino.notify.Messages.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.outbox.Mails.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user351 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Sender", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Sender","(outbox.Mails.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Mails/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user351, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user351 ];
    Lino.outbox.Mails.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.RecurrentEvents.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user354 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(cal.RecurrentEvents.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/RecurrentEvents/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user354, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user354 ];
    Lino.cal.RecurrentEvents.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Authorities.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 63,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var user357 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(users.Authorities.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Authorities/user" }) }) });
    this.items = [ { "autoHeight": true, "items": user357, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user357 ];
    Lino.users.Authorities.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Partners.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 135,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var observed_event360 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Observed event</span>", "listeners": { "render": Lino.quicktip_renderer("Observed event","(contacts.Partners.observed_event) Extended filter criteria") }, "maxLength": 50, "name": "observed_event", "selectOnFocus": true });
    var start_date361 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(contacts.Partners.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date362 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(contacts.Partners.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    this.items = [ { "autoHeight": true, "flex": 44, "items": observed_event360, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": start_date361, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": end_date362, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ observed_event360, start_date361, end_date362 ];
    Lino.contacts.Partners.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Enrolments.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 162,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var start_date367 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(courses.Enrolments.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date368 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(courses.Enrolments.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var author369 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "authorHidden", "listeners": { "render": Lino.quicktip_renderer("User","(courses.Enrolments.author) ") }, "name": "author", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/author" }) }) });
    var state370 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(courses.Enrolments.state) ") }, "name": "state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.courses.EnrolmentStates) });
    var course_state371 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Course state", "forceSelection": true, "hiddenName": "course_stateHidden", "listeners": { "render": Lino.quicktip_renderer("Course state","(courses.Enrolments.course_state) ") }, "name": "course_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.courses.CourseStates) });
    var participants_only372 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Participants only", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Participants only","(courses.Enrolments.participants_only) Hide cancelled enrolments. Ignored if you specify an explicit enrolment state.") }, "name": "participants_only", "selectOnFocus": true });
    this.items = [ { "autoHeight": true, "flex": 16, "items": start_date367, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": end_date368, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": author369, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": state370, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": course_state371, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": participants_only372, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date367, end_date368, author369, state370, course_state371, participants_only372 ];
    Lino.courses.Enrolments.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.about.Inspector.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 153,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var inspected380 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Inspected object", "listeners": { "render": Lino.quicktip_renderer("Inspected object","(about.Inspector.inspected) ") }, "maxLength": 100, "name": "inspected", "selectOnFocus": true });
    var show_callables381 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "show callables", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("show callables","(about.Inspector.show_callables) ") }, "name": "show_callables", "selectOnFocus": true });
    this.items = [ { "autoHeight": true, "flex": 67, "items": inspected380, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": show_callables381, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ inspected380, show_callables381 ];
    Lino.about.Inspector.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.Deployments.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 108,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var start_date385 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(deploy.Deployments.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date386 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(deploy.Deployments.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var show_closed387 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">show closed</span>", "forceSelection": true, "hiddenName": "show_closedHidden", "listeners": { "render": Lino.quicktip_renderer("show closed","(deploy.Deployments.show_closed) Show deployments on closed milestones.") }, "name": "show_closed", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    this.items = [ { "autoHeight": true, "flex": 39, "items": start_date385, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": end_date386, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": show_closed387, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date385, end_date386, show_closed387 ];
    Lino.deploy.Deployments.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.Sessions.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoHeight: true,
  frame: true,
  layoutConfig: { "align": "stretchmax" },
  hideCheckBoxLabels: true,
  autoScroll: false,
  labelWidth: 135,
  border: false,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'hbox',
  autoHeight: true,
  initComponent : function() {
    var start_date392 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(clocking.Sessions.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var end_date393 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(clocking.Sessions.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true, "value": null });
    var observed_event394 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Observed event", "forceSelection": true, "hiddenName": "observed_eventHidden", "listeners": { "render": Lino.quicktip_renderer("Observed event","(clocking.Sessions.observed_event) ") }, "name": "observed_event", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.PeriodEvents) });
    var company395 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "Organisatsioon", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organization","(clocking.Sessions.company) ") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/company" }) }) });
    var project396 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Eesm\u00e4rk", "hiddenName": "projectHidden", "listeners": { "render": Lino.quicktip_renderer("Mission","(clocking.Sessions.project) ") }, "name": "project", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Projects.detail,Lino.tickets.Projects.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/project" }) }) });
    var user397 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "T\u00f6\u00f6taja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Worker","(clocking.Sessions.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/user" }) }) });
    var session_type398 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Istungiliik...", "fieldLabel": "Istungiliik", "hiddenName": "session_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Session Type","(clocking.Sessions.session_type) ") }, "name": "session_type", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/session_type" }) }) });
    var ticket399 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket","(clocking.Sessions.ticket) ") }, "name": "ticket", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/ticket" }) }) });
    this.items = [ { "autoHeight": true, "flex": 9, "items": start_date392, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": end_date393, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": observed_event394, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": company395, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": project396, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": user397, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": session_type398, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": ticket399, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date392, end_date393, observed_event394, company395, project396, user397, session_type398, ticket399 ];
    Lino.clocking.Sessions.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Users.verify_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 162,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'verify',
  ls_url: "/users/Users",
  window_title: "Verify",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.email409 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "e-mail address", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(Verify.email) ") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    this.verification_code410 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Verification code", "listeners": { "render": Lino.quicktip_renderer("Verification code","(Verify.verification_code) ") }, "maxLength": 50, "name": "verification_code", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.email409, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.verification_code410, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.email409, this.verification_code410 ];
    Lino.users.Users.verify_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.print_presence_sheet_html_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 117,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'print_presence_sheet_html',
  ls_url: "/courses/Activities",
  window_title: "Kohalolekuteleht (HTML)",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.start_date431 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(Presence sheet (HTML).start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true });
    this.end_date432 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(Presence sheet (HTML).end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true });
    this.show_remarks433 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Show remarks", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Show remarks","(Presence sheet (HTML).show_remarks) ") }, "name": "show_remarks", "selectOnFocus": true });
    this.show_states434 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Show states", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Show states","(Presence sheet (HTML).show_states) ") }, "name": "show_states", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.start_date431, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.end_date432, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_remarks433, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_states434, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.start_date431, this.end_date432, this.show_remarks433, this.show_states434 ];
    Lino.courses.Activities.print_presence_sheet_html_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Users.change_password_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 171,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'change_password',
  ls_url: "/users/Users",
  window_title: "Muuda salas\u00f5na",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.current414 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Current password", "inputType": "password", "listeners": { "render": Lino.quicktip_renderer("Current password","(Change password.current) ") }, "maxLength": null, "name": "current", "selectOnFocus": true });
    this.new1415 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "New password", "inputType": "password", "listeners": { "render": Lino.quicktip_renderer("New password","(Change password.new1) ") }, "maxLength": null, "name": "new1", "selectOnFocus": true });
    this.new2416 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "New password again", "inputType": "password", "listeners": { "render": Lino.quicktip_renderer("New password again","(Change password.new2) ") }, "maxLength": null, "name": "new2", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.current414, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.new1415, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.new2416, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.current414, this.new1415, this.new2416 ];
    Lino.users.Users.change_password_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.NewUsers.send_welcome_email_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 135,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'send_welcome_email',
  ls_url: "/users/NewUsers",
  window_title: "Welcome mail",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.email426 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "e-mail address", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(Welcome mail.email) ") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    this.subject427 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Teema", "listeners": { "render": Lino.quicktip_renderer("Subject","(Welcome mail.subject) ") }, "maxLength": 250, "name": "subject", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.email426, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.subject427, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.email426, this.subject427 ];
    Lino.users.NewUsers.send_welcome_email_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.AllUsers.send_welcome_email_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 135,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'send_welcome_email',
  ls_url: "/users/AllUsers",
  window_title: "Welcome mail",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.email421 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "e-mail address", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(Welcome mail.email) ") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    this.subject422 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Teema", "listeners": { "render": Lino.quicktip_renderer("Subject","(Welcome mail.subject) ") }, "maxLength": 250, "name": "subject", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.email421, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.subject422, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.email421, this.subject422 ];
    Lino.users.AllUsers.send_welcome_email_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.print_presence_sheet_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 117,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'print_presence_sheet',
  ls_url: "/courses/Activities",
  window_title: "Kohalolekuteleht",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.start_date440 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Period from</span>", "listeners": { "render": Lino.quicktip_renderer("Period from","(Presence sheet.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true });
    this.end_date441 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">until</span>", "listeners": { "render": Lino.quicktip_renderer("until","(Presence sheet.end_date) End date of observed period") }, "name": "end_date", "selectOnFocus": true });
    this.show_remarks442 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Show remarks", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Show remarks","(Presence sheet.show_remarks) ") }, "name": "show_remarks", "selectOnFocus": true });
    this.show_states443 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Show states", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Show states","(Presence sheet.show_states) ") }, "name": "show_states", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.start_date440, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.end_date441, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_remarks442, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_states443, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.start_date440, this.end_date441, this.show_remarks442, this.show_states443 ];
    Lino.courses.Activities.print_presence_sheet_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.DemandsByDemander.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 46,
  initComponent : function() {
    var skill561 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(faculties.DemandsByDemander.skill) ") }, "name": "skill", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/DemandsByDemander/skill" }) }) });
    var importance562 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Importance</span>", "listeners": { "render": Lino.quicktip_renderer("Importance","(faculties.DemandsByDemander.importance) How important this skill is for this demand. A number between -100 and +100.") }, "name": "importance", "selectOnFocus": true, "value": 100 });
    var main_panel563 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": skill561, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": importance562, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "form" });
    this.items = main_panel563;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.DemandsByDemander.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Persons.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 6,
  initComponent : function() {
    var first_name550 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("First name","(contacts.Persons.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name551 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Last name","(contacts.Persons.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var main_1_panel552 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": first_name550, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": last_name551, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var gender555 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Sugu</span>", "forceSelection": true, "hiddenName": "genderHidden", "listeners": { "render": Lino.quicktip_renderer("Gender","(contacts.Persons.gender) The sex of this person (male or female).") }, "name": "gender", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var language556 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(contacts.Persons.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var main_2_panel557 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 31, "items": gender555, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 68, "items": language556, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel560 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel552, main_2_panel557 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel560;
    this.before_row_edit = function(record) {
    }
    Lino.contacts.Persons.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Persons.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 6,
  initComponent : function() {
    var overview_disp484 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "flex": 40, "listeners": { "render": Lino.quicktip_renderer(null,"(contacts.Persons.overview) ") }, "name": "overview", "value": "<br/>" });
    var last_name485 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Last name","(contacts.Persons.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var first_name486 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("First name","(contacts.Persons.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var gender487 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Sugu</span>", "forceSelection": true, "hiddenName": "genderHidden", "listeners": { "render": Lino.quicktip_renderer("Gender","(contacts.Persons.gender) The sex of this person (male or female).") }, "name": "gender", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var name_box_panel488 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 46, "items": last_name485, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": first_name486, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": gender487, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var email492 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(contacts.Persons.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var gsm493 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">GSM</span>", "listeners": { "render": Lino.quicktip_renderer("GSM","(contacts.Persons.gsm) The primary mobile phone number.") }, "maxLength": 200, "name": "gsm", "selectOnFocus": true });
    var phone494 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Phone</span>", "listeners": { "render": Lino.quicktip_renderer("Phone","(contacts.Persons.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.") }, "maxLength": 200, "name": "phone", "selectOnFocus": true });
    var contact_box_3_panel495 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": gsm493, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": phone494, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var contact_box_panel498 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 60, "frame": true, "hideCheckBoxLabels": true, "items": [ name_box_panel488, { "anchor": "-20", "autoHeight": true, "items": email492, "labelAlign": "top", "layout": "form", "xtype": "panel" }, contact_box_3_panel495 ], "labelAlign": "top", "labelWidth": 135, "layout": "form" });
    var general_1_panel500 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ overview_disp484, contact_box_panel498 ], "labelAlign": "top", "labelWidth": 0, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var contacts_RolesByPerson_grid510 = new Lino.contacts.RolesByPerson.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Contact for","(contacts.contacts.RolesByPerson) Shows all roles of a person.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.contacts.RolesByPerson.grid) ] });
    var comments_CommentsByRFC_htmlbox511 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 50, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Comments","(contacts.Persons.comments_CommentsByRFC) ") }, "master_panel": this, "name": "comments_CommentsByRFC", "title": "Comments", "tools": [ Lino.show_in_own_window_button(Lino.comments.CommentsByRFC.grid) ], "value": "<br/>" });
    var general_2_panel512 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ contacts_RolesByPerson_grid510, comments_CommentsByRFC_htmlbox511 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var general_panel513 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel500, general_2_panel512 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var faculties_OffersByEndUser_grid539 = new Lino.faculties.OffersByEndUser.GridPanel({ "containing_panel": this, "hide_top_toolbar": true, "listeners": { "activate": Lino.on_tab_activate }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "title": "Oskuse pakkumised", "tools": [ Lino.show_in_own_window_button(Lino.faculties.OffersByEndUser.grid) ] });
    var id540 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(contacts.Persons.id) ") }, "name": "id", "selectOnFocus": true });
    var language541 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(contacts.Persons.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url542 = new Lino.URLField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "URL", "listeners": { "render": Lino.quicktip_renderer("URL","(contacts.Persons.url) ") }, "maxLength": 200, "name": "url", "selectOnFocus": true });
    var more_1_panel543 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 13, "items": id540, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": language541, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 58, "items": url542, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks547 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 83, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var more_panel548 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel543, remarks547 ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel549 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel513, faculties_OffersByEndUser_grid539, more_panel548 ], "labelAlign": "top", "split": true });
    this.items = main_panel549;
    this.before_row_edit = function(record) {
      contacts_RolesByPerson_grid510.on_master_changed();
      comments_CommentsByRFC_htmlbox511.refresh();
      faculties_OffersByEndUser_grid539.on_master_changed();
      remarks547.refresh();
    }
    Lino.contacts.Persons.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
  }
});


Lino.outbox.Mails.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 63,
  initComponent : function() {
    var subject566 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Teema", "listeners": { "render": Lino.quicktip_renderer("Subject","(outbox.Mails.subject) ") }, "maxLength": 200, "name": "subject", "selectOnFocus": true });
    var date567 = new Lino.DateField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kuup\u00e4ev</span>", "listeners": { "render": Lino.quicktip_renderer("Date","(outbox.Mails.date) \n        The official date to be printed on the document.\n        ") }, "name": "date", "selectOnFocus": true });
    var main_1_panel568 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": subject566, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": date567, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user571 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Sender", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Sender","(outbox.Mails.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Mails/user" }) }) });
    var sent572 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "sent", "listeners": { "render": Lino.quicktip_renderer("sent","(outbox.Mails.sent) ") }, "name": "sent", "value": "<br>" });
    var id573 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(outbox.Mails.id) ") }, "name": "id", "selectOnFocus": true });
    var owner_disp574 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var main_2_panel575 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": user571, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": sent572, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": id573, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": owner_disp574, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var RecipientsByMail_grid591 = new Lino.outbox.RecipientsByMail.GridPanel({ "containing_panel": this, "flex": 55, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Recipients","(outbox.outbox.RecipientsByMail) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.outbox.RecipientsByMail.grid) ] });
    var outbox_AttachmentsByMail_htmlbox592 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 22, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Attachments","(outbox.Mails.outbox_AttachmentsByMail) ") }, "master_panel": this, "name": "outbox_AttachmentsByMail", "title": "Attachments", "tools": [ Lino.show_in_own_window_button(Lino.outbox.AttachmentsByMail.grid) ], "value": "<br/>" });
    var uploads_UploadsByController_htmlbox593 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 22, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Uploads","(outbox.Mails.uploads_UploadsByController) Shows all Uploads") }, "master_panel": this, "name": "uploads_UploadsByController", "title": "Uploads", "tools": [ Lino.show_in_own_window_button(Lino.uploads.UploadsByController.grid) ], "value": "<br/>" });
    var main_3_panel594 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 29, "frame": false, "hideCheckBoxLabels": true, "items": [ RecipientsByMail_grid591, outbox_AttachmentsByMail_htmlbox592, uploads_UploadsByController_htmlbox593 ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var body595 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Body", "flex": 58, "name": "body", "selectOnFocus": true, "title": "Body" });
    var main_panel596 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel568, main_2_panel575, main_3_panel594, body595 ], "labelAlign": "top", "labelWidth": 45, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel596;
    this.before_row_edit = function(record) {
      RecipientsByMail_grid591.on_master_changed();
      outbox_AttachmentsByMail_htmlbox592.refresh();
      uploads_UploadsByController_htmlbox593.refresh();
      body595.refresh();
    }
    Lino.outbox.Mails.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Lines.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 27,
  initComponent : function() {
    var name597 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimetus</span>", "listeners": { "render": Lino.quicktip_renderer("Designation","(courses.Lines.name) The designation of this activity line as seen by the user\ne.g. when selecting the line.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et598 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(courses.Lines.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel599 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name597, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et598, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var ref602 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(courses.Lines.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var topic603 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(courses.Lines.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Topics.detail,Lino.courses.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/topic" }) }) });
    var main_2_panel604 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": ref602, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": topic603, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var every_unit607 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Korduvus", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Recurrency","(courses.Lines.every_unit) ") }, "name": "every_unit", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every608 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Repeat every","(courses.Lines.every) ") }, "name": "every", "selectOnFocus": true, "value": 1 });
    var event_type609 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">S\u00fcndmuseliik</span>", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(courses.Lines.event_type) The type of calendar entries to be generated. If this is empty, no calendar entries will be generated.") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/event_type" }) }) });
    var main_3_panel610 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 45, "items": every_unit607, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": every608, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": event_type609, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description614 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et615 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var main_4_panel616 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ description614, description_et615 ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel617 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel599, main_2_panel604, main_3_panel610, main_4_panel616 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel617;
    this.before_row_edit = function(record) {
      description614.refresh();
      description_et615.refresh();
    }
    Lino.courses.Lines.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.DeploymentsByTicket.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 50,
  initComponent : function() {
    var milestone618 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "milestoneHidden", "listeners": { "render": Lino.quicktip_renderer("Activity","(deploy.DeploymentsByTicket.milestone) ") }, "name": "milestone", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByTicket/milestone" }) }) });
    var wish_type619 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Wish type", "forceSelection": true, "hiddenName": "wish_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Wish type","(deploy.DeploymentsByTicket.wish_type) ") }, "name": "wish_type", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.deploy.WishTypes) });
    var main_1_panel620 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 57, "items": milestone618, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 42, "items": wish_type619, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remark623 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "M\u00e4rkus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Remark","(deploy.DeploymentsByTicket.remark) ") }, "name": "remark", "selectOnFocus": true });
    var main_panel624 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel620, { "flex": 83, "items": remark623, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel624;
    this.before_row_edit = function(record) {
    }
    Lino.deploy.DeploymentsByTicket.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Guests.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 18,
  initComponent : function() {
    var event626 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni event...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">event</span>", "hiddenName": "eventHidden", "listeners": { "render": Lino.quicktip_renderer("event","(cal.Guests.event) The calendar event to which this presence applies.") }, "name": "event", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.OneEvent.detail,Lino.cal.OneEvent.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/event" }) }) });
    var partner627 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Partner</span>", "hiddenName": "partnerHidden", "listeners": { "render": Lino.quicktip_renderer("Partner","(cal.Guests.partner) The partner to which this presence applies.") }, "name": "partner", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/partner" }) }) });
    var role628 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Guest Role...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Role</span>", "hiddenName": "roleHidden", "listeners": { "render": Lino.quicktip_renderer("Role","(cal.Guests.role) The role of this partner in this presence.") }, "name": "role", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.GuestRoles.detail,Lino.cal.GuestRoles.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/role" }) }) });
    var main_panel629 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": event626, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": partner627, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": role628, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "form" });
    this.items = main_panel629;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Guests.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.EntryTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 58,
  initComponent : function() {
    var id633 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(blogs.EntryTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name634 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(blogs.EntryTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et635 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(blogs.EntryTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel636 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id633, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name634, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et635, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var remark640 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkus", "flex": 5, "name": "remark", "region": "center", "selectOnFocus": true, "split": true, "title": "M\u00e4rkus" });
    var blogs_EntriesByType_grid692 = new Lino.blogs.EntriesByType.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Blog Entries","(blogs.blogs.EntriesByType) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "south", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.blogs.EntriesByType.grid) ] });
    var main_panel693 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel636, remark640, blogs_EntriesByType_grid692 ], "labelAlign": "top", "labelWidth": 63 });
    this.items = main_panel693;
    this.before_row_edit = function(record) {
      remark640.refresh();
      blogs_EntriesByType_grid692.on_master_changed();
    }
    Lino.blogs.EntryTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.OtherUsers.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 10,
  disable_editing: true,
  initComponent : function() {
    var first_name694 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("First name","(users.OtherUsers.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name695 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Last name","(users.OtherUsers.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var city696 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Linn</span>", "forceSelection": false, "hiddenName": "cityHidden", "listeners": { "render": Lino.quicktip_renderer("City","(users.OtherUsers.city) A pointer to Place.") }, "name": "city", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/OtherUsers/city" }) }) });
    var main_1_panel697 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": first_name694, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": last_name695, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": city696, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var phone701 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Phone</span>", "listeners": { "render": Lino.quicktip_renderer("Phone","(users.OtherUsers.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.") }, "maxLength": 200, "name": "phone", "selectOnFocus": true });
    var gsm702 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">GSM</span>", "listeners": { "render": Lino.quicktip_renderer("GSM","(users.OtherUsers.gsm) The primary mobile phone number.") }, "maxLength": 200, "name": "gsm", "selectOnFocus": true });
    var main_2_panel703 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": phone701, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": gsm702, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var about_me_htmlbox706 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 60, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("About me","(users.OtherUsers.about_me) ") }, "name": "about_me", "title": "About me", "value": "<br/>" });
    var main_panel707 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel697, main_2_panel703, about_me_htmlbox706 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel707;
    this.before_row_edit = function(record) {
      about_me_htmlbox706.refresh();
    }
    Lino.users.OtherUsers.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city696.on("change", function(){ this.save() }, this);
  }
});


Lino.tinymce.TextFieldTemplates.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 66,
  initComponent : function() {
    var name708 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(tinymce.TextFieldTemplates.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var user709 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(tinymce.TextFieldTemplates.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tinymce/TextFieldTemplates/user" }) }) });
    var main_panel710 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name708, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user709, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel710;
    this.before_row_edit = function(record) {
    }
    Lino.tinymce.TextFieldTemplates.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.topics.TopicGroups.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 30,
  initComponent : function() {
    var id713 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(topics.TopicGroups.id) ") }, "name": "id", "selectOnFocus": true });
    var name714 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(topics.TopicGroups.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et715 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(topics.TopicGroups.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel716 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id713, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name714, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et715, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var description720 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 5, "name": "description", "region": "center", "selectOnFocus": true, "split": true, "title": "Kirjeldus" });
    var TopicsByGroup_grid765 = new Lino.topics.TopicsByGroup.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Topics","(topics.topics.TopicsByGroup) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "south", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.topics.TopicsByGroup.grid) ] });
    var main_panel766 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel716, description720, TopicsByGroup_grid765 ], "labelAlign": "top", "labelWidth": 108 });
    this.items = main_panel766;
    this.before_row_edit = function(record) {
      description720.refresh();
      TopicsByGroup_grid765.on_master_changed();
    }
    Lino.topics.TopicGroups.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.UploadTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 61,
  initComponent : function() {
    var id767 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(uploads.UploadTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var upload_area768 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Upload Area", "forceSelection": true, "hiddenName": "upload_areaHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Area","(uploads.UploadTypes.upload_area) ") }, "name": "upload_area", "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var wanted769 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Wanted", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Wanted","(uploads.UploadTypes.wanted) Add a (+) button when there is no upload of this type.") }, "name": "wanted", "selectOnFocus": true });
    var max_number770 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Max. number</span>", "listeners": { "render": Lino.quicktip_renderer("Max. number","(uploads.UploadTypes.max_number) No need to upload more uploads than N of this type.\n-1 means no limit.") }, "name": "max_number", "selectOnFocus": true, "value": -1 });
    var shortcut771 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Upload shortcut</span>", "listeners": { "render": Lino.quicktip_renderer("Upload shortcut","(uploads.UploadTypes.shortcut) Optional pointer to a virtual upload shortcut field.  If\nthis is not empty, then the given shortcut field will manage\nuploads of this type.  See also Shortcuts.") }, "maxLength": 50, "name": "shortcut", "selectOnFocus": true });
    var main_1_panel772 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 9, "items": id767, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": upload_area768, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": wanted769, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": max_number770, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 41, "items": shortcut771, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name778 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(uploads.UploadTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et779 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(uploads.UploadTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel780 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name778, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et779, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var uploads_UploadsByType_grid823 = new Lino.uploads.UploadsByType.GridPanel({ "containing_panel": this, "flex": 71, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Uploads","(uploads.uploads.UploadsByType) Shows all Uploads") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.uploads.UploadsByType.grid) ] });
    var main_panel824 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel772, main_2_panel780, uploads_UploadsByType_grid823 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel824;
    this.before_row_edit = function(record) {
      uploads_UploadsByType_grid823.on_master_changed();
    }
    Lino.uploads.UploadTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.meetings.Meetings.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 68,
  initComponent : function() {
    var name825 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(meetings.Meetings.name) ") }, "maxLength": 100, "name": "name", "selectOnFocus": true });
    var start_date826 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(meetings.Meetings.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var main_1_panel827 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": name825, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": start_date826, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var list830 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "fieldLabel": "Memebers", "hiddenName": "listHidden", "listeners": { "render": Lino.quicktip_renderer("Memebers","(meetings.Meetings.list) ") }, "name": "list", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.lists.Lists.detail,Lino.lists.Lists.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/list" }) }) });
    var main_panel831 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel827, { "anchor": "-20", "autoHeight": true, "items": list830, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel831;
    this.before_row_edit = function(record) {
    }
    Lino.meetings.Meetings.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Tickets.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 43,
  initComponent : function() {
    var summary833 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Summary</span>", "listeners": { "render": Lino.quicktip_renderer("Summary","(tickets.Tickets.summary) Short summary of the problem.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var id834 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tickets.Tickets.id) ") }, "name": "id", "selectOnFocus": true });
    var general1_1_panel835 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 86, "items": summary833, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": id834, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user838 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(tickets.Tickets.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/user" }) }) });
    var end_user839 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "End user", "hiddenName": "end_userHidden", "listeners": { "render": Lino.quicktip_renderer("End user","(tickets.Tickets.end_user) ") }, "name": "end_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/end_user" }) }) });
    var deadline840 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Deadline", "listeners": { "render": Lino.quicktip_renderer("Deadline","(tickets.Tickets.deadline) ") }, "name": "deadline", "selectOnFocus": true });
    var general1_2_panel841 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 32, "items": user838, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": end_user839, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 35, "items": deadline840, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var site845 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "siteHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(tickets.Tickets.site) ") }, "name": "site", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/site" }) }) });
    var topic846 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(tickets.Tickets.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.topics.Topics.detail,Lino.topics.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/topic" }) }) });
    var project847 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Eesm\u00e4rk", "hiddenName": "projectHidden", "listeners": { "render": Lino.quicktip_renderer("Mission","(tickets.Tickets.project) ") }, "name": "project", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Projects.detail,Lino.tickets.Projects.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/project" }) }) });
    var general1_3_panel848 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": site845, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": topic846, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": project847, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var workflow_buttons_disp852 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(tickets.Tickets.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var private853 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Private", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Private","(tickets.Tickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.") }, "name": "private", "selectOnFocus": true });
    var general1_4_panel854 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 75, "items": workflow_buttons_disp852, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": private853, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var faculties_DemandsByDemander_htmlbox857 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 50, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Wanted skills","(tickets.Tickets.faculties_DemandsByDemander) ") }, "master_panel": this, "name": "faculties_DemandsByDemander", "title": "Wanted skills", "tools": [ Lino.show_in_own_window_button(Lino.faculties.DemandsByDemander.grid) ], "value": "<br/>" });
    var bottom_box_1_panel859 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 3, "frame": false, "hideCheckBoxLabels": true, "items": [ faculties_DemandsByDemander_htmlbox857 ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretch" }, "region": "north", "split": true });
    var deploy_DeploymentsByTicket_htmlbox860 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 50, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Wishes","(tickets.Tickets.deploy_DeploymentsByTicket) ") }, "master_panel": this, "name": "deploy_DeploymentsByTicket", "title": "Wishes", "tools": [ Lino.show_in_own_window_button(Lino.deploy.DeploymentsByTicket.grid) ], "value": "<br/>" });
    var clocking_SessionsByTicket_htmlbox861 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 50, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Sessions","(tickets.Tickets.clocking_SessionsByTicket) The \"Sessions\" panel in the detail of a ticket.") }, "master_panel": this, "name": "clocking_SessionsByTicket", "title": "Istungid", "tools": [ Lino.show_in_own_window_button(Lino.clocking.SessionsByTicket.grid) ], "value": "<br/>" });
    var bottom_box_2_panel862 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 3, "frame": false, "hideCheckBoxLabels": true, "items": [ deploy_DeploymentsByTicket_htmlbox860, clocking_SessionsByTicket_htmlbox861 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" }, "region": "center", "split": true });
    var bottom_box_panel863 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "flex": 50, "frame": true, "hideCheckBoxLabels": true, "items": [ bottom_box_1_panel859, bottom_box_2_panel862 ], "labelAlign": "top" });
    var general1_panel864 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "flex": 66, "frame": true, "hideCheckBoxLabels": true, "items": [ general1_1_panel835, general1_2_panel841, general1_3_panel848, general1_4_panel854, bottom_box_panel863 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    var comments_CommentsByRFC_htmlbox865 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 33, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Comments","(tickets.Tickets.comments_CommentsByRFC) ") }, "master_panel": this, "name": "comments_CommentsByRFC", "title": "Comments", "tools": [ Lino.show_in_own_window_button(Lino.comments.CommentsByRFC.grid) ], "value": "<br/>" });
    var general_1_panel866 = new Ext.Panel({ "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ general1_panel864, comments_CommentsByRFC_htmlbox865 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var created867 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Loodud</span>", "listeners": { "render": Lino.quicktip_renderer("Created","(tickets.Tickets.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified868 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Modified","(tickets.Tickets.modified) ") }, "name": "modified", "value": "<br>" });
    var reported_for869 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reported for</span>", "hiddenName": "reported_forHidden", "listeners": { "render": Lino.quicktip_renderer("Reported for","(tickets.Tickets.reported_for) Milestone for which this ticket has been reported.") }, "name": "reported_for", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/reported_for" }) }) });
    var ticket_type870 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipikuliik...", "fieldLabel": "Lipikuliik", "hiddenName": "ticket_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket type","(tickets.Tickets.ticket_type) ") }, "name": "ticket_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.TicketTypes.detail,Lino.tickets.TicketTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/ticket_type" }) }) });
    var more1_1_panel871 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": created867, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": modified868, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": reported_for869, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": ticket_type870, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var state876 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(tickets.Tickets.state) ") }, "name": "state", "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var ref877 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(tickets.Tickets.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var duplicate_of878 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Duplicate of", "hiddenName": "duplicate_ofHidden", "listeners": { "render": Lino.quicktip_renderer("Duplicate of","(tickets.Tickets.duplicate_of) ") }, "name": "duplicate_of", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/duplicate_of" }) }) });
    var planned_time879 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Planned time</span>", "listeners": { "render": Lino.quicktip_renderer("Planned time","(tickets.Tickets.planned_time) The time (in hours) we plan to work on this project or ticket.") }, "name": "planned_time", "selectOnFocus": true });
    var priority880 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Priority", "listeners": { "render": Lino.quicktip_renderer("Priority","(tickets.Tickets.priority) ") }, "name": "priority", "selectOnFocus": true, "value": 100 });
    var more1_2_panel881 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": state876, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": ref877, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": duplicate_of878, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": planned_time879, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": priority880, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var more1_panel887 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 76, "frame": true, "hideCheckBoxLabels": true, "items": [ more1_1_panel871, more1_2_panel881 ], "labelAlign": "top", "layout": "form" });
    var DuplicatesByTicket_grid1026 = new Lino.tickets.DuplicatesByTicket.GridPanel({ "containing_panel": this, "flex": 23, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Duplicates","(tickets.tickets.DuplicatesByTicket) Shows the tickets which are marked as duplicates of this\n(i.e. whose duplicate_of field points to this ticket.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.DuplicatesByTicket.grid) ] });
    var more_1_panel1027 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ more1_panel887, DuplicatesByTicket_grid1026 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1028 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 42, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes1029 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "Resolution", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Resolution","(tickets.Tickets.upgrade_notes) ") }, "name": "upgrade_notes", "selectOnFocus": true });
    var tickets_LinksByTicket_htmlbox1030 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 28, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Dependencies","(tickets.Tickets.tickets_LinksByTicket) ") }, "master_panel": this, "name": "tickets_LinksByTicket", "title": "Dependencies", "tools": [ Lino.show_in_own_window_button(Lino.tickets.LinksByTicket.grid) ], "value": "<br/>" });
    var more_2_panel1031 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description1028, { "flex": 28, "items": upgrade_notes1029, "labelAlign": "top", "layout": "form", "xtype": "panel" }, tickets_LinksByTicket_htmlbox1030 ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var more_panel1033 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel1027, more_2_panel1031 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var changes_ChangesByMaster_grid1034 = new Lino.changes.ChangesByMaster.GridPanel({ "containing_panel": this, "hide_top_toolbar": true, "listeners": { "activate": Lino.on_tab_activate }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "title": "History", "tools": [ Lino.show_in_own_window_button(Lino.changes.ChangesByMaster.grid) ] });
    var uploads_UploadsByController_htmlbox1035 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "activate": Lino.on_tab_activate }, "master_panel": this, "name": "uploads_UploadsByController", "title": "Even more", "tools": [ Lino.show_in_own_window_button(Lino.uploads.UploadsByController.grid) ], "value": "<br/>" });
    var main_panel1036 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel866, more_panel1033, changes_ChangesByMaster_grid1034, uploads_UploadsByController_htmlbox1035 ], "labelAlign": "top", "split": true });
    this.items = main_panel1036;
    this.before_row_edit = function(record) {
      faculties_DemandsByDemander_htmlbox857.refresh();
      deploy_DeploymentsByTicket_htmlbox860.refresh();
      clocking_SessionsByTicket_htmlbox861.refresh();
      comments_CommentsByRFC_htmlbox865.refresh();
      reported_for869.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      DuplicatesByTicket_grid1026.on_master_changed();
      description1028.refresh();
      tickets_LinksByTicket_htmlbox1030.refresh();
      changes_ChangesByMaster_grid1034.on_master_changed();
      uploads_UploadsByController_htmlbox1035.refresh();
    }
    this.onRender = function(ct, position) {
      site845.on('change',Lino.chooser_handler(reported_for869,'site'));
      Lino.tickets.Tickets.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.tickets.Tickets.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Demands.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 46,
  initComponent : function() {
    var demander1037 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Demander", "hiddenName": "demanderHidden", "listeners": { "render": Lino.quicktip_renderer("Demander","(faculties.Demands.demander) ") }, "name": "demander", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Demands/demander" }) }) });
    var skill1038 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(faculties.Demands.skill) ") }, "name": "skill", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Demands/skill" }) }) });
    var importance1039 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Importance</span>", "listeners": { "render": Lino.quicktip_renderer("Importance","(faculties.Demands.importance) How important this skill is for this demand. A number between -100 and +100.") }, "name": "importance", "selectOnFocus": true, "value": 100 });
    var id1040 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(faculties.Demands.id) ") }, "name": "id", "selectOnFocus": true });
    var main_3_panel1041 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": importance1039, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": id1040, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1044 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": demander1037, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": skill1038, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel1041 ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel1044;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.Demands.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.outbox.Mails.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 63,
  initComponent : function() {
    var subject1047 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Teema", "listeners": { "render": Lino.quicktip_renderer("Subject","(outbox.Mails.subject) ") }, "maxLength": 200, "name": "subject", "selectOnFocus": true });
    var body1048 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Body", "flex": 83, "name": "body", "selectOnFocus": true, "title": "Body" });
    var main_panel1049 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "items": subject1047, "labelAlign": "top", "layout": "form", "xtype": "panel" }, body1048 ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1049;
    this.before_row_edit = function(record) {
      body1048.refresh();
    }
    Lino.outbox.Mails.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 29,
  initComponent : function() {
    var line1051 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "fieldLabel": "Tegevuste sari", "hiddenName": "lineHidden", "listeners": { "render": Lino.quicktip_renderer("Activity line","(courses.Activities.line) ") }, "name": "line", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Lines.detail,Lino.courses.Lines.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/line" }) }) });
    var teacher1052 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "\u00dcrituse juht", "hiddenName": "teacherHidden", "listeners": { "render": Lino.quicktip_renderer("Instructor","(courses.Activities.teacher) ") }, "name": "teacher", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/teacher" }) }) });
    var start_date1053 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(courses.Activities.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date1054 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "End Date", "listeners": { "render": Lino.quicktip_renderer("End Date","(courses.Activities.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var start_time1055 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Start time", "listeners": { "render": Lino.quicktip_renderer("Start time","(courses.Activities.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var end_time1056 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("End Time","(courses.Activities.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var general_1_panel1057 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 24, "items": line1051, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": teacher1052, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": start_date1053, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": end_date1054, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": start_time1055, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": end_time1056, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var room1064 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(courses.Activities.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/room" }) }) });
    var workflow_buttons_disp1065 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(courses.Activities.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var id1066 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Activities.id) ") }, "name": "id", "selectOnFocus": true });
    var user1067 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.Activities.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/user" }) }) });
    var general_2_panel1068 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": room1064, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": workflow_buttons_disp1065, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": id1066, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": user1067, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name1073 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(courses.Activities.name) ") }, "maxLength": 100, "name": "name", "selectOnFocus": true });
    var description1074 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et1075 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var general_4_panel1076 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description1074, description_et1075 ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var general_panel1077 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel1057, general_2_panel1068, { "autoHeight": true, "items": name1073, "labelAlign": "top", "layout": "form", "xtype": "panel" }, general_4_panel1076 ], "labelAlign": "top", "labelWidth": 108, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var max_events1079 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "S\u00fcndmuste arv", "listeners": { "render": Lino.quicktip_renderer("Number of events","(courses.Activities.max_events) ") }, "name": "max_events", "selectOnFocus": true });
    var max_date1080 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Genereeri s\u00fcndmusi kuni", "listeners": { "render": Lino.quicktip_renderer("Generate events until","(courses.Activities.max_date) ") }, "name": "max_date", "selectOnFocus": true });
    var every_unit1081 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Korduvus", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Recurrency","(courses.Activities.every_unit) ") }, "name": "every_unit", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every1082 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Repeat every","(courses.Activities.every) ") }, "name": "every", "selectOnFocus": true });
    var cal_tab_1_panel1083 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 11, "items": max_events1079, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 29, "items": max_date1080, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 47, "items": every_unit1081, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": every1082, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 198, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var monday1088 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "esmasp\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Monday","(courses.Activities.monday) ") }, "name": "monday", "selectOnFocus": true });
    var tuesday1089 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "teisip\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Tuesday","(courses.Activities.tuesday) ") }, "name": "tuesday", "selectOnFocus": true });
    var wednesday1090 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "kolmap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Wednesday","(courses.Activities.wednesday) ") }, "name": "wednesday", "selectOnFocus": true });
    var thursday1091 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "neljap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Thursday","(courses.Activities.thursday) ") }, "name": "thursday", "selectOnFocus": true });
    var friday1092 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "reede", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Friday","(courses.Activities.friday) ") }, "name": "friday", "selectOnFocus": true });
    var saturday1093 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "laup\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Saturday","(courses.Activities.saturday) ") }, "name": "saturday", "selectOnFocus": true });
    var sunday1094 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "p\u00fchap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Sunday","(courses.Activities.sunday) ") }, "name": "sunday", "selectOnFocus": true });
    var cal_tab_2_panel1095 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 14, "items": monday1088, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": tuesday1089, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": wednesday1090, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": thursday1091, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": friday1092, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": saturday1093, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": sunday1094, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var cal_EntriesByController_htmlbox1103 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 60, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("events","(courses.Activities.cal_EntriesByController) Shows the events linked to this database object.") }, "master_panel": this, "name": "cal_EntriesByController", "title": "events", "tools": [ Lino.show_in_own_window_button(Lino.cal.EntriesByController.grid) ], "value": "<br/>" });
    var cal_tab_panel1104 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ cal_tab_1_panel1083, cal_tab_2_panel1095, cal_EntriesByController_htmlbox1103 ], "labelAlign": "top", "labelWidth": 63, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Kalender" });
    var enrolments_until1105 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Enrolments until", "listeners": { "render": Lino.quicktip_renderer("Enrolments until","(courses.Activities.enrolments_until) ") }, "name": "enrolments_until", "selectOnFocus": true });
    var max_places1106 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Available places</span>", "listeners": { "render": Lino.quicktip_renderer("Available places","(courses.Activities.max_places) Maximum number of participants") }, "name": "max_places", "selectOnFocus": true });
    var confirmed1107 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Kinnitatud", "listeners": { "render": Lino.quicktip_renderer("Confirmed","(courses.Activities.confirmed) ") }, "name": "confirmed" });
    var free_places1108 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Free places", "listeners": { "render": Lino.quicktip_renderer("Free places","(courses.Activities.free_places) ") }, "name": "free_places" });
    var print_actions_disp1109 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Tr\u00fcki", "listeners": { "render": Lino.quicktip_renderer("Print","(courses.Activities.print_actions) ") }, "name": "print_actions", "value": "<br/>" });
    var enrolments_top_panel1110 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 24, "items": enrolments_until1105, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": max_places1106, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": confirmed1107, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": free_places1108, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": print_actions_disp1109, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var EnrolmentsByCourse_htmlbox1116 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 50, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Enrolments","(courses.Activities.EnrolmentsByCourse) Base class for all enrolment tables.") }, "ls_bbar_actions": [ { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" } ], "ls_insert_handler": Lino.courses.EnrolmentsByCourse.insert, "master_panel": this, "name": "EnrolmentsByCourse", "title": "Osav\u00f5tud", "tools": [ Lino.show_in_own_window_button(Lino.courses.EnrolmentsByCourse.grid) ], "value": "<br/>" });
    var enrolments_panel1117 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ enrolments_top_panel1110, EnrolmentsByCourse_htmlbox1116 ], "labelAlign": "top", "labelWidth": 99, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Osav\u00f5tud" });
    var main_panel1118 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel1077, cal_tab_panel1104, enrolments_panel1117 ], "labelAlign": "top", "split": true });
    this.items = main_panel1118;
    this.before_row_edit = function(record) {
      description1074.refresh();
      description_et1075.refresh();
      cal_EntriesByController_htmlbox1103.refresh();
      EnrolmentsByCourse_htmlbox1116.refresh();
    }
    Lino.courses.Activities.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.topics.Topics.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 31,
  initComponent : function() {
    var id733 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(topics.Topics.id) ") }, "name": "id", "selectOnFocus": true });
    var ref734 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(topics.Topics.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var name735 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(topics.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et736 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(topics.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var topic_group737 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Topic group...", "fieldLabel": "Topic group", "hiddenName": "topic_groupHidden", "listeners": { "render": Lino.quicktip_renderer("Topic group","(topics.Topics.topic_group) ") }, "name": "topic_group", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.topics.TopicGroups.detail,Lino.topics.TopicGroups.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/Topics/topic_group" }) }) });
    var main_1_panel738 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 5, "items": id733, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": ref734, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": name735, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": name_et736, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": topic_group737, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var description744 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Long description", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Long description" });
    var description_et745 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Long description (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Long description (et)" });
    var main_2_panel746 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 5, "frame": false, "hideCheckBoxLabels": true, "items": [ description744, description_et745 ], "labelAlign": "top", "labelWidth": 198, "layout": "hbox", "layoutConfig": { "align": "stretch" }, "region": "center", "split": true });
    var topics_InterestsByTopic_grid755 = new Lino.topics.InterestsByTopic.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Interests","(topics.topics.InterestsByTopic) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "south", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.topics.InterestsByTopic.grid) ] });
    var main_panel756 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel738, main_2_panel746, topics_InterestsByTopic_grid755 ], "labelAlign": "top" });
    this.items = main_panel756;
    this.before_row_edit = function(record) {
      description744.refresh();
      description_et745.refresh();
      topics_InterestsByTopic_grid755.on_master_changed();
    }
    Lino.topics.Topics.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.RecurrentEvents.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 14,
  initComponent : function() {
    var name1119 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimetus</span>", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.RecurrentEvents.name) See lino.utils.mldbc.mixins.BabelNamed.name.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1120 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.RecurrentEvents.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1121 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1119, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1120, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id1124 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.RecurrentEvents.id) ") }, "name": "id", "selectOnFocus": true });
    var user1125 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(cal.RecurrentEvents.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/RecurrentEvents/user" }) }) });
    var event_type1126 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "S\u00fcndmuseliik", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(cal.RecurrentEvents.event_type) ") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/RecurrentEvents/event_type" }) }) });
    var main_2_panel1127 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 11, "items": id1124, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": user1125, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": event_type1126, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date1131 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(cal.RecurrentEvents.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var start_time1132 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Start time", "listeners": { "render": Lino.quicktip_renderer("Start time","(cal.RecurrentEvents.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var end_date1133 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "End Date", "listeners": { "render": Lino.quicktip_renderer("End Date","(cal.RecurrentEvents.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var end_time1134 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("End Time","(cal.RecurrentEvents.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var main_3_panel1135 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": start_date1131, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_time1132, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": end_date1133, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_time1134, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var every_unit1140 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Korduvus</span>", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Recurrency","(cal.RecurrentEvents.every_unit) Inherited from RecurrentSet.every_unit.") }, "name": "every_unit", "selectOnFocus": true, "store": Lino.cal.Recurrencies });
    var every1141 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Repeat every","(cal.RecurrentEvents.every) ") }, "name": "every", "selectOnFocus": true, "value": 1 });
    var max_events1142 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "S\u00fcndmuste arv", "listeners": { "render": Lino.quicktip_renderer("Number of events","(cal.RecurrentEvents.max_events) ") }, "name": "max_events", "selectOnFocus": true });
    var main_4_panel1143 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 67, "items": every_unit1140, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": every1141, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": max_events1142, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var monday1147 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "esmasp\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Monday","(cal.RecurrentEvents.monday) ") }, "name": "monday", "selectOnFocus": true });
    var tuesday1148 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "teisip\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Tuesday","(cal.RecurrentEvents.tuesday) ") }, "name": "tuesday", "selectOnFocus": true });
    var wednesday1149 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "kolmap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Wednesday","(cal.RecurrentEvents.wednesday) ") }, "name": "wednesday", "selectOnFocus": true });
    var thursday1150 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "neljap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Thursday","(cal.RecurrentEvents.thursday) ") }, "name": "thursday", "selectOnFocus": true });
    var friday1151 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "reede", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Friday","(cal.RecurrentEvents.friday) ") }, "name": "friday", "selectOnFocus": true });
    var saturday1152 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "laup\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Saturday","(cal.RecurrentEvents.saturday) ") }, "name": "saturday", "selectOnFocus": true });
    var sunday1153 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "p\u00fchap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Sunday","(cal.RecurrentEvents.sunday) ") }, "name": "sunday", "selectOnFocus": true });
    var main_5_panel1154 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 14, "items": monday1147, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": tuesday1148, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": wednesday1149, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": thursday1150, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": friday1151, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": saturday1152, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": sunday1153, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1162 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 66, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var cal_EntriesByController_htmlbox1163 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 33, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("events","(cal.RecurrentEvents.cal_EntriesByController) Shows the events linked to this database object.") }, "master_panel": this, "name": "cal_EntriesByController", "title": "events", "tools": [ Lino.show_in_own_window_button(Lino.cal.EntriesByController.grid) ], "value": "<br/>" });
    var main_6_panel1164 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description1162, cal_EntriesByController_htmlbox1163 ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel1165 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1121, main_2_panel1127, main_3_panel1135, main_4_panel1143, main_5_panel1154, main_6_panel1164 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1165;
    this.before_row_edit = function(record) {
      description1162.refresh();
      cal_EntriesByController_htmlbox1163.refresh();
    }
    Lino.cal.RecurrentEvents.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Enrolments.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 28,
  initComponent : function() {
    var request_date1166 = new Lino.DateField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Date of request", "listeners": { "render": Lino.quicktip_renderer("Date of request","(courses.Enrolments.request_date) ") }, "name": "request_date", "selectOnFocus": true });
    var user1167 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.Enrolments.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/user" }) }) });
    var main_1_panel1168 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": request_date1166, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 60, "items": user1167, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var course1171 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "courseHidden", "listeners": { "render": Lino.quicktip_renderer("Activity","(courses.Enrolments.course) ") }, "name": "course", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/course" }) }) });
    var pupil1172 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "Inimene", "forceSelection": false, "hiddenName": "pupilHidden", "listeners": { "render": Lino.quicktip_renderer("Person","(courses.Enrolments.pupil) ") }, "name": "pupil", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/pupil" }) }) });
    var main_2_panel1173 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": course1171, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": pupil1172, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remark1176 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(courses.Enrolments.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var main_panel1177 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1168, main_2_panel1173, { "anchor": "-20", "autoHeight": true, "items": remark1176, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "form" });
    this.items = main_panel1177;
    this.before_row_edit = function(record) {
      course1171.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course1171.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil1172.setContextValue('course', record ? record.data['courseHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      request_date1166.on('change',Lino.chooser_handler(course1171,'request_date'));
      course1171.on('change',Lino.chooser_handler(pupil1172,'course'));
      Lino.courses.Enrolments.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.Enrolments.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.Deployments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 50,
  initComponent : function() {
    var milestone1179 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "milestoneHidden", "listeners": { "render": Lino.quicktip_renderer("Activity","(deploy.Deployments.milestone) ") }, "name": "milestone", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/Deployments/milestone" }) }) });
    var wish_type1180 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Wish type", "forceSelection": true, "hiddenName": "wish_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Wish type","(deploy.Deployments.wish_type) ") }, "name": "wish_type", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.deploy.WishTypes) });
    var ticket1181 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket","(deploy.Deployments.ticket) ") }, "name": "ticket", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/Deployments/ticket" }) }) });
    var remark1182 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "M\u00e4rkus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Remark","(deploy.Deployments.remark) ") }, "name": "remark", "selectOnFocus": true });
    var main_panel1183 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "items": milestone1179, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "items": wish_type1180, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "items": ticket1181, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "flex": 62, "items": remark1182, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1183;
    this.before_row_edit = function(record) {
    }
    Lino.deploy.Deployments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.DeploymentsByMilestone.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 50,
  initComponent : function() {
    var ticket1188 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket","(deploy.DeploymentsByMilestone.ticket) ") }, "name": "ticket", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByMilestone/ticket" }) }) });
    var remark1189 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "M\u00e4rkus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Remark","(deploy.DeploymentsByMilestone.remark) ") }, "name": "remark", "selectOnFocus": true });
    var main_panel1190 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "items": ticket1188, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "flex": 83, "items": remark1189, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1190;
    this.before_row_edit = function(record) {
    }
    Lino.deploy.DeploymentsByMilestone.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Partners.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 8,
  initComponent : function() {
    var name1193 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimi</span>", "listeners": { "render": Lino.quicktip_renderer("Name","(contacts.Partners.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var language1194 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(contacts.Partners.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var email1195 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(contacts.Partners.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var main_2_panel1196 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 48, "items": language1194, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 51, "items": email1195, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1199 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name1193, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel1196 ], "labelAlign": "top", "labelWidth": 45, "layout": "form" });
    this.items = main_panel1199;
    this.before_row_edit = function(record) {
    }
    Lino.contacts.Partners.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Companies.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 5,
  initComponent : function() {
    var overview_disp1201 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "flex": 32, "listeners": { "render": Lino.quicktip_renderer(null,"(contacts.Companies.overview) ") }, "name": "overview", "value": "<br/>" });
    var email1202 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(contacts.Companies.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var url1203 = new Lino.URLField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "URL", "listeners": { "render": Lino.quicktip_renderer("URL","(contacts.Companies.url) ") }, "maxLength": 200, "name": "url", "selectOnFocus": true });
    var contact_box_1_panel1204 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 65, "items": email1202, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": url1203, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var gsm1207 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">GSM</span>", "listeners": { "render": Lino.quicktip_renderer("GSM","(contacts.Companies.gsm) The primary mobile phone number.") }, "maxLength": 200, "name": "gsm", "selectOnFocus": true });
    var phone1208 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Phone</span>", "listeners": { "render": Lino.quicktip_renderer("Phone","(contacts.Companies.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.") }, "maxLength": 200, "name": "phone", "selectOnFocus": true });
    var contact_box_2_panel1209 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": gsm1207, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": phone1208, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var contact_box_panel1212 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 67, "frame": true, "hideCheckBoxLabels": true, "items": [ contact_box_1_panel1204, contact_box_2_panel1209 ], "labelAlign": "top", "layout": "form", "title": "Contact" });
    var general_1_panel1213 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ overview_disp1201, contact_box_panel1212 ], "labelAlign": "top", "labelWidth": 0, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var contacts_RolesByCompany_grid1223 = new Lino.contacts.RolesByCompany.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Contact persons","(contacts.contacts.RolesByCompany) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.contacts.RolesByCompany.grid) ] });
    var comments_CommentsByRFC_htmlbox1224 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 50, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Comments","(contacts.Companies.comments_CommentsByRFC) ") }, "master_panel": this, "name": "comments_CommentsByRFC", "title": "Comments", "tools": [ Lino.show_in_own_window_button(Lino.comments.CommentsByRFC.grid) ], "value": "<br/>" });
    var general_2_panel1225 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ contacts_RolesByCompany_grid1223, comments_CommentsByRFC_htmlbox1224 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var general_panel1226 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel1213, general_2_panel1225 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var prefix1227 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Name prefix", "listeners": { "render": Lino.quicktip_renderer("Name prefix","(contacts.Companies.prefix) ") }, "maxLength": 200, "name": "prefix", "selectOnFocus": true });
    var name1228 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimi</span>", "listeners": { "render": Lino.quicktip_renderer("Name","(contacts.Companies.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var type1229 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsiooniliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organisatsiooniliik</span>", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Organization type","(contacts.Companies.type) Pointer to the CompanyType.") }, "name": "type", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/type" }) }) });
    var name_box_panel1230 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": prefix1227, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": name1228, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 49, "items": type1229, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var country1234 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Country","(contacts.Companies.country) ") }, "name": "country", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Countries.detail,Lino.countries.Countries.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/country" }) }) });
    var city1235 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Linn</span>", "forceSelection": false, "hiddenName": "cityHidden", "listeners": { "render": Lino.quicktip_renderer("City","(contacts.Companies.city) A pointer to Place.") }, "name": "city", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/city" }) }) });
    var zip_code1236 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "Zip code", "listeners": { "render": Lino.quicktip_renderer("Zip code","(contacts.Companies.zip_code) ") }, "maxLength": 10, "name": "zip_code", "selectOnFocus": true });
    var address_box_2_panel1237 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": country1234, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": city1235, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code1236, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street1241 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">T\u00e4nav</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(contacts.Companies.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no1242 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nr.</span>", "listeners": { "render": Lino.quicktip_renderer("No.","(contacts.Companies.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box1243 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Box</span>", "listeners": { "render": Lino.quicktip_renderer("Box","(contacts.Companies.street_box) Text to print after street nuber on the same line.") }, "maxLength": 10, "name": "street_box", "selectOnFocus": true });
    var address_box_4_panel1244 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": street1241, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_no1242, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_box1243, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_box_panel1248 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ name_box_panel1230, address_box_2_panel1237, address_box_4_panel1244 ], "labelAlign": "top", "layout": "form", "title": "Aadres" });
    var remarks1249 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 62, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var contact_panel1250 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ address_box_panel1248, remarks1249 ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Contact" });
    var faculties_OffersByEndUser_grid1251 = new Lino.faculties.OffersByEndUser.GridPanel({ "containing_panel": this, "hide_top_toolbar": true, "listeners": { "activate": Lino.on_tab_activate }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "title": "Oskuse pakkumised", "tools": [ Lino.show_in_own_window_button(Lino.faculties.OffersByEndUser.grid) ] });
    var id1252 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(contacts.Companies.id) ") }, "name": "id", "selectOnFocus": true });
    var language1253 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(contacts.Companies.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var parent1254 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "Parent", "hiddenName": "parentHidden", "listeners": { "render": Lino.quicktip_renderer("Parent","(contacts.Companies.parent) ") }, "name": "parent", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/parent" }) }) });
    var more_1_panel1255 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 14, "items": id1252, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": language1253, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 57, "items": parent1254, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var CompaniesByCompany_grid1356 = new Lino.contacts.CompaniesByCompany.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Organizations","(contacts.contacts.CompaniesByCompany) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.contacts.CompaniesByCompany.grid) ] });
    var more_panel1357 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel1255, CompaniesByCompany_grid1356 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel1358 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel1226, contact_panel1250, faculties_OffersByEndUser_grid1251, more_panel1357 ], "labelAlign": "top", "split": true });
    this.items = main_panel1358;
    this.before_row_edit = function(record) {
      contacts_RolesByCompany_grid1223.on_master_changed();
      comments_CommentsByRFC_htmlbox1224.refresh();
      city1235.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1235.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      remarks1249.refresh();
      faculties_OffersByEndUser_grid1251.on_master_changed();
      CompaniesByCompany_grid1356.on_master_changed();
    }
    this.onRender = function(ct, position) {
      country1234.on('change',Lino.chooser_handler(city1235,'country'));
      Lino.contacts.Companies.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.contacts.Companies.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city1235.on("change", function(){ this.save() }, this);
    zip_code1236.on("change", function(){ this.save() }, this);
  }
});


Lino.tickets.Projects.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 41,
  initComponent : function() {
    var ref1359 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(tickets.Projects.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var name1360 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Name","(tickets.Projects.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var general_1_panel1361 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": ref1359, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name1360, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1364 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 83, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var general_panel1365 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel1361, description1364 ], "labelAlign": "top", "labelWidth": 108, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var TicketsByProject_grid1400 = new Lino.tickets.TicketsByProject.GridPanel({ "containing_panel": this, "hide_top_toolbar": true, "listeners": { "activate": Lino.on_tab_activate }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "title": "Lipikud", "tools": [ Lino.show_in_own_window_button(Lino.tickets.TicketsByProject.grid) ] });
    var parent1401 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Parent", "hiddenName": "parentHidden", "listeners": { "render": Lino.quicktip_renderer("Parent","(tickets.Projects.parent) ") }, "name": "parent", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Projects.detail,Lino.tickets.Projects.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/parent" }) }) });
    var type1402 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Project Type...", "fieldLabel": "Project Type", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Project Type","(tickets.Projects.type) ") }, "name": "type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.ProjectTypes.detail,Lino.tickets.ProjectTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/type" }) }) });
    var reporting_type1403 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Reporting type", "forceSelection": true, "hiddenName": "reporting_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Reporting type","(tickets.Projects.reporting_type) ") }, "name": "reporting_type", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var more_1_panel1404 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": parent1401, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": type1402, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": reporting_type1403, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company1408 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organisatsioon</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organization","(tickets.Projects.company) Pointer to lino_xl.lib.contacts.models.Company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/company" }) }) });
    var assign_to1409 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Assign tickets to</span>", "hiddenName": "assign_toHidden", "listeners": { "render": Lino.quicktip_renderer("Assign tickets to","(tickets.Projects.assign_to) The user to whom new tickets will be assigned.") }, "name": "assign_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/assign_to" }) }) });
    var private1410 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Private", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Private","(tickets.Projects.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.") }, "name": "private", "selectOnFocus": true });
    var closed1411 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "L\u00f5petatud", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Closed","(tickets.Projects.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.") }, "name": "closed", "selectOnFocus": true });
    var more_2_panel1412 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": company1408, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": assign_to1409, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": private1410, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": closed1411, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date1417 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(tickets.Projects.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date1418 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("End date","(tickets.Projects.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var srcref_url_template1419 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "srcref url template", "listeners": { "render": Lino.quicktip_renderer("srcref url template","(tickets.Projects.srcref_url_template) ") }, "maxLength": 200, "name": "srcref_url_template", "selectOnFocus": true });
    var changeset_url_template1420 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "changeset url template", "listeners": { "render": Lino.quicktip_renderer("changeset url template","(tickets.Projects.changeset_url_template) ") }, "maxLength": 200, "name": "changeset_url_template", "selectOnFocus": true });
    var more_3_panel1421 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": start_date1417, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date1418, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": srcref_url_template1419, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": changeset_url_template1420, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 207, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var ProjectsByParent_grid1487 = new Lino.tickets.ProjectsByParent.GridPanel({ "containing_panel": this, "flex": 62, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Subprojects","(tickets.tickets.ProjectsByParent) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.ProjectsByParent.grid) ] });
    var more_panel1488 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel1404, more_2_panel1412, more_3_panel1421, ProjectsByParent_grid1487 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel1489 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel1365, TicketsByProject_grid1400, more_panel1488 ], "labelAlign": "top", "split": true });
    this.items = main_panel1489;
    this.before_row_edit = function(record) {
      description1364.refresh();
      TicketsByProject_grid1400.on_master_changed();
      ProjectsByParent_grid1487.on_master_changed();
    }
    Lino.tickets.Projects.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Guests.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 18,
  initComponent : function() {
    var event1490 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni event...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">event</span>", "hiddenName": "eventHidden", "listeners": { "render": Lino.quicktip_renderer("event","(cal.Guests.event) The calendar event to which this presence applies.") }, "name": "event", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.OneEvent.detail,Lino.cal.OneEvent.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/event" }) }) });
    var partner1491 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Partner</span>", "hiddenName": "partnerHidden", "listeners": { "render": Lino.quicktip_renderer("Partner","(cal.Guests.partner) The partner to which this presence applies.") }, "name": "partner", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/partner" }) }) });
    var role1492 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Guest Role...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Role</span>", "hiddenName": "roleHidden", "listeners": { "render": Lino.quicktip_renderer("Role","(cal.Guests.role) The role of this partner in this presence.") }, "name": "role", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.GuestRoles.detail,Lino.cal.GuestRoles.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/role" }) }) });
    var main_1_panel1493 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": event1490, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": partner1491, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": role1492, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var state1497 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(cal.Guests.state) The state of this presence.") }, "name": "state", "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var remark1498 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(cal.Guests.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var workflow_buttons_disp1499 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(cal.Guests.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var main_2_panel1500 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": state1497, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": remark1498, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 49, "items": workflow_buttons_disp1499, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1504 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1493, main_2_panel1500 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1504;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Guests.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.GuestRoles.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 20,
  initComponent : function() {
    var id1505 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.GuestRoles.id) ") }, "name": "id", "selectOnFocus": true });
    var name1506 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.GuestRoles.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1507 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.GuestRoles.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1508 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1505, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1506, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1507, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var cal_GuestsByRole_grid1524 = new Lino.cal.GuestsByRole.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Presences","(cal.cal.GuestsByRole) The default table for Guest.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.cal.GuestsByRole.grid) ] });
    var main_panel1525 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1508, cal_GuestsByRole_grid1524 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1525;
    this.before_row_edit = function(record) {
      cal_GuestsByRole_grid1524.on_master_changed();
    }
    Lino.cal.GuestRoles.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.StatusReport.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  disable_editing: true,
  initComponent : function() {
    var body_htmlbox1526 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer(null,"(courses.StatusReport.body) ") }, "name": "body", "value": "<br/>" });
    var main_panel1527 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ body_htmlbox1526 ], "labelAlign": "top", "labelWidth": 0, "layout": "fit" });
    this.items = main_panel1527;
    this.before_row_edit = function(record) {
      body_htmlbox1526.refresh();
    }
    Lino.courses.StatusReport.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.Excerpts.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 37,
  initComponent : function() {
    var id1528 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(excerpts.Excerpts.id) ") }, "name": "id", "selectOnFocus": true });
    var excerpt_type1529 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">V\u00e4ljav\u00f5teliik</span>", "hiddenName": "excerpt_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Excerpt Type","(excerpts.Excerpts.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).") }, "name": "excerpt_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.excerpts.ExcerptTypes.detail,Lino.excerpts.ExcerptTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/excerpt_type" }) }) });
    var main_1_panel1530 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": id1528, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 83, "items": excerpt_type1529, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user1533 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(excerpts.Excerpts.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/user" }) }) });
    var build_method1534 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Build method", "forceSelection": true, "hiddenName": "build_methodHidden", "listeners": { "render": Lino.quicktip_renderer("Build method","(excerpts.Excerpts.build_method) ") }, "name": "build_method", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var main_2_panel1535 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": user1533, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 69, "items": build_method1534, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company1538 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Firma)</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Recipient (Organization)","(excerpts.Excerpts.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/company" }) }) });
    var contact_person1539 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Isik)</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Recipient (Person)","(excerpts.Excerpts.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/contact_person" }) }) });
    var language1540 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(excerpts.Excerpts.language) The language used for printing this excerpt.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var main_3_panel1541 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": company1538, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": contact_person1539, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": language1540, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 225, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var owner_disp1545 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Controlled by</span>", "name": "owner" });
    var build_time1546 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">build time</span>", "listeners": { "render": Lino.quicktip_renderer("build time","(excerpts.Excerpts.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.") }, "name": "build_time", "value": "<br>" });
    var main_4_panel1547 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 38, "items": owner_disp1545, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 61, "items": build_time1546, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1550 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1530, main_2_panel1535, main_3_panel1541, main_4_panel1547 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1550;
    this.before_row_edit = function(record) {
      excerpt_type1529.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person1539.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      owner_disp1545.on('change',Lino.chooser_handler(excerpt_type1529,'owner'));
      company1538.on('change',Lino.chooser_handler(contact_person1539,'company'));
      Lino.excerpts.Excerpts.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.Excerpts.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.gfks.ContentTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 34,
  initComponent : function() {
    var id1551 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(gfks.ContentTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var app_label1552 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "app label", "listeners": { "render": Lino.quicktip_renderer("app label","(gfks.ContentTypes.app_label) ") }, "maxLength": 100, "name": "app_label", "selectOnFocus": true });
    var model1553 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "pythoni mudeli klassinimi", "listeners": { "render": Lino.quicktip_renderer("python model class name","(gfks.ContentTypes.model) ") }, "maxLength": 100, "name": "model", "selectOnFocus": true });
    var base_classes_disp1554 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Base classes", "listeners": { "render": Lino.quicktip_renderer("Base classes","(gfks.ContentTypes.base_classes) ") }, "name": "base_classes", "value": "<br/>" });
    var main_1_panel1555 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 6, "items": id1551, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": app_label1552, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": model1553, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": base_classes_disp1554, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var HelpTextsByModel_grid1566 = new Lino.gfks.HelpTextsByModel.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Help Texts","(gfks.gfks.HelpTextsByModel) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "center", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.gfks.HelpTextsByModel.grid) ] });
    var BrokenGFKsByModel_grid1571 = new Lino.gfks.BrokenGFKsByModel.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Broken GFKs","(gfks.gfks.BrokenGFKsByModel) Shows all database objects (model instances) who have a broken\nGeneriForeignKey field.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "south", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.gfks.BrokenGFKsByModel.grid) ] });
    var main_panel1572 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1555, HelpTextsByModel_grid1566, BrokenGFKsByModel_grid1571 ], "labelAlign": "top" });
    this.items = main_panel1572;
    this.before_row_edit = function(record) {
      HelpTextsByModel_grid1566.on_master_changed();
      BrokenGFKsByModel_grid1571.on_master_changed();
    }
    Lino.gfks.ContentTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Tasks.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 12,
  initComponent : function() {
    var start_date1573 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(cal.Tasks.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var due_date1574 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Due date", "listeners": { "render": Lino.quicktip_renderer("Due date","(cal.Tasks.due_date) ") }, "name": "due_date", "selectOnFocus": true });
    var id1575 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Tasks.id) ") }, "name": "id", "selectOnFocus": true });
    var workflow_buttons_disp1576 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(cal.Tasks.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var main_1_panel1577 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": start_date1573, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": due_date1574, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": id1575, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 49, "items": workflow_buttons_disp1576, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var summary1582 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00fchikirjeldus", "listeners": { "render": Lino.quicktip_renderer("Short description","(cal.Tasks.summary) ") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var user1583 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(cal.Tasks.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Tasks/user" }) }) });
    var owner_disp1584 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var created1585 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Loodud</span>", "listeners": { "render": Lino.quicktip_renderer("Created","(cal.Tasks.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified1586 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Modified","(cal.Tasks.modified) ") }, "name": "modified", "value": "<br>" });
    var main_4_panel1587 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 20, "items": owner_disp1584, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": created1585, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": modified1586, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1591 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "Kirjeldus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Description","(cal.Tasks.description) ") }, "name": "description", "selectOnFocus": true });
    var main_panel1592 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1577, { "autoHeight": true, "items": summary1582, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "items": user1583, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_4_panel1587, { "flex": 45, "items": description1591, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1592;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Tasks.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.DemandsByDemander.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 46,
  initComponent : function() {
    var skill1596 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(faculties.DemandsByDemander.skill) ") }, "name": "skill", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/DemandsByDemander/skill" }) }) });
    var importance1597 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Importance</span>", "listeners": { "render": Lino.quicktip_renderer("Importance","(faculties.DemandsByDemander.importance) How important this skill is for this demand. A number between -100 and +100.") }, "name": "importance", "selectOnFocus": true, "value": 100 });
    var main_panel1598 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": skill1596, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": importance1597, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "form" });
    this.items = main_panel1598;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.DemandsByDemander.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Tasks.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 12,
  initComponent : function() {
    var summary1601 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00fchikirjeldus", "listeners": { "render": Lino.quicktip_renderer("Short description","(cal.Tasks.summary) ") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var user1602 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(cal.Tasks.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Tasks/user" }) }) });
    var main_panel1603 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": summary1601, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user1602, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "form" });
    this.items = main_panel1603;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Tasks.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.RecurrentEvents.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 14,
  initComponent : function() {
    var name1606 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimetus</span>", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.RecurrentEvents.name) See lino.utils.mldbc.mixins.BabelNamed.name.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1607 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.RecurrentEvents.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1608 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1606, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1607, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date1611 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(cal.RecurrentEvents.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date1612 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "End Date", "listeners": { "render": Lino.quicktip_renderer("End Date","(cal.RecurrentEvents.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var every_unit1613 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Korduvus</span>", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Recurrency","(cal.RecurrentEvents.every_unit) Inherited from RecurrentSet.every_unit.") }, "name": "every_unit", "selectOnFocus": true, "store": Lino.cal.Recurrencies });
    var event_type1614 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "S\u00fcndmuseliik", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(cal.RecurrentEvents.event_type) ") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/RecurrentEvents/event_type" }) }) });
    var main_2_panel1615 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": start_date1611, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date1612, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": every_unit1613, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 29, "items": event_type1614, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1620 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1608, main_2_panel1615 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1620;
    this.before_row_edit = function(record) {
    }
    Lino.cal.RecurrentEvents.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.EnrolmentsByCourse.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 28,
  initComponent : function() {
    var pupil1621 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "Inimene", "forceSelection": false, "hiddenName": "pupilHidden", "listeners": { "render": Lino.quicktip_renderer("Person","(courses.EnrolmentsByCourse.pupil) ") }, "name": "pupil", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByCourse/pupil" }) }) });
    var remark1622 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(courses.EnrolmentsByCourse.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var request_date1623 = new Lino.DateField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Date of request", "listeners": { "render": Lino.quicktip_renderer("Date of request","(courses.EnrolmentsByCourse.request_date) ") }, "name": "request_date", "selectOnFocus": true });
    var user1624 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.EnrolmentsByCourse.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByCourse/user" }) }) });
    var main_3_panel1625 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": request_date1623, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 60, "items": user1624, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1628 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": pupil1621, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": remark1622, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel1625 ], "labelAlign": "top", "labelWidth": 63, "layout": "form" });
    this.items = main_panel1628;
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      pupil1621.setContextValue('mk',bp['mk']);
      pupil1621.setContextValue('mt',bp['mt']);
    }
    Lino.courses.EnrolmentsByCourse.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.countries.Countries.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 1,
  initComponent : function() {
    var isocode1631 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(4), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">ISO code</span>", "listeners": { "render": Lino.quicktip_renderer("ISO code","(countries.Countries.isocode)         The two-letter code for this country as defined by ISO 3166-1.\n        For countries that no longer exist it may be a 4-letter code.") }, "maxLength": 4, "name": "isocode", "selectOnFocus": true });
    var short_code1632 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(4), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Short code</span>", "listeners": { "render": Lino.quicktip_renderer("Short code","(countries.Countries.short_code) A short abbreviation for regional usage. Obsolete.") }, "maxLength": 4, "name": "short_code", "selectOnFocus": true });
    var main_1_panel1633 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": isocode1631, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": short_code1632, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name1636 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(countries.Countries.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1637 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(countries.Countries.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel1638 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1636, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1637, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1641 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1633, main_2_panel1638 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1641;
    this.before_row_edit = function(record) {
    }
    Lino.countries.Countries.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.Votes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 33,
  initComponent : function() {
    var user1642 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">S\u00f5nav\u00f5tja</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Voter","(votes.Votes.user) The user who is voting.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/Votes/user" }) }) });
    var votable1643 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Lipik</span>", "hiddenName": "votableHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket","(votes.Votes.votable) The ticket (or other votable) being voted.") }, "name": "votable", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/Votes/votable" }) }) });
    var main_1_panel1644 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": user1642, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": votable1643, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var mail_mode1647 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Email notification mode", "forceSelection": true, "hiddenName": "mail_modeHidden", "listeners": { "render": Lino.quicktip_renderer("Email notification mode","(votes.Votes.mail_mode) ") }, "name": "mail_mode", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.notify.MailModes) });
    var priority1648 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Priority</span>", "listeners": { "render": Lino.quicktip_renderer("Priority","(votes.Votes.priority) My personal priority for this ticket.") }, "name": "priority", "selectOnFocus": true, "value": 0 });
    var nickname1649 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nickname</span>", "listeners": { "render": Lino.quicktip_renderer("Nickname","(votes.Votes.nickname) My nickname for this ticket. Optional.") }, "maxLength": 50, "name": "nickname", "selectOnFocus": true });
    var main_4_panel1650 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": priority1648, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 80, "items": nickname1649, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var state1653 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(votes.Votes.state) The state of this vote.  Pointer to VoteStates.") }, "name": "state", "selectOnFocus": true, "store": Lino.votes.VoteStates });
    var rating1654 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Rating</span>", "forceSelection": true, "hiddenName": "ratingHidden", "listeners": { "render": Lino.quicktip_renderer("Rating","(votes.Votes.rating) How the ticket author rates my help on this ticket.") }, "name": "rating", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.votes.Ratings) });
    var main_panel1655 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1644, { "anchor": "-20", "autoHeight": true, "items": mail_mode1647, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_4_panel1650, { "anchor": "-20", "autoHeight": true, "items": state1653, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": rating1654, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel1655;
    this.before_row_edit = function(record) {
    }
    Lino.votes.Votes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.Uploads.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 62,
  initComponent : function() {
    var file799 = Lino.file_field_handler(this,{ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Fail</span>", "listeners": { "render": Lino.quicktip_renderer("File","(uploads.Uploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file") }, "maxLength": 100, "name": "file", "selectOnFocus": true });
    var user800 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Uploaded by", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Uploaded by","(uploads.Uploads.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/user" }) }) });
    var main_1_panel801 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": file799, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": user800, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var upload_area804 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Upload Area", "forceSelection": true, "hiddenName": "upload_areaHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Area","(uploads.Uploads.upload_area) ") }, "name": "upload_area", "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var type805 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Upload Type...", "fieldLabel": "Upload Type", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Type","(uploads.Uploads.type) ") }, "name": "type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.uploads.UploadTypes.detail,Lino.uploads.UploadTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/type" }) }) });
    var description806 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Description","(uploads.Uploads.description) A short description entered manually by the user.") }, "maxLength": 200, "name": "description", "selectOnFocus": true });
    var main_2_panel807 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": upload_area804, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": type805, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 41, "items": description806, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var owner_disp811 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var main_panel812 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel801, main_2_panel807, { "anchor": "-20", "autoHeight": true, "items": owner_disp811, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "form" });
    this.items = main_panel812;
    this.before_row_edit = function(record) {
      type805.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      upload_area804.on('change',Lino.chooser_handler(type805,'upload_area'));
      Lino.uploads.Uploads.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.uploads.Uploads.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.MyVotes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 33,
  initComponent : function() {
    var user1659 = new Lino.TwinCombo({ "anchor": "-20", "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">S\u00f5nav\u00f5tja</span>", "hidden": true, "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Voter","(votes.MyVotes.user) The user who is voting.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/MyVotes/user" }) }) });
    var workflow_buttons_disp1660 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(votes.MyVotes.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var mail_mode1661 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Email notification mode", "forceSelection": true, "hiddenName": "mail_modeHidden", "listeners": { "render": Lino.quicktip_renderer("Email notification mode","(votes.MyVotes.mail_mode) ") }, "name": "mail_mode", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.notify.MailModes) });
    var priority1662 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Priority</span>", "listeners": { "render": Lino.quicktip_renderer("Priority","(votes.MyVotes.priority) My personal priority for this ticket.") }, "name": "priority", "selectOnFocus": true, "value": 0 });
    var nickname1663 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nickname</span>", "listeners": { "render": Lino.quicktip_renderer("Nickname","(votes.MyVotes.nickname) My nickname for this ticket. Optional.") }, "maxLength": 50, "name": "nickname", "selectOnFocus": true });
    var main_4_panel1664 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": priority1662, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 80, "items": nickname1663, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1667 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ user1659, { "anchor": "-20", "autoHeight": true, "items": workflow_buttons_disp1660, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": mail_mode1661, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_4_panel1664 ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel1667;
    this.before_row_edit = function(record) {
    }
    Lino.votes.MyVotes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.addresses.Addresses.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 24,
  initComponent : function() {
    var country1670 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Country","(addresses.Addresses.country) ") }, "name": "country", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Countries.detail,Lino.countries.Countries.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/country" }) }) });
    var city1671 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Linn</span>", "forceSelection": false, "hiddenName": "cityHidden", "listeners": { "render": Lino.quicktip_renderer("City","(addresses.Addresses.city) A pointer to Place.") }, "name": "city", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/city" }) }) });
    var zip_code1672 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "Zip code", "listeners": { "render": Lino.quicktip_renderer("Zip code","(addresses.Addresses.zip_code) ") }, "maxLength": 10, "name": "zip_code", "selectOnFocus": true });
    var main_1_panel1673 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": country1670, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": city1671, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": zip_code1672, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var addr11677 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Address line before street</span>", "listeners": { "render": Lino.quicktip_renderer("Address line before street","(addresses.Addresses.addr1) Address line before street") }, "maxLength": 200, "name": "addr1", "selectOnFocus": true });
    var street1678 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">T\u00e4nav</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(addresses.Addresses.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no1679 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nr.</span>", "listeners": { "render": Lino.quicktip_renderer("No.","(addresses.Addresses.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box1680 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Box</span>", "listeners": { "render": Lino.quicktip_renderer("Box","(addresses.Addresses.street_box) Text to print after street nuber on the same line.") }, "maxLength": 10, "name": "street_box", "selectOnFocus": true });
    var main_3_panel1681 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 48, "items": street1678, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": street_no1679, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": street_box1680, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var addr21685 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Address line after street</span>", "listeners": { "render": Lino.quicktip_renderer("Address line after street","(addresses.Addresses.addr2) Address line to print below street line.") }, "maxLength": 200, "name": "addr2", "selectOnFocus": true });
    var address_type1686 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Aadressiliik", "forceSelection": true, "hiddenName": "address_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Address type","(addresses.Addresses.address_type) ") }, "name": "address_type", "selectOnFocus": true, "store": Lino.addresses.AddressTypes });
    var remark1687 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(addresses.Addresses.remark) ") }, "maxLength": 50, "name": "remark", "selectOnFocus": true });
    var main_5_panel1688 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": address_type1686, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": remark1687, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var data_source1691 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Data source</span>", "forceSelection": true, "hiddenName": "data_sourceHidden", "listeners": { "render": Lino.quicktip_renderer("Data source","(addresses.Addresses.data_source) Pointer to choicelists.DataSources.") }, "name": "data_source", "store": Lino.addresses.DataSources });
    var partner1692 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "Inimene", "hiddenName": "partnerHidden", "listeners": { "render": Lino.quicktip_renderer("Person","(addresses.Addresses.partner) ") }, "name": "partner", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/partner" }) }) });
    var main_6_panel1693 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 48, "items": data_source1691, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 51, "items": partner1692, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1696 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1673, { "anchor": "-20", "autoHeight": true, "items": addr11677, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel1681, { "anchor": "-20", "autoHeight": true, "items": addr21685, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_5_panel1688, main_6_panel1693 ], "labelAlign": "top", "labelWidth": 243, "layout": "form" });
    this.items = main_panel1696;
    this.before_row_edit = function(record) {
      city1671.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1671.setContextValue('region', record ? record.data['regionHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      country1670.on('change',Lino.chooser_handler(city1671,'country'));
      Lino.addresses.Addresses.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.addresses.Addresses.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city1671.on("change", function(){ this.save() }, this);
    zip_code1672.on("change", function(){ this.save() }, this);
  }
});


Lino.users.Register.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 10,
  initComponent : function() {
    var first_name1699 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("First name","(users.Register.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name1700 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Last name","(users.Register.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var main_1_panel1701 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": first_name1699, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": last_name1700, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var email1704 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(users.Register.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var language1705 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(users.Register.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var main_2_panel1706 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": email1704, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": language1705, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var gsm1709 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">GSM</span>", "listeners": { "render": Lino.quicktip_renderer("GSM","(users.Register.gsm) The primary mobile phone number.") }, "maxLength": 200, "name": "gsm", "selectOnFocus": true });
    var phone1710 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Phone</span>", "listeners": { "render": Lino.quicktip_renderer("Phone","(users.Register.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.") }, "maxLength": 200, "name": "phone", "selectOnFocus": true });
    var main_3_panel1711 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": gsm1709, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": phone1710, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var country1714 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Country","(users.Register.country) ") }, "name": "country", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Countries.detail,Lino.countries.Countries.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/country" }) }) });
    var city1715 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Linn</span>", "forceSelection": false, "hiddenName": "cityHidden", "listeners": { "render": Lino.quicktip_renderer("City","(users.Register.city) A pointer to Place.") }, "name": "city", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/city" }) }) });
    var main_4_panel1716 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": country1714, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": city1715, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street1719 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">T\u00e4nav</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(users.Register.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no1720 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nr.</span>", "listeners": { "render": Lino.quicktip_renderer("No.","(users.Register.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var main_5_panel1721 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 65, "items": street1719, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": street_no1720, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var username1724 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajanimi", "listeners": { "render": Lino.quicktip_renderer("Username","(users.Register.username) ") }, "maxLength": 30, "name": "username", "selectOnFocus": true });
    var main_panel1725 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1701, main_2_panel1706, main_3_panel1711, main_4_panel1716, main_5_panel1721, { "anchor": "-20", "autoHeight": true, "items": username1724, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel1725;
    this.before_row_edit = function(record) {
      city1715.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1715.setContextValue('region', record ? record.data['regionHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      country1714.on('change',Lino.chooser_handler(city1715,'country'));
      Lino.users.Register.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.users.Register.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Enrolments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 28,
  initComponent : function() {
    var request_date1727 = new Lino.DateField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Date of request", "listeners": { "render": Lino.quicktip_renderer("Date of request","(courses.Enrolments.request_date) ") }, "name": "request_date", "selectOnFocus": true });
    var user1728 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.Enrolments.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/user" }) }) });
    var start_date1729 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(courses.Enrolments.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date1730 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("End date","(courses.Enrolments.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var main_1_panel1731 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": request_date1727, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": user1728, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": start_date1729, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": end_date1730, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var course1736 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "courseHidden", "listeners": { "render": Lino.quicktip_renderer("Activity","(courses.Enrolments.course) ") }, "name": "course", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/course" }) }) });
    var pupil1737 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "Inimene", "forceSelection": false, "hiddenName": "pupilHidden", "listeners": { "render": Lino.quicktip_renderer("Person","(courses.Enrolments.pupil) ") }, "name": "pupil", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/pupil" }) }) });
    var main_2_panel1738 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": course1736, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": pupil1737, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remark1741 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(courses.Enrolments.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var workflow_buttons_disp1742 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(courses.Enrolments.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var main_3_panel1743 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 41, "items": remark1741, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 58, "items": workflow_buttons_disp1742, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var confirmation_details1746 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Confirmation details", "flex": 50, "name": "confirmation_details", "selectOnFocus": true, "title": "Confirmation details" });
    var main_panel1747 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1731, main_2_panel1738, main_3_panel1743, confirmation_details1746 ], "labelAlign": "top", "labelWidth": 189, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1747;
    this.before_row_edit = function(record) {
      course1736.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course1736.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil1737.setContextValue('course', record ? record.data['courseHidden'] : undefined);
      confirmation_details1746.refresh();
    }
    this.onRender = function(ct, position) {
      request_date1727.on('change',Lino.chooser_handler(course1736,'request_date'));
      course1736.on('change',Lino.chooser_handler(pupil1737,'course'));
      Lino.courses.Enrolments.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.Enrolments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.lists.Lists.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 56,
  initComponent : function() {
    var ref1748 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(lists.Lists.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var list_type1749 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Listiliik...", "fieldLabel": "Listiliik", "hiddenName": "list_typeHidden", "listeners": { "render": Lino.quicktip_renderer("List Type","(lists.Lists.list_type) ") }, "name": "list_type", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/Lists/list_type" }) }) });
    var main_1_panel1750 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": ref1748, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": list_type1749, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name1753 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(lists.Lists.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1754 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(lists.Lists.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel1755 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1753, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1754, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks1758 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 71, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_panel1759 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1750, main_2_panel1755, remarks1758 ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1759;
    this.before_row_edit = function(record) {
      remarks1758.refresh();
    }
    Lino.lists.Lists.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.Uploads.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 62,
  initComponent : function() {
    var type814 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Upload Type...", "fieldLabel": "Upload Type", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Type","(uploads.Uploads.type) ") }, "name": "type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.uploads.UploadTypes.detail,Lino.uploads.UploadTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/type" }) }) });
    var description815 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Description","(uploads.Uploads.description) A short description entered manually by the user.") }, "maxLength": 200, "name": "description", "selectOnFocus": true });
    var file816 = Lino.file_field_handler(this,{ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Fail</span>", "listeners": { "render": Lino.quicktip_renderer("File","(uploads.Uploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file") }, "maxLength": 100, "name": "file", "selectOnFocus": true });
    var user817 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Uploaded by", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Uploaded by","(uploads.Uploads.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/user" }) }) });
    var main_panel818 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": type814, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": description815, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": file816, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user817, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel818;
    this.before_row_edit = function(record) {
      type814.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    }
    Lino.uploads.Uploads.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.SkillTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 48,
  initComponent : function() {
    var id1760 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(faculties.SkillTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name1761 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(faculties.SkillTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1762 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(faculties.SkillTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1763 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1760, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1761, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1762, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var SkillsByType_grid1869 = new Lino.faculties.SkillsByType.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Skills","(faculties.faculties.SkillsByType) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.faculties.SkillsByType.grid) ] });
    var main_panel1870 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1763, SkillsByType_grid1869 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1870;
    this.before_row_edit = function(record) {
      SkillsByType_grid1869.on_master_changed();
    }
    Lino.faculties.SkillTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.SkillTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 48,
  initComponent : function() {
    var id1871 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(faculties.SkillTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name1872 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(faculties.SkillTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1873 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(faculties.SkillTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel1874 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1872, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1873, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1877 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": id1871, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel1874 ], "labelAlign": "top", "labelWidth": 27, "layout": "form" });
    this.items = main_panel1877;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.SkillTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.topics.Topics.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 31,
  initComponent : function() {
    var topic_group757 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Topic group...", "fieldLabel": "Topic group", "hiddenName": "topic_groupHidden", "listeners": { "render": Lino.quicktip_renderer("Topic group","(topics.Topics.topic_group) ") }, "name": "topic_group", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.topics.TopicGroups.detail,Lino.topics.TopicGroups.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/Topics/topic_group" }) }) });
    var name758 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(topics.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et759 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(topics.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel760 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name758, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et759, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel763 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": topic_group757, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel760 ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel763;
    this.before_row_edit = function(record) {
    }
    Lino.topics.Topics.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Skills.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 49,
  initComponent : function() {
    var name1854 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(faculties.Skills.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1855 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(faculties.Skills.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1856 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1854, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1855, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var parent1859 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Parent skill", "hiddenName": "parentHidden", "listeners": { "render": Lino.quicktip_renderer("Parent skill","(faculties.Skills.parent) ") }, "name": "parent", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Skills/parent" }) }) });
    var main_panel1860 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1856, { "anchor": "-20", "autoHeight": true, "items": parent1859, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "form" });
    this.items = main_panel1860;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.Skills.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Companies.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 5,
  initComponent : function() {
    var name1343 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimi</span>", "listeners": { "render": Lino.quicktip_renderer("Name","(contacts.Companies.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var language1344 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(contacts.Companies.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var email1345 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(contacts.Companies.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var main_2_panel1346 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": language1344, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 66, "items": email1345, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var type1349 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsiooniliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organisatsiooniliik</span>", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Organization type","(contacts.Companies.type) Pointer to the CompanyType.") }, "name": "type", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/type" }) }) });
    var id1350 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(contacts.Companies.id) ") }, "name": "id", "selectOnFocus": true });
    var main_3_panel1351 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 80, "items": type1349, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": id1350, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1354 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name1343, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel1346, main_3_panel1351 ], "labelAlign": "top", "labelWidth": 45, "layout": "form" });
    this.items = main_panel1354;
    this.before_row_edit = function(record) {
    }
    Lino.contacts.Companies.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Events.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 16,
  initComponent : function() {
    var start_date1879 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(cal.Events.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var start_time1880 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Start time", "listeners": { "render": Lino.quicktip_renderer("Start time","(cal.Events.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var end_date1881 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "End Date", "listeners": { "render": Lino.quicktip_renderer("End Date","(cal.Events.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var end_time1882 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00f5peb (aeg)</span>", "listeners": { "render": Lino.quicktip_renderer("End Time","(cal.Events.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.") }, "name": "end_time", "selectOnFocus": true });
    var main_1_panel1883 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": start_date1879, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_time1880, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": end_date1881, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_time1882, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var summary1888 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00fchikirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Short description","(cal.Events.summary) A one-line descriptive text.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var main_panel1889 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1883, { "anchor": "-20", "autoHeight": true, "items": summary1888, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "form" });
    this.items = main_panel1889;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Events.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.countries.Countries.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 1,
  initComponent : function() {
    var isocode1891 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(4), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">ISO code</span>", "listeners": { "render": Lino.quicktip_renderer("ISO code","(countries.Countries.isocode)         The two-letter code for this country as defined by ISO 3166-1.\n        For countries that no longer exist it may be a 4-letter code.") }, "maxLength": 4, "name": "isocode", "selectOnFocus": true });
    var name1892 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(countries.Countries.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1893 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(countries.Countries.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var short_code1894 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(4), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Short code</span>", "listeners": { "render": Lino.quicktip_renderer("Short code","(countries.Countries.short_code) A short abbreviation for regional usage. Obsolete.") }, "maxLength": 4, "name": "short_code", "selectOnFocus": true });
    var main_1_panel1895 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": isocode1891, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": name1892, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": name_et1893, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": short_code1894, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var countries_PlacesByCountry_grid2019 = new Lino.countries.PlacesByCountry.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Places","(countries.countries.PlacesByCountry) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.countries.PlacesByCountry.grid) ] });
    var main_panel2020 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1895, countries_PlacesByCountry_grid2019 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2020;
    this.before_row_edit = function(record) {
      countries_PlacesByCountry_grid2019.on_master_changed();
    }
    Lino.countries.Countries.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.meetings.Meetings.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 68,
  initComponent : function() {
    var room2021 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(meetings.Meetings.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/room" }) }) });
    var workflow_buttons_disp2022 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(meetings.Meetings.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var name2023 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(meetings.Meetings.name) ") }, "maxLength": 100, "name": "name", "selectOnFocus": true });
    var general_1_panel2024 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 28, "items": room2021, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 42, "items": workflow_buttons_disp2022, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 29, "items": name2023, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var deploy_DeploymentsByMilestone_grid2043 = new Lino.deploy.DeploymentsByMilestone.GridPanel({ "containing_panel": this, "flex": 62, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Wishes","(deploy.deploy.DeploymentsByMilestone) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 0, "tools": [ Lino.show_in_own_window_button(Lino.deploy.DeploymentsByMilestone.grid) ] });
    var general_panel2044 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel2024, deploy_DeploymentsByMilestone_grid2043 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var id2045 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(meetings.Meetings.id) ") }, "name": "id", "selectOnFocus": true });
    var user2046 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(meetings.Meetings.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/user" }) }) });
    var list2047 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "fieldLabel": "Memebers", "hiddenName": "listHidden", "listeners": { "render": Lino.quicktip_renderer("Memebers","(meetings.Meetings.list) ") }, "name": "list", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.lists.Lists.detail,Lino.lists.Lists.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/list" }) }) });
    var more_left_panel2048 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 37, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": id2045, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user2046, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": list2047, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    var blogs_EntriesByController_htmlbox2052 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 62, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Blog Entries","(meetings.Meetings.blogs_EntriesByController) ") }, "master_panel": this, "name": "blogs_EntriesByController", "title": "Blog Entries", "tools": [ Lino.show_in_own_window_button(Lino.blogs.EntriesByController.grid) ], "value": "<br/>" });
    var more_1_panel2053 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ more_left_panel2048, blogs_EntriesByController_htmlbox2052 ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2054 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 25, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et2055 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 25, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var MembersByMeeting_grid2067 = new Lino.meetings.MembersByMeeting.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Members","(meetings.meetings.MembersByMeeting) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.meetings.MembersByMeeting.grid) ] });
    var more_2_panel2068 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ description2054, description_et2055, MembersByMeeting_grid2067 ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var more_panel2069 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel2053, more_2_panel2068 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel2070 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel2044, more_panel2069 ], "labelAlign": "top", "split": true });
    this.items = main_panel2070;
    this.before_row_edit = function(record) {
      deploy_DeploymentsByMilestone_grid2043.on_master_changed();
      blogs_EntriesByController_htmlbox2052.refresh();
      description2054.refresh();
      description_et2055.refresh();
      MembersByMeeting_grid2067.on_master_changed();
    }
    Lino.meetings.Meetings.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.ExcerptTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 36,
  initComponent : function() {
    var id2071 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(excerpts.ExcerptTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2072 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimetus</span>", "listeners": { "render": Lino.quicktip_renderer("Designation","(excerpts.ExcerptTypes.name) The designation of this excerpt type.\nOne field for every language.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2073 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(excerpts.ExcerptTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2074 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2071, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2072, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2073, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var content_type2078 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Model</span>", "hiddenName": "content_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Model","(excerpts.ExcerptTypes.content_type) The model that can issue printouts of this type.") }, "name": "content_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.gfks.ContentTypes.detail,Lino.gfks.ContentTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/content_type" }) }) });
    var build_method2079 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Build method</span>", "forceSelection": true, "hiddenName": "build_methodHidden", "listeners": { "render": Lino.quicktip_renderer("Build method","(excerpts.ExcerptTypes.build_method) See lino.modlib.printing.mixins.PrintableType.build_method.") }, "name": "build_method", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var template2080 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Template</span>", "listeners": { "render": Lino.quicktip_renderer("Template","(excerpts.ExcerptTypes.template) The main template to be used when printing an excerpt of this type.") }, "name": "template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/template" }) }) });
    var body_template2081 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Body template</span>", "listeners": { "render": Lino.quicktip_renderer("Body template","(excerpts.ExcerptTypes.body_template) The body template to be used when         rendering a printable of this type. This is a list of files         with extension `.body.html`.") }, "name": "body_template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/body_template" }) }) });
    var email_template2082 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Email template</span>", "listeners": { "render": Lino.quicktip_renderer("Email template","(excerpts.ExcerptTypes.email_template) The name of the file to be used as template when creating an email from a mailable of this type.") }, "name": "email_template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/email_template" }) }) });
    var shortcut2083 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Excerpt shortcut</span>", "listeners": { "render": Lino.quicktip_renderer("Excerpt shortcut","(excerpts.ExcerptTypes.shortcut) Optional pointer to a shortcut field.  If this is not empty, then\nthe given shortcut field will manage excerpts of this type.") }, "maxLength": 50, "name": "shortcut", "selectOnFocus": true });
    var main_2_panel2084 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 15, "items": content_type2078, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": build_method2079, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": template2080, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": body_template2081, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": email_template2082, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": shortcut2083, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var primary2091 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Primary", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Primary","(excerpts.ExcerptTypes.primary) Whether this is the default type to use for this model. There's at most one primary type per model. Enabling this field will automatically make the other types non-primary.") }, "name": "primary", "selectOnFocus": true });
    var print_directly2092 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Print directly", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Print directly","(excerpts.ExcerptTypes.print_directly) ") }, "name": "print_directly", "selectOnFocus": true });
    var certifying2093 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Tsertifitseeriv", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Certifying","(excerpts.ExcerptTypes.certifying) Whether an excerpt of this type is a unique printout.") }, "name": "certifying", "selectOnFocus": true });
    var print_recipient2094 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Print recipient", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Print recipient","(excerpts.ExcerptTypes.print_recipient) Whether to print a recipient field in document.") }, "name": "print_recipient", "selectOnFocus": true });
    var backward_compat2095 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Backward compatible", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Backward compatible","(excerpts.ExcerptTypes.backward_compat) Check this to have `this` in template context point to owner instead of excerpt.") }, "name": "backward_compat", "selectOnFocus": true });
    var attach_to_email2096 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Attach to email", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Attach to email","(excerpts.ExcerptTypes.attach_to_email) Whether the printable file should be attached to the email\nwhen creating an email from a mailable of this type.\n") }, "name": "attach_to_email", "selectOnFocus": true });
    var main_3_panel2097 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": primary2091, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": print_directly2092, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": certifying2093, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": print_recipient2094, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": backward_compat2095, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": attach_to_email2096, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var excerpts_ExcerptsByType_grid2131 = new Lino.excerpts.ExcerptsByType.GridPanel({ "containing_panel": this, "flex": 62, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Excerpts","(excerpts.excerpts.ExcerptsByType) Base class for all tables on Excerpt.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.excerpts.ExcerptsByType.grid) ] });
    var main_panel2132 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2074, main_2_panel2084, main_3_panel2097, excerpts_ExcerptsByType_grid2131 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2132;
    this.before_row_edit = function(record) {
      template2080.setContextValue('build_method', record ? record.data['build_methodHidden'] : undefined);
      template2080.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      body_template2081.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      email_template2082.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      excerpts_ExcerptsByType_grid2131.on_master_changed();
    }
    this.onRender = function(ct, position) {
      build_method2079.on('change',Lino.chooser_handler(template2080,'build_method'));
      content_type2078.on('change',Lino.chooser_handler(template2080,'content_type'));
      content_type2078.on('change',Lino.chooser_handler(body_template2081,'content_type'));
      content_type2078.on('change',Lino.chooser_handler(email_template2082,'content_type'));
      Lino.excerpts.ExcerptTypes.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.ExcerptTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Links.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 42,
  initComponent : function() {
    var parent2133 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Parent", "hiddenName": "parentHidden", "listeners": { "render": Lino.quicktip_renderer("Parent","(tickets.Links.parent) ") }, "name": "parent", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Links/parent" }) }) });
    var type2134 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Dependency type", "forceSelection": true, "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Dependency type","(tickets.Links.type) ") }, "name": "type", "selectOnFocus": true, "store": Lino.tickets.LinkTypes });
    var child2135 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Child", "hiddenName": "childHidden", "listeners": { "render": Lino.quicktip_renderer("Child","(tickets.Links.child) ") }, "name": "child", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Links/child" }) }) });
    var main_panel2136 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": parent2133, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": type2134, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": child2135, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "form" });
    this.items = main_panel2136;
    this.before_row_edit = function(record) {
    }
    Lino.tickets.Links.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Topics.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 26,
  initComponent : function() {
    var id2140 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Topics.id) ") }, "name": "id", "selectOnFocus": true });
    var name2141 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(courses.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2142 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(courses.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2143 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2140, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2141, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2142, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var courses_LinesByTopic_grid2209 = new Lino.courses.LinesByTopic.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Activity lines","(courses.courses.LinesByTopic) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "center", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.courses.LinesByTopic.grid) ] });
    var courses_CoursesByTopic_grid2267 = new Lino.courses.CoursesByTopic.GridPanel({ "containing_panel": this, "flex": 5, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Activities","(courses.courses.CoursesByTopic) Shows the courses of a given topic.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "region": "south", "split": true, "tools": [ Lino.show_in_own_window_button(Lino.courses.CoursesByTopic.grid) ] });
    var main_panel2268 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2143, courses_LinesByTopic_grid2209, courses_CoursesByTopic_grid2267 ], "labelAlign": "top" });
    this.items = main_panel2268;
    this.before_row_edit = function(record) {
      courses_LinesByTopic_grid2209.on_master_changed();
      courses_CoursesByTopic_grid2267.on_master_changed();
    }
    Lino.courses.Topics.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.Comments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 38,
  initComponent : function() {
    var id2269 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(comments.Comments.id) ") }, "name": "id", "selectOnFocus": true });
    var user2270 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(comments.Comments.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var created2271 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Loodud</span>", "listeners": { "render": Lino.quicktip_renderer("Created","(comments.Comments.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified2272 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Modified","(comments.Comments.modified) ") }, "name": "modified", "value": "<br>" });
    var main_1_panel2273 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 8, "items": id2269, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 35, "items": user2270, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": created2271, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": modified2272, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var reply_to2278 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Comment...", "fieldLabel": "Reply to", "hiddenName": "reply_toHidden", "listeners": { "render": Lino.quicktip_renderer("Reply to","(comments.Comments.reply_to) ") }, "name": "reply_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.comments.Comments.detail,Lino.comments.Comments.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/reply_to" }) }) });
    var owner_disp2279 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var owner_type2280 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "fieldLabel": "Controlled by (type)", "hiddenName": "owner_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Controlled by (type)","(comments.Comments.owner_type) ") }, "name": "owner_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.gfks.ContentTypes.detail,Lino.gfks.ContentTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/owner_type" }) }) });
    var owner_id2281 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Controlled by (object)", "hiddenName": "owner_idHidden", "listeners": { "render": Lino.quicktip_renderer("Controlled by (object)","(comments.Comments.owner_id) ") }, "name": "owner_id", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/owner_id" }) }) });
    var comment_type2282 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Comment Type...", "fieldLabel": "Comment Type", "hiddenName": "comment_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Comment Type","(comments.Comments.comment_type) ") }, "name": "comment_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.comments.CommentTypes.detail,Lino.comments.CommentTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/comment_type" }) }) });
    var main_2_panel2283 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": reply_to2278, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": owner_disp2279, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": owner_type2280, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": owner_id2281, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": comment_type2282, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 207, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var short_text2289 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Short text</span>", "flex": 71, "name": "short_text", "selectOnFocus": true, "title": "Short text" });
    var main_panel2290 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2273, main_2_panel2283, short_text2289 ], "labelAlign": "top", "labelWidth": 99, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2290;
    this.before_row_edit = function(record) {
      owner_id2281.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      short_text2289.refresh();
    }
    this.onRender = function(ct, position) {
      owner_type2280.on('change',Lino.chooser_handler(owner_id2281,'owner_type'));
      Lino.comments.Comments.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.comments.Comments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.about.About.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  disable_editing: true,
  initComponent : function() {
    var server_status_disp2292 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Server status", "listeners": { "render": Lino.quicktip_renderer("Server status","(about.About.server_status) ") }, "name": "server_status", "value": "<br/>" });
    var main_panel2293 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "flex": 25, "html": "<div class=\"htmlText\"><span>This is <a href=\"http://vilma.lino-framework.org/\" target=\"_blank\">Lino Vilma</a> 2017.4.0 using <a href=\"http://www.lino-framework.org\" target=\"_blank\">Lino</a> 2016.12.0, <a href=\"http://www.djangoproject.com\" target=\"_blank\">Django</a> 1.9.13, <a href=\"http://www.python.org/\" target=\"_blank\">Python</a> 2.7.12, <a href=\"http://babel.edgewall.org/\" target=\"_blank\">Babel</a> 2.3.4, <a href=\"http://jinja.pocoo.org/\" target=\"_blank\">Jinja</a> 2.9.5, <a href=\"http://labix.org/python-dateutil\" target=\"_blank\">python-dateutil</a> 2.6.0, <a href=\"http://getbootstrap.com\" target=\"_blank\">Bootstrap</a> 3.3.4, <a href=\"http://www.sencha.com\" target=\"_blank\">ExtJS</a> <a href=\"#\" onclick=\"alert('ExtJS client version is ' + Ext.version);\" title=\"Click to see ExtJS client version\">(version)</a>, <a href=\"http://www.famfamfam.com/lab/icons/silk/\" target=\"_blank\">Silk Icons</a> 1.3, <a href=\"http://ext.ensible.com/products/calendar/\" target=\"_blank\">Ext.ensible adapter</a> <a href=\"#\" onclick=\"alert('Extensible Calendar version is '             + Ext.ensible.version);\" title=\"Click to see Extensible Calendar version\">(version)</a>, <a href=\"https://github.com/django/channels\" target=\"_blank\">Channels (inactive)</a> 1.1.3, <a href=\"http://www.tinymce.com/\" target=\"_blank\">TinyMCE</a> 3.5.11, <a href=\"http://www.byte-force.com\" target=\"_blank\">Ext.ux.TinyMCE</a> 0.8.4</span><p>Languages: en, et</p><p>Server uptime : <b>30/04/2017 at 19:45</b> (UTC)</p><p>This is a Lino demo site.</p><p>We are running with simulated date set to Thursday, 16 March 2017.</p><p>Source timestamps:</p><ul><li>atelier : <b>15/03/2017 at 16:14</b></li><li>django : <b>10/04/2017 at 02:48</b></li><li>lino_noi : <b>27/04/2017 at 16:43</b></li><li>lino : <b>30/04/2017 at 03:07</b></li><li>lino_vilma : <b>30/04/2017 at 19:40</b></li><li>lino_xl : <b>30/04/2017 at 19:43</b></li></ul></div>", "xtype": "label" }, { "autoHeight": true, "items": server_status_disp2292, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2293;
    this.before_row_edit = function(record) {
    }
    Lino.about.About.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Skills.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 49,
  initComponent : function() {
    var id1782 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(faculties.Skills.id) ") }, "name": "id", "selectOnFocus": true });
    var name1783 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(faculties.Skills.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1784 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(faculties.Skills.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1785 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1782, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1783, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1784, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var parent1789 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Parent skill", "hiddenName": "parentHidden", "listeners": { "render": Lino.quicktip_renderer("Parent skill","(faculties.Skills.parent) ") }, "name": "parent", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Skills/parent" }) }) });
    var skill_type1790 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskuseliik...", "fieldLabel": "Oskuseliik", "hiddenName": "skill_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Skill type","(faculties.Skills.skill_type) ") }, "name": "skill_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.SkillTypes.detail,Lino.faculties.SkillTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Skills/skill_type" }) }) });
    var affinity1791 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Affinity</span>", "listeners": { "render": Lino.quicktip_renderer("Affinity","(faculties.Skills.affinity) How much workers enjoy to get a new ticket requiring this skill.A number between -100 and +100.") }, "name": "affinity", "selectOnFocus": true, "value": 100 });
    var main_2_panel1792 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 44, "items": parent1789, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": skill_type1790, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": affinity1791, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var SkillsByParent_grid1862 = new Lino.faculties.SkillsByParent.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Child skills","(faculties.faculties.SkillsByParent) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.faculties.SkillsByParent.grid) ] });
    var remarks1863 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 50, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_3_panel1864 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 41, "frame": false, "hideCheckBoxLabels": true, "items": [ SkillsByParent_grid1862, remarks1863 ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var OffersBySkill_grid1865 = new Lino.faculties.OffersBySkill.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Skill offers","(faculties.faculties.OffersBySkill) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.faculties.OffersBySkill.grid) ] });
    var DemandsBySkill_grid1866 = new Lino.faculties.DemandsBySkill.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Skill demands","(faculties.faculties.DemandsBySkill) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.faculties.DemandsBySkill.grid) ] });
    var main_4_panel1867 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 41, "frame": false, "hideCheckBoxLabels": true, "items": [ OffersBySkill_grid1865, DemandsBySkill_grid1866 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel1868 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1785, main_2_panel1792, main_3_panel1864, main_4_panel1867 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1868;
    this.before_row_edit = function(record) {
      SkillsByParent_grid1862.on_master_changed();
      remarks1863.refresh();
      OffersBySkill_grid1865.on_master_changed();
      DemandsBySkill_grid1866.on_master_changed();
    }
    Lino.faculties.Skills.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.system.SiteConfigs.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 3,
  initComponent : function() {
    var site_company2295 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Site owner</span>", "hiddenName": "site_companyHidden", "listeners": { "render": Lino.quicktip_renderer("Site owner","(system.SiteConfigs.site_company) The organisation who runs this site.  This is used e.g. when\nprinting your address in certain documents or reports.  Or\nnewly created partners inherit the country of the site owner.") }, "name": "site_company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/system/SiteConfigs/site_company" }) }) });
    var next_partner_id2296 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Next partner id</span>", "listeners": { "render": Lino.quicktip_renderer("Next partner id","(system.SiteConfigs.next_partner_id) The next automatic id for any new partner.") }, "name": "next_partner_id", "selectOnFocus": true, "value": 100 });
    var default_build_method2297 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Default build method</span>", "forceSelection": true, "hiddenName": "default_build_methodHidden", "listeners": { "render": Lino.quicktip_renderer("Default build method","(system.SiteConfigs.default_build_method) The default build method to use when rendering printable documents.") }, "name": "default_build_method", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var main_1_panel2298 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 37, "items": site_company2295, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": next_partner_id2296, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": default_build_method2297, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 189, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2302 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2298 ], "labelAlign": "top", "layout": "fit" });
    this.items = main_panel2302;
    this.before_row_edit = function(record) {
    }
    Lino.system.SiteConfigs.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Lines.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 27,
  initComponent : function() {
    var id2170 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Lines.id) ") }, "name": "id", "selectOnFocus": true });
    var name2171 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimetus</span>", "listeners": { "render": Lino.quicktip_renderer("Designation","(courses.Lines.name) The designation of this activity line as seen by the user\ne.g. when selecting the line.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2172 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(courses.Lines.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var ref2173 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(courses.Lines.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var main_1_panel2174 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 7, "items": id2170, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": name2171, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": name_et2172, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": ref2173, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2179 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organisatsioon</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organization","(courses.Lines.company) Pointer to lino_xl.lib.contacts.models.Company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/company" }) }) });
    var contact_person2180 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">represented by</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("represented by","(courses.Lines.contact_person) Pointer to lino_xl.lib.contacts.models.Person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/contact_person" }) }) });
    var main_2_panel2181 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2179, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2180, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var course_area2184 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Layout</span>", "forceSelection": true, "hiddenName": "course_areaHidden", "listeners": { "render": Lino.quicktip_renderer("Layout","(courses.Lines.course_area) Pointer to CourseAreas.  This is used only when an\napplication defines several variants of\nEnrolmentsByPupil.") }, "name": "course_area", "selectOnFocus": true, "store": Lino.courses.CourseAreas });
    var topic2185 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Topic","(courses.Lines.topic) ") }, "name": "topic", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Topics.detail,Lino.courses.Topics.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/topic" }) }) });
    var body_template2186 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Body template</span>", "listeners": { "render": Lino.quicktip_renderer("Body template","(courses.Lines.body_template) The body template to use when printing a course of this series. Leave empty to use the site's default.") }, "name": "body_template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/body_template" }) }) });
    var main_3_panel2187 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": course_area2184, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 46, "items": topic2185, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": body_template2186, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var event_type2191 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">S\u00fcndmuseliik</span>", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(courses.Lines.event_type) The type of calendar entries to be generated. If this is empty, no calendar entries will be generated.") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/event_type" }) }) });
    var guest_role2192 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Guest Role...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Manage presences as</span>", "hiddenName": "guest_roleHidden", "listeners": { "render": Lino.quicktip_renderer("Manage presences as","(courses.Lines.guest_role) The default guest role for particpants of calendar entries for activities in this series. Leave empty if you don't want any presences management.") }, "name": "guest_role", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.GuestRoles.detail,Lino.cal.GuestRoles.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/guest_role" }) }) });
    var every_unit2193 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Korduvus", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Recurrency","(courses.Lines.every_unit) ") }, "name": "every_unit", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every2194 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Repeat every","(courses.Lines.every) ") }, "name": "every", "selectOnFocus": true, "value": 1 });
    var main_4_panel2195 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": event_type2191, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": guest_role2192, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": every_unit2193, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": every2194, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var excerpt_title2200 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Excerpt title</span>", "listeners": { "render": Lino.quicktip_renderer("Excerpt title","(courses.Lines.excerpt_title) The title to be used when printing an excerpt.") }, "maxLength": 200, "name": "excerpt_title", "selectOnFocus": true });
    var excerpt_title_et2201 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Excerpt title (et)", "listeners": { "render": Lino.quicktip_renderer("Excerpt title (et)","(courses.Lines.excerpt_title_et) ") }, "maxLength": 200, "name": "excerpt_title_et", "selectOnFocus": true });
    var main_5_panel2202 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": excerpt_title2200, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": excerpt_title_et2201, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 171, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2205 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et2206 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var main_6_panel2207 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description2205, description_et2206 ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel2208 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2174, main_2_panel2181, main_3_panel2187, main_4_panel2195, main_5_panel2202, main_6_panel2207 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2208;
    this.before_row_edit = function(record) {
      contact_person2180.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2205.refresh();
      description_et2206.refresh();
    }
    this.onRender = function(ct, position) {
      company2179.on('change',Lino.chooser_handler(contact_person2180,'company'));
      Lino.courses.Lines.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.Lines.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Calendars.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 21,
  initComponent : function() {
    var name2303 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.Calendars.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2304 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.Calendars.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2305 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2303, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2304, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var color2308 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "color", "listeners": { "render": Lino.quicktip_renderer("color","(cal.Calendars.color) ") }, "name": "color", "selectOnFocus": true });
    var main_panel2309 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2305, { "anchor": "-20", "autoHeight": true, "items": color2308, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "form" });
    this.items = main_panel2309;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Calendars.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.Entries.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 57,
  initComponent : function() {
    var title687 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Heading", "listeners": { "render": Lino.quicktip_renderer("Heading","(blogs.Entries.title) ") }, "maxLength": 200, "name": "title", "selectOnFocus": true });
    var entry_type688 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Blog Entry Type...", "fieldLabel": "Blog Entry Type", "hiddenName": "entry_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Blog Entry Type","(blogs.Entries.entry_type) ") }, "name": "entry_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.blogs.EntryTypes.detail,Lino.blogs.EntryTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/entry_type" }) }) });
    var main_panel689 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": title687, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": entry_type688, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "form" });
    this.items = main_panel689;
    this.before_row_edit = function(record) {
    }
    Lino.blogs.Entries.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.addresses.Addresses.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 24,
  initComponent : function() {
    var country2311 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Country","(addresses.Addresses.country) ") }, "name": "country", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Countries.detail,Lino.countries.Countries.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/country" }) }) });
    var city2312 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Linn</span>", "forceSelection": false, "hiddenName": "cityHidden", "listeners": { "render": Lino.quicktip_renderer("City","(addresses.Addresses.city) A pointer to Place.") }, "name": "city", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/city" }) }) });
    var main_1_panel2313 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": country2311, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": city2312, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street2316 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">T\u00e4nav</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(addresses.Addresses.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no2317 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nr.</span>", "listeners": { "render": Lino.quicktip_renderer("No.","(addresses.Addresses.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box2318 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Box</span>", "listeners": { "render": Lino.quicktip_renderer("Box","(addresses.Addresses.street_box) Text to print after street nuber on the same line.") }, "maxLength": 10, "name": "street_box", "selectOnFocus": true });
    var main_2_panel2319 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 48, "items": street2316, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": street_no2317, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": street_box2318, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_type2323 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Aadressiliik", "forceSelection": true, "hiddenName": "address_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Address type","(addresses.Addresses.address_type) ") }, "name": "address_type", "selectOnFocus": true, "store": Lino.addresses.AddressTypes });
    var remark2324 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(addresses.Addresses.remark) ") }, "maxLength": 50, "name": "remark", "selectOnFocus": true });
    var main_3_panel2325 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": address_type2323, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": remark2324, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2328 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2313, main_2_panel2319, main_3_panel2325 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2328;
    this.before_row_edit = function(record) {
      city2312.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city2312.setContextValue('region', record ? record.data['regionHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      country2311.on('change',Lino.chooser_handler(city2312,'country'));
      Lino.addresses.Addresses.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.addresses.Addresses.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Offers.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 47,
  initComponent : function() {
    var user527 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("User","(faculties.Offers.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/user" }) }) });
    var end_user528 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "End user", "hiddenName": "end_userHidden", "listeners": { "render": Lino.quicktip_renderer("End user","(faculties.Offers.end_user) ") }, "name": "end_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/end_user" }) }) });
    var main_1_panel529 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": user527, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": end_user528, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var faculty532 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "facultyHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(faculties.Offers.faculty) ") }, "name": "faculty", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/faculty" }) }) });
    var affinity533 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Affinity</span>", "listeners": { "render": Lino.quicktip_renderer("Affinity","(faculties.Offers.affinity) How much this user likes to get a new ticket in this faculty.A number between -100 and +100.") }, "name": "affinity", "selectOnFocus": true, "value": 100 });
    var main_2_panel534 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 80, "items": faculty532, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": affinity533, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description537 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 71, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_panel538 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel529, main_2_panel534, description537 ], "labelAlign": "top", "labelWidth": 108, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel538;
    this.before_row_edit = function(record) {
      description537.refresh();
    }
    Lino.faculties.Offers.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.Sessions.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 52,
  initComponent : function() {
    var ticket2329 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket","(clocking.Sessions.ticket) ") }, "name": "ticket", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/ticket" }) }) });
    var user2330 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "T\u00f6\u00f6taja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Worker","(clocking.Sessions.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/user" }) }) });
    var faculty2331 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Oskus</span>", "hiddenName": "facultyHidden", "listeners": { "render": Lino.quicktip_renderer("Skill","(clocking.Sessions.faculty) The faculty that has been used during this session. On a new\nsession this defaults to the needed faculty currently specified\non the ticket.") }, "name": "faculty", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.faculties.Skills.detail,Lino.faculties.Skills.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/faculty" }) }) });
    var main_1_panel2332 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": ticket2329, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": user2330, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": faculty2331, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date2336 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Algab (p\u00e4ev)</span>", "listeners": { "render": Lino.quicktip_renderer("Start date","(clocking.Sessions.start_date) The date when you started to work.") }, "name": "start_date", "selectOnFocus": true });
    var start_time2337 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Start time</span>", "listeners": { "render": Lino.quicktip_renderer("Start time","(clocking.Sessions.start_time) The time (in hh:mm) when you started working on this\nsession.") }, "name": "start_time", "selectOnFocus": true });
    var end_date2338 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">End Date</span>", "listeners": { "render": Lino.quicktip_renderer("End Date","(clocking.Sessions.end_date) Leave this field blank if it is the same date as start_date.") }, "name": "end_date", "selectOnFocus": true });
    var end_time2339 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00f5peb (aeg)</span>", "listeners": { "render": Lino.quicktip_renderer("End Time","(clocking.Sessions.end_time) The time (in hh:mm) when you stopped to work. This is empty\nas long as you are busy with this session.") }, "name": "end_time", "selectOnFocus": true });
    var break_time2340 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(6), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Paus</span>", "listeners": { "render": Lino.quicktip_renderer("Break Time","(clocking.Sessions.break_time) The time (in hh:mm) to remove from the duration resulting\nfrom the difference between start_time and\nend_time.") }, "maxLength": 6, "name": "break_time", "selectOnFocus": true });
    var duration2341 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(6), "disabled": true, "fieldLabel": "Kestus", "listeners": { "render": Lino.quicktip_renderer("Duration","(clocking.Sessions.duration) ") }, "maxLength": 6, "name": "duration" });
    var main_2_panel2342 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 23, "items": start_date2336, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": start_time2337, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": end_date2338, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": end_time2339, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": break_time2340, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": duration2341, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var summary2349 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kokkuv\u00f5te</span>", "listeners": { "render": Lino.quicktip_renderer("Summary","(clocking.Sessions.summary) Summary of the session.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var workflow_buttons_disp2350 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(clocking.Sessions.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var main_3_panel2351 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 75, "items": summary2349, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": workflow_buttons_disp2350, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2354 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_panel2355 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2332, main_2_panel2342, main_3_panel2351, description2354 ], "labelAlign": "top", "labelWidth": 108, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2355;
    this.before_row_edit = function(record) {
      description2354.refresh();
    }
    Lino.clocking.Sessions.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Partners.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 8,
  initComponent : function() {
    var name1986 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimi</span>", "listeners": { "render": Lino.quicktip_renderer("Name","(contacts.Partners.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var country1987 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Country","(contacts.Partners.country) ") }, "name": "country", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Countries.detail,Lino.countries.Countries.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Partners/country" }) }) });
    var city1988 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Linn</span>", "forceSelection": false, "hiddenName": "cityHidden", "listeners": { "render": Lino.quicktip_renderer("City","(contacts.Partners.city) A pointer to Place.") }, "name": "city", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Partners/city" }) }) });
    var zip_code1989 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "Zip code", "listeners": { "render": Lino.quicktip_renderer("Zip code","(contacts.Partners.zip_code) ") }, "maxLength": 10, "name": "zip_code", "selectOnFocus": true });
    var address_box_2_panel1990 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": country1987, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": city1988, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code1989, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street1994 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">T\u00e4nav</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(contacts.Partners.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no1995 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nr.</span>", "listeners": { "render": Lino.quicktip_renderer("No.","(contacts.Partners.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box1996 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Box</span>", "listeners": { "render": Lino.quicktip_renderer("Box","(contacts.Partners.street_box) Text to print after street nuber on the same line.") }, "maxLength": 10, "name": "street_box", "selectOnFocus": true });
    var address_box_4_panel1997 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": street1994, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_no1995, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_box1996, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_box_panel2001 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 50, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name1986, "labelAlign": "top", "layout": "form", "xtype": "panel" }, address_box_2_panel1990, address_box_4_panel1997 ], "labelAlign": "top", "labelWidth": 45, "layout": "form", "title": "Aadres" });
    var url2003 = new Lino.URLField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "URL", "listeners": { "render": Lino.quicktip_renderer("URL","(contacts.Partners.url) ") }, "maxLength": 200, "name": "url", "selectOnFocus": true });
    var phone2004 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Phone</span>", "listeners": { "render": Lino.quicktip_renderer("Phone","(contacts.Partners.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.") }, "maxLength": 200, "name": "phone", "selectOnFocus": true });
    var gsm2005 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">GSM</span>", "listeners": { "render": Lino.quicktip_renderer("GSM","(contacts.Partners.gsm) The primary mobile phone number.") }, "maxLength": 200, "name": "gsm", "selectOnFocus": true });
    var contact_box_panel2006 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 25, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": url2003, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": phone2004, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": gsm2005, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "form", "title": "Contact" });
    var overview_disp2010 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "flex": 25, "listeners": { "render": Lino.quicktip_renderer(null,"(contacts.Partners.overview) ") }, "name": "overview", "value": "<br/>" });
    var main_1_panel2011 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ address_box_panel2001, contact_box_panel2006, overview_disp2010 ], "labelAlign": "top", "labelWidth": 0, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks2012 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 62, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_panel2013 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2011, remarks2012 ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2013;
    this.before_row_edit = function(record) {
      city1988.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1988.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      remarks2012.refresh();
    }
    this.onRender = function(ct, position) {
      country1987.on('change',Lino.chooser_handler(city1988,'country'));
      Lino.contacts.Partners.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.contacts.Partners.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city1988.on("change", function(){ this.save() }, this);
    zip_code1989.on("change", function(){ this.save() }, this);
  }
});


Lino.cal.EventTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 15,
  initComponent : function() {
    var name2356 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.EventTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2357 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.EventTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2358 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2356, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2357, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var event_label2361 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Entry label</span>", "listeners": { "render": Lino.quicktip_renderer("Entry label","(cal.EventTypes.event_label) Default text for summary of new entries.") }, "maxLength": 200, "name": "event_label", "selectOnFocus": true });
    var event_label_et2362 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Entry label (et)", "listeners": { "render": Lino.quicktip_renderer("Entry label (et)","(cal.EventTypes.event_label_et) ") }, "maxLength": 200, "name": "event_label_et", "selectOnFocus": true });
    var main_2_panel2363 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": event_label2361, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": event_label_et2362, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date2366 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(cal.EventTypes.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var max_days2367 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Maximum days</span>", "listeners": { "render": Lino.quicktip_renderer("Maximum days","(cal.EventTypes.max_days) The maximal number of days allowed as duration.") }, "name": "max_days", "selectOnFocus": true, "value": 1 });
    var id2368 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.EventTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var main_3_panel2369 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 56, "items": start_date2366, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": max_days2367, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": id2368, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var email_template2373 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Email template</span>", "listeners": { "render": Lino.quicktip_renderer("Email template","(cal.EventTypes.email_template) The name of the file to be used as template when creating an email from a mailable of this type.") }, "name": "email_template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EventTypes/email_template" }) }) });
    var attach_to_email2374 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Attach to email", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Attach to email","(cal.EventTypes.attach_to_email) Whether the printable file should be attached to the email\nwhen creating an email from a mailable of this type.\n") }, "name": "attach_to_email", "selectOnFocus": true });
    var main_4_panel2375 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": email_template2373, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": attach_to_email2374, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var is_appointment2378 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Appointment", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Appointment","(cal.EventTypes.is_appointment) Whether entries of this type should be considered\n\"appointments\" (i.e. whose time and place have been agreed\nupon with other users or external parties).") }, "name": "is_appointment", "selectOnFocus": true });
    var all_rooms2379 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Locks all rooms", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Locks all rooms","(cal.EventTypes.all_rooms) ") }, "name": "all_rooms", "selectOnFocus": true });
    var locks_user2380 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Locks the user", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Locks the user","(cal.EventTypes.locks_user) Whether calendar entries of this type make the user\nunavailable for other locking events at the same time.") }, "name": "locks_user", "selectOnFocus": true });
    var max_conflicting2381 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Simultaneous entries</span>", "listeners": { "render": Lino.quicktip_renderer("Simultaneous entries","(cal.EventTypes.max_conflicting) How many conflicting events should be tolerated.") }, "name": "max_conflicting", "selectOnFocus": true, "value": 1 });
    var main_5_panel2382 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 28, "items": is_appointment2378, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": all_rooms2379, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": locks_user2380, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": max_conflicting2381, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 189, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var EntriesByType_grid2472 = new Lino.cal.EntriesByType.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("events","(cal.cal.EntriesByType) Table which shows all calendar events.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.cal.EntriesByType.grid) ] });
    var main_panel2473 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2358, main_2_panel2363, main_3_panel2369, main_4_panel2375, main_5_panel2382, EntriesByType_grid2472 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2473;
    this.before_row_edit = function(record) {
      EntriesByType_grid2472.on_master_changed();
    }
    Lino.cal.EventTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Calendars.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 21,
  initComponent : function() {
    var name2474 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.Calendars.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2475 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.Calendars.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var color2476 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "color", "listeners": { "render": Lino.quicktip_renderer("color","(cal.Calendars.color) ") }, "name": "color", "selectOnFocus": true });
    var id2477 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Calendars.id) ") }, "name": "id", "selectOnFocus": true });
    var main_1_panel2478 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": name2474, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": name_et2475, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": color2476, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": id2477, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2483 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 33, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var SubscriptionsByCalendar_grid2493 = new Lino.cal.SubscriptionsByCalendar.GridPanel({ "containing_panel": this, "flex": 66, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Subscriptions","(cal.cal.SubscriptionsByCalendar) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.cal.SubscriptionsByCalendar.grid) ] });
    var main_2_panel2494 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 83, "frame": false, "hideCheckBoxLabels": true, "items": [ description2483, SubscriptionsByCalendar_grid2493 ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel2495 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2478, main_2_panel2494 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2495;
    this.before_row_edit = function(record) {
      description2483.refresh();
      SubscriptionsByCalendar_grid2493.on_master_changed();
    }
    Lino.cal.Calendars.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.ServiceReports.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 51,
  initComponent : function() {
    var start_date2496 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(clocking.ServiceReports.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date2497 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("End date","(clocking.ServiceReports.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var user2498 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Autor</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(clocking.ServiceReports.user) This can be empty and will then show the working time of all\nusers.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/user" }) }) });
    var interesting_for2499 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Interesting for</span>", "hiddenName": "interesting_forHidden", "listeners": { "render": Lino.quicktip_renderer("Interesting for","(clocking.ServiceReports.interesting_for) Only tickets interesting for this partner.") }, "name": "interesting_for", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/interesting_for" }) }) });
    var ticket_state2500 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Staatus</span>", "forceSelection": true, "hiddenName": "ticket_stateHidden", "listeners": { "render": Lino.quicktip_renderer("State","(clocking.ServiceReports.ticket_state) Only tickets in this state.") }, "name": "ticket_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var printed_disp2501 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Tr\u00fckitud", "listeners": { "render": Lino.quicktip_renderer("Printed","(clocking.ServiceReports.printed) ") }, "name": "printed", "value": "<br/>" });
    var main_1_panel2502 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 12, "items": start_date2496, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": end_date2497, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": user2498, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": interesting_for2499, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": ticket_state2500, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": printed_disp2501, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2509 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organisatsioon</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organization","(clocking.ServiceReports.company) Pointer to lino_xl.lib.contacts.models.Company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/company" }) }) });
    var contact_person2510 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">represented by</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("represented by","(clocking.ServiceReports.contact_person) Pointer to lino_xl.lib.contacts.models.Person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/contact_person" }) }) });
    var main_2_panel2511 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2509, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2510, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var SessionsByReport_grid2530 = new Lino.clocking.SessionsByReport.GridPanel({ "containing_panel": this, "flex": 55, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Sessions","(clocking.clocking.SessionsByReport) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.clocking.SessionsByReport.grid) ] });
    var main_panel2531 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2502, main_2_panel2511, SessionsByReport_grid2530 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2531;
    this.before_row_edit = function(record) {
      contact_person2510.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      SessionsByReport_grid2530.on_master_changed();
    }
    this.onRender = function(ct, position) {
      company2509.on('change',Lino.chooser_handler(contact_person2510,'company'));
      Lino.clocking.ServiceReports.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.clocking.ServiceReports.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.countries.Places.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 2,
  initComponent : function() {
    var name1913 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(countries.Places.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1914 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(countries.Places.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var country1915 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Country","(countries.Places.country) ") }, "name": "country", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Countries.detail,Lino.countries.Countries.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/country" }) }) });
    var main_1_panel1916 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": name1913, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": name_et1914, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": country1915, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var type1920 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Asumiliik", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Place Type","(countries.Places.type) ") }, "name": "type", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/type" }) }) });
    var parent1921 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Part of</span>", "hiddenName": "parentHidden", "listeners": { "render": Lino.quicktip_renderer("Part of","(countries.Places.parent) The superordinate geographic place of which this place is a part.") }, "name": "parent", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.countries.Places.detail,Lino.countries.Places.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/parent" }) }) });
    var zip_code1922 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(8), "fieldLabel": "zip code", "listeners": { "render": Lino.quicktip_renderer("zip code","(countries.Places.zip_code) ") }, "maxLength": 8, "name": "zip_code", "selectOnFocus": true });
    var id1923 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(countries.Places.id) ") }, "name": "id", "selectOnFocus": true });
    var main_2_panel1924 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": type1920, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 45, "items": parent1921, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code1922, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": id1923, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var PlacesByPlace_grid2016 = new Lino.countries.PlacesByPlace.GridPanel({ "containing_panel": this, "flex": 41, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Subdivisions","(countries.countries.PlacesByPlace) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.countries.PlacesByPlace.grid) ] });
    var contacts_PartnersByCity_grid2017 = new Lino.contacts.PartnersByCity.GridPanel({ "containing_panel": this, "flex": 41, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Partners","(contacts.contacts.PartnersByCity) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.contacts.PartnersByCity.grid) ] });
    var main_panel2018 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1916, main_2_panel1924, PlacesByPlace_grid2016, contacts_PartnersByCity_grid2017 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2018;
    this.before_row_edit = function(record) {
      type1920.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      PlacesByPlace_grid2016.on_master_changed();
      contacts_PartnersByCity_grid2017.on_master_changed();
    }
    this.onRender = function(ct, position) {
      country1915.on('change',Lino.chooser_handler(type1920,'country'));
      Lino.countries.Places.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.countries.Places.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Events.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 16,
  initComponent : function() {
    var event_type2427 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">S\u00fcndmuseliik</span>", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Calendar entry type","(cal.Events.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.") }, "name": "event_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.EventTypes.detail,Lino.cal.EventTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/event_type" }) }) });
    var summary2428 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00fchikirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Short description","(cal.Events.summary) A one-line descriptive text.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var id2429 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Events.id) ") }, "name": "id", "selectOnFocus": true });
    var general_1_panel2430 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 23, "items": event_type2427, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 70, "items": summary2428, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 5, "items": id2429, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date2434 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(cal.Events.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var start_time2435 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Start time", "listeners": { "render": Lino.quicktip_renderer("Start time","(cal.Events.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var start_panel2436 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "flex": 38, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": start_date2434, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": start_time2435, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var end_date2439 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "End Date", "listeners": { "render": Lino.quicktip_renderer("End Date","(cal.Events.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var end_time2440 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00f5peb (aeg)</span>", "listeners": { "render": Lino.quicktip_renderer("End Time","(cal.Events.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.") }, "name": "end_time", "selectOnFocus": true });
    var end_panel2441 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "flex": 38, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": end_date2439, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": end_time2440, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var access_class2444 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Access Class</span>", "forceSelection": true, "hiddenName": "access_classHidden", "listeners": { "render": Lino.quicktip_renderer("Access Class","(cal.Events.access_class) Whether this is private, public or between.") }, "name": "access_class", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var general_2_panel2445 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ start_panel2436, end_panel2441, { "autoHeight": true, "flex": 22, "items": access_class2444, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user2447 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Autor</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(cal.Events.user) The responsible user.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/user" }) }) });
    var room2448 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Room","(cal.Events.room) ") }, "name": "room", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Rooms.detail,Lino.cal.Rooms.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/room" }) }) });
    var company2449 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organizer</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Organizer","(cal.Events.company) Pointer to lino_xl.lib.contacts.models.Company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/company" }) }) });
    var contact_person2450 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kontaktisik</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Contact person","(cal.Events.contact_person) Pointer to lino_xl.lib.contacts.models.Person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/contact_person" }) }) });
    var general_3_panel2451 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": user2447, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": room2448, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": company2449, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": contact_person2450, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var owner_disp2456 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var workflow_buttons_disp2457 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(cal.Events.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var general_4_panel2458 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": owner_disp2456, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 75, "items": workflow_buttons_disp2457, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2461 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Description","(cal.Events.description) A longer descriptive text.") }, "name": "description", "selectOnFocus": true });
    var blogs_EntriesByController_htmlbox2462 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 33, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Blog Entries","(cal.Events.blogs_EntriesByController) ") }, "master_panel": this, "name": "blogs_EntriesByController", "title": "Blog Entries", "tools": [ Lino.show_in_own_window_button(Lino.blogs.EntriesByController.grid) ], "value": "<br/>" });
    var general_5_panel2463 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 45, "frame": false, "hideCheckBoxLabels": true, "items": [ { "flex": 66, "items": description2461, "labelAlign": "top", "layout": "form", "xtype": "panel" }, blogs_EntriesByController_htmlbox2462 ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var general_panel2465 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel2430, general_2_panel2445, general_3_panel2451, general_4_panel2458, general_5_panel2463 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var GuestsByEvent_grid2470 = new Lino.cal.GuestsByEvent.GridPanel({ "containing_panel": this, "hide_top_toolbar": true, "listeners": { "activate": Lino.on_tab_activate }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "title": "Kohalolekud", "tools": [ Lino.show_in_own_window_button(Lino.cal.GuestsByEvent.grid) ] });
    var main_panel2471 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel2465, GuestsByEvent_grid2470 ], "labelAlign": "top", "split": true });
    this.items = main_panel2471;
    this.before_row_edit = function(record) {
      contact_person2450.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      blogs_EntriesByController_htmlbox2462.refresh();
      GuestsByEvent_grid2470.on_master_changed();
    }
    this.onRender = function(ct, position) {
      company2449.on('change',Lino.chooser_handler(contact_person2450,'company'));
      Lino.cal.Events.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.cal.Events.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.VotesByVotable.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 33,
  initComponent : function() {
    var mail_mode2532 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Email notification mode", "forceSelection": true, "hiddenName": "mail_modeHidden", "listeners": { "render": Lino.quicktip_renderer("Email notification mode","(votes.VotesByVotable.mail_mode) ") }, "name": "mail_mode", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.notify.MailModes) });
    var workflow_buttons_disp2533 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(votes.VotesByVotable.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var rating2534 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Rating</span>", "forceSelection": true, "hiddenName": "ratingHidden", "listeners": { "render": Lino.quicktip_renderer("Rating","(votes.VotesByVotable.rating) How the ticket author rates my help on this ticket.") }, "name": "rating", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.votes.Ratings) });
    var main_panel2535 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": mail_mode2532, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": workflow_buttons_disp2533, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": rating2534, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel2535;
    this.before_row_edit = function(record) {
    }
    Lino.votes.VotesByVotable.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.lists.Lists.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 56,
  initComponent : function() {
    var ref2539 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Reference</span>", "listeners": { "render": Lino.quicktip_renderer("Reference","(lists.Lists.ref) The reference. This must be either empty or unique.") }, "maxLength": 40, "name": "ref", "selectOnFocus": true });
    var list_type2540 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Listiliik...", "fieldLabel": "Listiliik", "hiddenName": "list_typeHidden", "listeners": { "render": Lino.quicktip_renderer("List Type","(lists.Lists.list_type) ") }, "name": "list_type", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/Lists/list_type" }) }) });
    var id2541 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(lists.Lists.id) ") }, "name": "id", "selectOnFocus": true });
    var main_1_panel2542 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 45, "items": ref2539, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": list_type2540, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": id2541, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2546 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(lists.Lists.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2547 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(lists.Lists.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel2548 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2546, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2547, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks2551 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 41, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var MembersByList_grid2563 = new Lino.lists.MembersByList.GridPanel({ "containing_panel": this, "flex": 41, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Members","(lists.lists.MembersByList) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.lists.MembersByList.grid) ] });
    var main_panel2564 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2542, main_2_panel2548, remarks2551, MembersByList_grid2563 ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2564;
    this.before_row_edit = function(record) {
      remarks2551.refresh();
      MembersByList_grid2563.on_master_changed();
    }
    Lino.lists.Lists.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.Comments.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 38,
  initComponent : function() {
    var reply_to2565 = new Lino.TwinCombo({ "emptyText": "Vali m\u00f5ni Comment...", "fieldLabel": "Reply to", "flex": 66, "hidden": true, "hiddenName": "reply_toHidden", "listeners": { "render": Lino.quicktip_renderer("Reply to","(comments.Comments.reply_to) ") }, "name": "reply_to", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.comments.Comments.detail,Lino.comments.Comments.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/reply_to" }) }) });
    var owner_disp2566 = new Ext.form.DisplayField({ "disabled": true, "fieldLabel": "Controlled by", "flex": 33, "hidden": true, "name": "owner" });
    var main_1_panel2567 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hidden": true, "hideCheckBoxLabels": true, "items": [ reply_to2565, owner_disp2566 ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var short_text2568 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Short text</span>", "flex": 83, "name": "short_text", "selectOnFocus": true, "title": "Short text" });
    var main_panel2569 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2567, short_text2568 ], "labelAlign": "top", "labelWidth": 99, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2569;
    this.before_row_edit = function(record) {
      short_text2568.refresh();
    }
    Lino.comments.Comments.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.UploadsByController.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 62,
  initComponent : function() {
    var file2570 = Lino.file_field_handler(this,{ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Fail</span>", "listeners": { "render": Lino.quicktip_renderer("File","(uploads.UploadsByController.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file") }, "maxLength": 100, "name": "file", "selectOnFocus": true });
    var type2571 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Upload Type...", "fieldLabel": "Upload Type", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Type","(uploads.UploadsByController.type) ") }, "name": "type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.uploads.UploadTypes.detail,Lino.uploads.UploadTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByController/type" }) }) });
    var description2572 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Description","(uploads.UploadsByController.description) A short description entered manually by the user.") }, "maxLength": 200, "name": "description", "selectOnFocus": true });
    var main_panel2573 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": file2570, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": type2571, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": description2572, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel2573;
    this.before_row_edit = function(record) {
      type2571.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    }
    Lino.uploads.UploadsByController.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.Entries.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 57,
  initComponent : function() {
    var title657 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Heading", "listeners": { "render": Lino.quicktip_renderer("Heading","(blogs.Entries.title) ") }, "maxLength": 200, "name": "title", "selectOnFocus": true });
    var entry_type658 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Blog Entry Type...", "fieldLabel": "Blog Entry Type", "hiddenName": "entry_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Blog Entry Type","(blogs.Entries.entry_type) ") }, "name": "entry_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.blogs.EntryTypes.detail,Lino.blogs.EntryTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/entry_type" }) }) });
    var id659 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(blogs.Entries.id) ") }, "name": "id", "selectOnFocus": true });
    var main_1_panel660 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 55, "items": title657, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": entry_type658, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": id659, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var pub_date664 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Publication date", "listeners": { "render": Lino.quicktip_renderer("Publication date","(blogs.Entries.pub_date) ") }, "name": "pub_date", "selectOnFocus": true });
    var pub_time665 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Publication time", "listeners": { "render": Lino.quicktip_renderer("Publication time","(blogs.Entries.pub_time) ") }, "name": "pub_time", "selectOnFocus": true });
    var user666 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(blogs.Entries.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/user" }) }) });
    var language667 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Keel", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(blogs.Entries.language) ") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp668 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var main_2_panel669 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": pub_date664, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": pub_time665, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": user666, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": language667, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": owner_disp668, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var body675 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Body", "flex": 75, "name": "body", "selectOnFocus": true, "title": "Body" });
    var TaggingsByEntry_grid684 = new Lino.blogs.TaggingsByEntry.GridPanel({ "containing_panel": this, "flex": 25, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Taggings","(blogs.blogs.TaggingsByEntry) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.blogs.TaggingsByEntry.grid) ] });
    var main_3_panel685 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 71, "frame": false, "hideCheckBoxLabels": true, "items": [ body675, TaggingsByEntry_grid684 ], "labelAlign": "top", "labelWidth": 45, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel686 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel660, main_2_panel669, main_3_panel685 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel686;
    this.before_row_edit = function(record) {
      body675.refresh();
      TaggingsByEntry_grid684.on_master_changed();
    }
    Lino.blogs.Entries.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.EventTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 15,
  initComponent : function() {
    var name2577 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.EventTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2578 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.EventTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2579 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2577, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2578, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var event_label2582 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Entry label</span>", "listeners": { "render": Lino.quicktip_renderer("Entry label","(cal.EventTypes.event_label) Default text for summary of new entries.") }, "maxLength": 200, "name": "event_label", "selectOnFocus": true });
    var event_label_et2583 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Entry label (et)", "listeners": { "render": Lino.quicktip_renderer("Entry label (et)","(cal.EventTypes.event_label_et) ") }, "maxLength": 200, "name": "event_label_et", "selectOnFocus": true });
    var main_2_panel2584 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": event_label2582, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": event_label_et2583, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2587 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2579, main_2_panel2584 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2587;
    this.before_row_edit = function(record) {
    }
    Lino.cal.EventTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 29,
  initComponent : function() {
    var line2256 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "fieldLabel": "Tegevuste sari", "hiddenName": "lineHidden", "listeners": { "render": Lino.quicktip_renderer("Activity line","(courses.Activities.line) ") }, "name": "line", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Lines.detail,Lino.courses.Lines.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/line" }) }) });
    var teacher2257 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "\u00dcrituse juht", "hiddenName": "teacherHidden", "listeners": { "render": Lino.quicktip_renderer("Instructor","(courses.Activities.teacher) ") }, "name": "teacher", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/teacher" }) }) });
    var main_1_panel2258 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": line2256, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": teacher2257, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2261 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(courses.Activities.name) ") }, "maxLength": 100, "name": "name", "selectOnFocus": true });
    var start_date2262 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Start date","(courses.Activities.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var main_2_panel2263 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": name2261, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": start_date2262, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2266 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2258, main_2_panel2263 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2266;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Activities.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Rooms.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 13,
  initComponent : function() {
    var id2588 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Rooms.id) ") }, "name": "id", "selectOnFocus": true });
    var name2589 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.Rooms.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2590 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.Rooms.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2591 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2588, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2589, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2590, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2595 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Responsible</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Responsible","(cal.Rooms.company) Pointer to lino_xl.lib.contacts.models.Company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/company" }) }) });
    var contact_person2596 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kontaktisik</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Contact person","(cal.Rooms.contact_person) Pointer to lino_xl.lib.contacts.models.Person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/contact_person" }) }) });
    var main_panel2597 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2591, { "anchor": "-20", "autoHeight": true, "items": company2595, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": contact_person2596, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "form" });
    this.items = main_panel2597;
    this.before_row_edit = function(record) {
      contact_person2596.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      company2595.on('change',Lino.chooser_handler(contact_person2596,'company'));
      Lino.cal.Rooms.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.cal.Rooms.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.Sessions.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 52,
  initComponent : function() {
    var ticket2523 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Ticket","(clocking.Sessions.ticket) ") }, "name": "ticket", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.tickets.Tickets.detail,Lino.tickets.Tickets.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/ticket" }) }) });
    var summary2524 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kokkuv\u00f5te</span>", "listeners": { "render": Lino.quicktip_renderer("Summary","(clocking.Sessions.summary) Summary of the session.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var session_type2525 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Istungiliik...", "fieldLabel": "Istungiliik", "hiddenName": "session_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Session Type","(clocking.Sessions.session_type) ") }, "name": "session_type", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/session_type" }) }) });
    var main_panel2526 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": ticket2523, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": summary2524, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": session_type2525, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "form" });
    this.items = main_panel2526;
    this.before_row_edit = function(record) {
    }
    Lino.clocking.Sessions.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Users.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 10,
  initComponent : function() {
    var username2600 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajanimi", "listeners": { "render": Lino.quicktip_renderer("Username","(users.Users.username) ") }, "maxLength": 30, "name": "username", "selectOnFocus": true });
    var profile2601 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajaliik", "forceSelection": true, "hiddenName": "profileHidden", "listeners": { "render": Lino.quicktip_renderer("User type","(users.Users.profile) ") }, "name": "profile", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var box1_1_panel2602 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": username2600, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": profile2601, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var first_name2605 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("First name","(users.Users.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name2606 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Last name","(users.Users.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var initials2607 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "Initials", "listeners": { "render": Lino.quicktip_renderer("Initials","(users.Users.initials) ") }, "maxLength": 10, "name": "initials", "selectOnFocus": true });
    var box1_2_panel2608 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": first_name2605, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": last_name2606, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": initials2607, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var email2612 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(users.Users.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var language2613 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(users.Users.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var timezone2614 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Time zone", "listeners": { "render": Lino.quicktip_renderer("Time zone","(users.Users.timezone) ") }, "name": "timezone", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/timezone" }) }) });
    var box1_3_panel2615 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 41, "items": email2612, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": language2613, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": timezone2614, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id2619 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(users.Users.id) ") }, "name": "id", "selectOnFocus": true });
    var created2620 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Loodud</span>", "listeners": { "render": Lino.quicktip_renderer("Created","(users.Users.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified2621 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Modified","(users.Users.modified) ") }, "name": "modified", "value": "<br>" });
    var box1_4_panel2622 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 13, "items": id2619, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": created2620, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": modified2621, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var box1_panel2626 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ box1_1_panel2602, box1_2_panel2608, box1_3_panel2615, box1_4_panel2622 ], "labelAlign": "top", "layout": "form" });
    var remarks2627 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 66, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var AuthoritiesGiven_grid2630 = new Lino.users.AuthoritiesGiven.GridPanel({ "containing_panel": this, "flex": 33, "hideHeaders": true, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Authorities given","(users.users.AuthoritiesGiven) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.users.AuthoritiesGiven.grid) ] });
    var main_2_panel2631 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 55, "frame": false, "hideCheckBoxLabels": true, "items": [ remarks2627, AuthoritiesGiven_grid2630 ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel2632 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ box1_panel2626, main_2_panel2631 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2632;
    this.before_row_edit = function(record) {
      timezone2614.setContextValue('partner', record ? record.data['partner'] : undefined);
      remarks2627.refresh();
      AuthoritiesGiven_grid2630.on_master_changed();
    }
    Lino.users.Users.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
  }
});


Lino.users.Users.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 10,
  initComponent : function() {
    var username2633 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajanimi", "listeners": { "render": Lino.quicktip_renderer("Username","(users.Users.username) ") }, "maxLength": 30, "name": "username", "selectOnFocus": true });
    var email2634 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">e-mail address</span>", "listeners": { "render": Lino.quicktip_renderer("e-mail address","(users.Users.email) The primary email address.") }, "maxLength": 254, "name": "email", "selectOnFocus": true });
    var main_1_panel2635 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": username2633, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": email2634, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var first_name2638 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("First name","(users.Users.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name2639 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Last name","(users.Users.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var main_2_panel2640 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": first_name2638, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": last_name2639, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var language2643 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Language","(users.Users.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var profile2644 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajaliik", "forceSelection": true, "hiddenName": "profileHidden", "listeners": { "render": Lino.quicktip_renderer("User type","(users.Users.profile) ") }, "name": "profile", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var main_4_panel2645 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 45, "items": language2643, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 54, "items": profile2644, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2648 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2635, main_2_panel2640, main_4_panel2645 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2648;
    this.before_row_edit = function(record) {
    }
    Lino.users.Users.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.ProjectTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 44,
  initComponent : function() {
    var id2649 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tickets.ProjectTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2650 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(tickets.ProjectTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2651 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(tickets.ProjectTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2652 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2649, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2650, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2651, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var ProjectsByType_grid2681 = new Lino.tickets.ProjectsByType.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Missions","(tickets.tickets.ProjectsByType) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.ProjectsByType.grid) ] });
    var main_panel2682 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2652, ProjectsByType_grid2681 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2682;
    this.before_row_edit = function(record) {
      ProjectsByType_grid2681.on_master_changed();
    }
    Lino.tickets.ProjectTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Slots.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 25,
  initComponent : function() {
    var name2683 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Name","(courses.Slots.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var start_time2684 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (aeg)", "listeners": { "render": Lino.quicktip_renderer("Start Time","(courses.Slots.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var end_time2685 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("End Time","(courses.Slots.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var main_1_panel2686 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 56, "items": name2683, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": start_time2684, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": end_time2685, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var courses_CoursesBySlot_grid2736 = new Lino.courses.CoursesBySlot.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Activities","(courses.courses.CoursesBySlot) Base table for all activities.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.courses.CoursesBySlot.grid) ] });
    var main_panel2737 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2686, courses_CoursesBySlot_grid2736 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2737;
    this.before_row_edit = function(record) {
      courses_CoursesBySlot_grid2736.on_master_changed();
    }
    Lino.courses.Slots.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Slots.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 25,
  initComponent : function() {
    var start_time2738 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (aeg)", "listeners": { "render": Lino.quicktip_renderer("Start Time","(courses.Slots.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var end_time2739 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("End Time","(courses.Slots.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var main_1_panel2740 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": start_time2738, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": end_time2739, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2743 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Name","(courses.Slots.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var main_panel2744 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2740, { "anchor": "-20", "autoHeight": true, "items": name2743, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 45, "layout": "form" });
    this.items = main_panel2744;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Slots.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tinymce.TextFieldTemplates.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 66,
  initComponent : function() {
    var id2746 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tinymce.TextFieldTemplates.id) ") }, "name": "id", "selectOnFocus": true });
    var name2747 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(tinymce.TextFieldTemplates.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var user2748 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(tinymce.TextFieldTemplates.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tinymce/TextFieldTemplates/user" }) }) });
    var main_1_panel2749 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2746, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 45, "items": name2747, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": user2748, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var description2753 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "Kirjeldus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Description","(tinymce.TextFieldTemplates.description) ") }, "name": "description", "selectOnFocus": true });
    var text2754 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Template Text", "flex": 5, "name": "text", "region": "south", "selectOnFocus": true, "split": true, "title": "Template Text" });
    var main_panel2755 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2749, { "flex": 5, "items": description2753, "labelAlign": "top", "layout": "form", "region": "center", "split": true, "xtype": "panel" }, text2754 ], "labelAlign": "top", "labelWidth": 126 });
    this.items = main_panel2755;
    this.before_row_edit = function(record) {
      text2754.refresh();
    }
    Lino.tinymce.TextFieldTemplates.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.VotesByVotable.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 33,
  initComponent : function() {
    var user2757 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">S\u00f5nav\u00f5tja</span>", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Voter","(votes.VotesByVotable.user) The user who is voting.") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/votes/VotesByVotable/user" }) }) });
    var mail_mode2758 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Email notification mode", "forceSelection": true, "hiddenName": "mail_modeHidden", "listeners": { "render": Lino.quicktip_renderer("Email notification mode","(votes.VotesByVotable.mail_mode) ") }, "name": "mail_mode", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.notify.MailModes) });
    var workflow_buttons_disp2759 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Actions", "listeners": { "render": Lino.quicktip_renderer("Actions","(votes.VotesByVotable.workflow_buttons) ") }, "name": "workflow_buttons", "value": "<br/>" });
    var main_panel2760 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": user2757, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": mail_mode2758, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": workflow_buttons_disp2759, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel2760;
    this.before_row_edit = function(record) {
    }
    Lino.votes.VotesByVotable.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Topics.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 26,
  initComponent : function() {
    var name2764 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(courses.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2765 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(courses.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2766 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2764, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2765, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id2769 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Topics.id) ") }, "name": "id", "selectOnFocus": true });
    var main_panel2770 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2766, { "anchor": "-20", "autoHeight": true, "items": id2769, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 27, "layout": "form" });
    this.items = main_panel2770;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Topics.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.Excerpts.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 37,
  initComponent : function() {
    var excerpt_type2123 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">V\u00e4ljav\u00f5teliik</span>", "hiddenName": "excerpt_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Excerpt Type","(excerpts.Excerpts.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).") }, "name": "excerpt_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.excerpts.ExcerptTypes.detail,Lino.excerpts.ExcerptTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/excerpt_type" }) }) });
    var company2124 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Firma)</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Recipient (Organization)","(excerpts.Excerpts.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/company" }) }) });
    var contact_person2125 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Isik)</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Recipient (Person)","(excerpts.Excerpts.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/contact_person" }) }) });
    var main_2_panel2126 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2124, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2125, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 225, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2129 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": excerpt_type2123, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel2126 ], "labelAlign": "top", "labelWidth": 117, "layout": "form" });
    this.items = main_panel2129;
    this.before_row_edit = function(record) {
      excerpt_type2123.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person2125.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      company2124.on('change',Lino.chooser_handler(contact_person2125,'company'));
      Lino.excerpts.Excerpts.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.Excerpts.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.ExcerptTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 36,
  initComponent : function() {
    var name2772 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Nimetus</span>", "listeners": { "render": Lino.quicktip_renderer("Designation","(excerpts.ExcerptTypes.name) The designation of this excerpt type.\nOne field for every language.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2773 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(excerpts.ExcerptTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2774 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2772, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2773, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var content_type2777 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Model</span>", "hiddenName": "content_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Model","(excerpts.ExcerptTypes.content_type) The model that can issue printouts of this type.") }, "name": "content_type", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.gfks.ContentTypes.detail,Lino.gfks.ContentTypes.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/content_type" }) }) });
    var primary2778 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Primary", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Primary","(excerpts.ExcerptTypes.primary) Whether this is the default type to use for this model. There's at most one primary type per model. Enabling this field will automatically make the other types non-primary.") }, "name": "primary", "selectOnFocus": true });
    var certifying2779 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Tsertifitseeriv", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Certifying","(excerpts.ExcerptTypes.certifying) Whether an excerpt of this type is a unique printout.") }, "name": "certifying", "selectOnFocus": true });
    var main_2_panel2780 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": content_type2777, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": primary2778, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": certifying2779, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var build_method2784 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Build method</span>", "forceSelection": true, "hiddenName": "build_methodHidden", "listeners": { "render": Lino.quicktip_renderer("Build method","(excerpts.ExcerptTypes.build_method) See lino.modlib.printing.mixins.PrintableType.build_method.") }, "name": "build_method", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var template2785 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Template</span>", "listeners": { "render": Lino.quicktip_renderer("Template","(excerpts.ExcerptTypes.template) The main template to be used when printing an excerpt of this type.") }, "name": "template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/template" }) }) });
    var body_template2786 = new Lino.SimpleRemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Body template</span>", "listeners": { "render": Lino.quicktip_renderer("Body template","(excerpts.ExcerptTypes.body_template) The body template to be used when         rendering a printable of this type. This is a list of files         with extension `.body.html`.") }, "name": "body_template", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/body_template" }) }) });
    var main_3_panel2787 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": build_method2784, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": template2785, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": body_template2786, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2791 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2774, main_2_panel2780, main_3_panel2787 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2791;
    this.before_row_edit = function(record) {
      template2785.setContextValue('build_method', record ? record.data['build_methodHidden'] : undefined);
      template2785.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      body_template2786.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      build_method2784.on('change',Lino.chooser_handler(template2785,'build_method'));
      content_type2777.on('change',Lino.chooser_handler(template2785,'content_type'));
      content_type2777.on('change',Lino.chooser_handler(body_template2786,'content_type'));
      Lino.excerpts.ExcerptTypes.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.ExcerptTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.changes.Changes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 40,
  disable_editing: true,
  initComponent : function() {
    var time1002 = new Ext.form.DisplayField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "time", "listeners": { "render": Lino.quicktip_renderer("time","(changes.Changes.time) ") }, "name": "time", "selectOnFocus": true, "value": "<br>" });
    var user1003 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("User","(changes.Changes.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/user" }) }) });
    var type1004 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Change Type", "forceSelection": true, "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Change Type","(changes.Changes.type) ") }, "name": "type", "selectOnFocus": true, "store": Lino.changes.ChangeTypes });
    var master_disp1005 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Master</span>", "name": "master" });
    var object_disp1006 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Object</span>", "name": "object" });
    var id1007 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(changes.Changes.id) ") }, "name": "id", "selectOnFocus": true });
    var main_1_panel1008 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": time1002, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": user1003, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": type1004, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": master_disp1005, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": object_disp1006, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 6, "items": id1007, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var diff1015 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "Changes", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Changes","(changes.Changes.diff) ") }, "name": "diff", "selectOnFocus": true });
    var main_panel1016 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1008, { "flex": 83, "items": diff1015, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1016;
    this.before_row_edit = function(record) {
    }
    Lino.changes.Changes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.TicketTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 45,
  initComponent : function() {
    var id2792 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tickets.TicketTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2793 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(tickets.TicketTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2794 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(tickets.TicketTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2795 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2792, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2793, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2794, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var TicketsByType_grid2833 = new Lino.tickets.TicketsByType.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Tickets","(tickets.tickets.TicketsByType) Global list of all tickets.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.TicketsByType.grid) ] });
    var main_panel2834 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2795, TicketsByType_grid2833 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2834;
    this.before_row_edit = function(record) {
      TicketsByType_grid2833.on_master_changed();
    }
    Lino.tickets.TicketTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.CommentTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 39,
  initComponent : function() {
    var name2835 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(comments.CommentTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2836 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(comments.CommentTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2837 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2835, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2836, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id2840 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(comments.CommentTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var main_panel2841 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2837, { "anchor": "-20", "autoHeight": true, "items": id2840, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 27, "layout": "form" });
    this.items = main_panel2841;
    this.before_row_edit = function(record) {
    }
    Lino.comments.CommentTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.about.Models.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  disable_editing: true,
  initComponent : function() {
    var app_disp2843 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "app_label", "listeners": { "render": Lino.quicktip_renderer("app_label","(about.Models.app) ") }, "name": "app", "value": "<br/>" });
    var name_disp2844 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "nimi", "listeners": { "render": Lino.quicktip_renderer("name","(about.Models.name) ") }, "name": "name", "value": "<br/>" });
    var docstring_disp2845 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "docstring", "listeners": { "render": Lino.quicktip_renderer("docstring","(about.Models.docstring) ") }, "name": "docstring", "value": "<br/>" });
    var rows2846 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Rows", "listeners": { "render": Lino.quicktip_renderer("Rows","(about.Models.rows) ") }, "name": "rows" });
    var main_1_panel2847 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 31, "items": app_disp2843, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": name_disp2844, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": docstring_disp2845, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 5, "items": rows2846, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var about_FieldsByModel_grid2856 = new Lino.about.FieldsByModel.GridPanel({ "containing_panel": this, "flex": 62, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Fields","(about.about.FieldsByModel) ") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.about.FieldsByModel.grid) ] });
    var main_panel2857 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2847, about_FieldsByModel_grid2856 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2857;
    this.before_row_edit = function(record) {
      about_FieldsByModel_grid2856.on_master_changed();
    }
    Lino.about.Models.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.UploadTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 61,
  initComponent : function() {
    var name2858 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(uploads.UploadTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2859 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(uploads.UploadTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2860 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2858, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2859, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var upload_area2863 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Upload Area", "forceSelection": true, "hiddenName": "upload_areaHidden", "listeners": { "render": Lino.quicktip_renderer("Upload Area","(uploads.UploadTypes.upload_area) ") }, "name": "upload_area", "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var main_panel2864 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2860, { "anchor": "-20", "autoHeight": true, "items": upload_area2863, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel2864;
    this.before_row_edit = function(record) {
    }
    Lino.uploads.UploadTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Rooms.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 13,
  initComponent : function() {
    var id2866 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Rooms.id) ") }, "name": "id", "selectOnFocus": true });
    var name2867 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(cal.Rooms.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2868 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(cal.Rooms.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2869 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2866, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2867, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2868, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2873 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organisatsioon...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Responsible</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Responsible","(cal.Rooms.company) Pointer to lino_xl.lib.contacts.models.Company.") }, "name": "company", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Companies.detail,Lino.contacts.Companies.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/company" }) }) });
    var contact_person2874 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Inimene...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kontaktisik</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Contact person","(cal.Rooms.contact_person) Pointer to lino_xl.lib.contacts.models.Person.") }, "name": "contact_person", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Persons.detail,Lino.contacts.Persons.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/contact_person" }) }) });
    var main_2_panel2875 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2873, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2874, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2878 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 41, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var cal_EntriesByRoom_grid2919 = new Lino.cal.EntriesByRoom.GridPanel({ "containing_panel": this, "flex": 41, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("events","(cal.cal.EntriesByRoom) Displays the Events at a given Room.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.cal.EntriesByRoom.grid) ] });
    var main_panel2920 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2869, main_2_panel2875, description2878, cal_EntriesByRoom_grid2919 ], "labelAlign": "top", "labelWidth": 108, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2920;
    this.before_row_edit = function(record) {
      contact_person2874.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2878.refresh();
      cal_EntriesByRoom_grid2919.on_master_changed();
    }
    this.onRender = function(ct, position) {
      company2873.on('change',Lino.chooser_handler(contact_person2874,'company'));
      Lino.cal.Rooms.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.cal.Rooms.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.CommentTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 39,
  initComponent : function() {
    var id2921 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(comments.CommentTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2922 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Designation","(comments.CommentTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2923 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Designation (et)","(comments.CommentTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2924 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2921, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2922, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2923, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var comments_CommentsByType_htmlbox2928 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "flex": 75, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "listeners": { "render": Lino.quicktip_renderer("Comments","(comments.CommentTypes.comments_CommentsByType) ") }, "master_panel": this, "name": "comments_CommentsByType", "title": "Comments", "tools": [ Lino.show_in_own_window_button(Lino.comments.CommentsByType.grid) ], "value": "<br/>" });
    var main_panel2929 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2924, comments_CommentsByType_htmlbox2928 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2929;
    this.before_row_edit = function(record) {
      comments_CommentsByType_htmlbox2928.refresh();
    }
    Lino.comments.CommentTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Tickets.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 43,
  initComponent : function() {
    var summary1021 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Summary</span>", "listeners": { "render": Lino.quicktip_renderer("Summary","(tickets.Tickets.summary) Short summary of the problem.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var end_user1022 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Partner...", "fieldLabel": "End user", "hiddenName": "end_userHidden", "listeners": { "render": Lino.quicktip_renderer("End user","(tickets.Tickets.end_user) ") }, "name": "end_user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.contacts.Partners.detail,Lino.contacts.Partners.insert)}, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/end_user" }) }) });
    var main_panel1023 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": summary1021, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": end_user1022, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel1023;
    this.before_row_edit = function(record) {
    }
    Lino.tickets.Tickets.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.EnrolmentsByPupil.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 28,
  initComponent : function() {
    var course2930 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "courseHidden", "listeners": { "render": Lino.quicktip_renderer("Activity","(courses.EnrolmentsByPupil.course) ") }, "name": "course", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.courses.Activities.detail,Lino.courses.Activities.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByPupil/course" }) }) });
    var remark2931 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("Remark","(courses.EnrolmentsByPupil.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var request_date2932 = new Lino.DateField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Date of request", "listeners": { "render": Lino.quicktip_renderer("Date of request","(courses.EnrolmentsByPupil.request_date) ") }, "name": "request_date", "selectOnFocus": true });
    var user2933 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Author","(courses.EnrolmentsByPupil.user) ") }, "name": "user", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.users.Users.detail,Lino.users.Users.insert)}, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByPupil/user" }) }) });
    var main_3_panel2934 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": request_date2932, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 60, "items": user2933, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2937 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": course2930, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": remark2931, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel2934 ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel2937;
    this.before_row_edit = function(record) {
      course2930.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course2930.setContextValue('request_date', record ? record.data['request_date'] : undefined);
    }
    this.onRender = function(ct, position) {
      request_date2932.on('change',Lino.chooser_handler(course2930,'request_date'));
      Lino.courses.EnrolmentsByPupil.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.EnrolmentsByPupil.InsertFormPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Users.verify = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.Users.verify_ActionFormPanel({});
});
Lino.users.Users.change_password = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.Users.change_password_ActionFormPanel({});
});
Lino.users.AllUsers.send_welcome_email = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.AllUsers.send_welcome_email_ActionFormPanel({});
});
Lino.users.NewUsers.send_welcome_email = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.NewUsers.send_welcome_email_ActionFormPanel({});
});
Lino.courses.Activities.print_presence_sheet_html = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Activities.print_presence_sheet_html_ActionFormPanel({});
});
Lino.courses.Activities.print_presence_sheet = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Activities.print_presence_sheet_ActionFormPanel({});
});

// js_render_GridPanel_class countries.Countries
Lino.countries.Countries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/countries/Countries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/countries/Countries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/countries/Countries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Riigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "isocode" }, { "name": "short_code" }, { "name": "iso3" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 1,
  ls_id_property : "isocode",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.Countries.detail;
    this.ls_insert_handler = Lino.countries.Countries.insert;
    var ww = this.containing_window;
    var name3774 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3775 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var isocode3776 = new Ext.form.TextField({ "allowBlank": false, "boxMinWidth": Lino.chars2width(4), "maxLength": 4, "selectOnFocus": true });
    var short_code3777 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(4), "hidden": true, "maxLength": 4, "selectOnFocus": true });
    var iso33778 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(3), "hidden": true, "maxLength": 3, "selectOnFocus": true });
    var mobile_item_disp3779 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3780 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3781 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3782 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name3774, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(countries.Countries.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et3775, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(countries.Countries.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "isocode", "editable": true, "editor": isocode3776, "filter": { "type": "string" }, "header": "ISO code", "sortable": true, "tooltip": "(countries.Countries.isocode)         The two-letter code for this country as defined by ISO 3166-1.\n        For countries that no longer exist it may be a 4-letter code.", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "short_code", "editable": true, "editor": short_code3777, "filter": { "type": "string" }, "header": "Short code", "hidden": true, "sortable": true, "tooltip": "(countries.Countries.short_code) A short abbreviation for regional usage. Obsolete.", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "iso3", "editable": true, "editor": iso33778, "filter": { "type": "string" }, "header": "ISO-3 code", "hidden": true, "sortable": true, "tooltip": "(countries.Countries.iso3) The three-letter code for this country as defined by ISO 3166-1.", "width": Lino.chars2width(5) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.Countries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.Countries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(countries.Countries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(countries.Countries.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.countries.Countries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.Countries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Countries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Countries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.Countries.insertPanel = Ext.extend(Lino.countries.Countries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/countries/Countries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.Countries.detail;
    this.ls_insert_handler = Lino.countries.Countries.insert;
    Lino.countries.Countries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.Countries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.countries.Countries.insertPanel(p);
});
Lino.countries.Countries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Countries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Countries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.Countries.detailPanel = Ext.extend(Lino.countries.Countries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/countries/Countries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.Countries.detail;
    this.ls_insert_handler = Lino.countries.Countries.insert;
    Lino.countries.Countries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.Countries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.Countries.detailPanel(p);
});
Lino.countries.Countries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Countries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.Countries.GridPanel(p);
});
Lino.countries.Countries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Countries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class countries.Places
Lino.countries.Places.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/countries/Places",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/countries/Places','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/countries/Places','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Asumid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "country" }, 'countryHidden', { "name": "name" }, { "name": "name_et" }, { "name": "type" }, 'typeHidden', { "name": "zip_code" }, { "name": "parent" }, 'parentHidden', { "name": "id", "type": "int" }, { "name": "children_summary" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 2,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.Places.detail;
    this.ls_insert_handler = Lino.countries.Places.insert;
    var ww = this.containing_window;
    var country3784 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Riik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/country" }) }) });
    var name3785 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3786 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var type3787 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/type" }) }) });
    var zip_code3788 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(8), "maxLength": 8, "selectOnFocus": true });
    var parent3789 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/parent" }) }) });
    var id3790 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var children_summary_disp3791 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3792 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3793 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3794 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3795 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      type3787.setContextValue('country', record ? record.data['countryHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      country3784.on('change',Lino.chooser_handler(type3787,'country'));
      Lino.countries.Places.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "country", "editable": true, "editor": country3784, "filter": { "type": "string" }, "header": "Riik", "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(countries.Places.country) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name3785, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(countries.Places.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et3786, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(countries.Places.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "type", "editable": true, "editor": type3787, "filter": { "type": "string" }, "header": "Asumiliik", "sortable": false, "tooltip": "(countries.Places.type) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "zip_code", "editable": true, "editor": zip_code3788, "filter": { "type": "string" }, "header": "zip code", "sortable": true, "tooltip": "(countries.Places.zip_code) ", "width": Lino.chars2width(10) }, { "colIndex": 5, "dataIndex": "parent", "editable": true, "editor": parent3789, "filter": { "type": "string" }, "header": "Part of", "renderer": Lino.fk_renderer('parentHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(countries.Places.parent) The superordinate geographic place of which this place is a part.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id3790, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(countries.Places.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(countries.Places.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.Places.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.Places.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(countries.Places.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(countries.Places.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.countries.Places.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.Places.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Places.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Places.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.Places.insertPanel = Ext.extend(Lino.countries.Places.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/countries/Places",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.Places.detail;
    this.ls_insert_handler = Lino.countries.Places.insert;
    Lino.countries.Places.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.Places.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.countries.Places.insertPanel(p);
});
Lino.countries.Places.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Places.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Places.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Places.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.Places.detailPanel = Ext.extend(Lino.countries.Places.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/countries/Places",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.Places.detail;
    this.ls_insert_handler = Lino.countries.Places.insert;
    Lino.countries.Places.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.Places.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.Places.detailPanel(p);
});
Lino.countries.Places.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.Places.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.Places.GridPanel(p);
});
Lino.countries.Places.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/Places", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class system.SiteConfigs
Lino.system.SiteConfigs.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/system/SiteConfigs",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/system/SiteConfigs','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/system/SiteConfigs','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": true, "itemId": "do_build", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Rebuild the site cache.\nThis action is available on About.") }, "menu_item_text": "Rebuild site cache", "overflowText": "Rebuild site cache", "panel_btn_handler": Lino.row_action_handler('do_build','GET',null), "text": "Rebuild site cache" } ],
  cell_edit : true,
  title : "Site configurations",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 18,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "default_build_method" }, 'default_build_methodHidden', { "dateFormat": "d.m.Y", "name": "simulate_today", "type": "date" }, { "name": "site_company" }, 'site_companyHidden', { "name": "next_partner_id", "type": "int", "useNull": true }, { "name": "default_event_type" }, 'default_event_typeHidden', { "name": "site_calendar" }, 'site_calendarHidden', { "name": "max_auto_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "hide_events_before", "type": "date" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 3,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.system.SiteConfigs.detail;
    var ww = this.containing_window;
    var id3797 = new Ext.form.NumberField({ "selectOnFocus": true });
    var default_build_method3798 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var simulate_today3799 = new Lino.DateField({ "selectOnFocus": true });
    var site_company3800 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/system/SiteConfigs/site_company" }) }) });
    var next_partner_id3801 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var default_event_type3802 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/system/SiteConfigs/default_event_type" }) }) });
    var site_calendar3803 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kalender...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/system/SiteConfigs/site_calendar" }) }) });
    var max_auto_events3804 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 72 });
    var hide_events_before3805 = new Lino.DateField({ "selectOnFocus": true });
    var mobile_item_disp3806 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3807 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3808 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3809 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3797, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(system.SiteConfigs.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "default_build_method", "editable": true, "editor": default_build_method3798, "filter": { "type": "string" }, "header": "Default build method", "sortable": false, "tooltip": "(system.SiteConfigs.default_build_method) The default build method to use when rendering printable documents.", "width": Lino.chars2width(24) }, { "colIndex": 2, "dataIndex": "simulate_today", "editable": true, "editor": simulate_today3799, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Simulated date", "sortable": true, "tooltip": "(system.SiteConfigs.simulate_today) A constant user-defined date to be substituted as current\nsystem date.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 3, "dataIndex": "site_company", "editable": true, "editor": site_company3800, "filter": { "type": "string" }, "header": "Site owner", "renderer": Lino.fk_renderer('site_companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(system.SiteConfigs.site_company) The organisation who runs this site.  This is used e.g. when\nprinting your address in certain documents or reports.  Or\nnewly created partners inherit the country of the site owner.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "next_partner_id", "editable": true, "editor": next_partner_id3801, "filter": { "type": "numeric" }, "format": "0", "header": "Next partner id", "sortable": true, "tooltip": "(system.SiteConfigs.next_partner_id) The next automatic id for any new partner.", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "default_event_type", "editable": true, "editor": default_event_type3802, "filter": { "type": "string" }, "header": "Default Event Type", "renderer": Lino.fk_renderer('default_event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(system.SiteConfigs.default_event_type) The default type of events on this site.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "site_calendar", "editable": true, "editor": site_calendar3803, "filter": { "type": "string" }, "header": "Site Calendar", "renderer": Lino.fk_renderer('site_calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(system.SiteConfigs.site_calendar) The default calendar of this site.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 7, "dataIndex": "max_auto_events", "editable": true, "editor": max_auto_events3804, "filter": { "type": "numeric" }, "format": "0", "header": "Max automatic events", "sortable": true, "tooltip": "(system.SiteConfigs.max_auto_events) Maximum number of automatic events to be generated.", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "hide_events_before", "editable": true, "editor": hide_events_before3805, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Hide events before", "sortable": true, "tooltip": "(system.SiteConfigs.hide_events_before) If this is specified, certain tables show only \nevents after the given date.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(system.SiteConfigs.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(system.SiteConfigs.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(system.SiteConfigs.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(system.SiteConfigs.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.system.SiteConfigs.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.system.SiteConfigs.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.SiteConfigs.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.SiteConfigs.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.SiteConfigs.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.SiteConfigs.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.SiteConfigs.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.system.SiteConfigs.detailPanel = Ext.extend(Lino.system.SiteConfigs.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "do_build", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Rebuild the site cache.\nThis action is available on About.") }, "menu_item_text": "Rebuild site cache", "overflowText": "Rebuild site cache", "panel_btn_handler": Lino.row_action_handler('do_build','GET',null), "text": "Rebuild site cache" } ],
  ls_url: "/system/SiteConfigs",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.system.SiteConfigs.detail;
    Lino.system.SiteConfigs.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.system.SiteConfigs.detail = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.system.SiteConfigs.detailPanel(p);
});
Lino.system.SiteConfigs.grid = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.system.SiteConfigs.GridPanel(p);
});
Lino.system.SiteConfigs.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.SiteConfigs.do_build = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/SiteConfigs", "GET", pk, "do_build", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.Partners
Lino.contacts.Partners.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/Partners",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/Partners','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/Partners','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Partnerid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 31,
  ls_store_fields : [ { "name": "name" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "remarks" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 29,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Partners.detail;
    this.ls_insert_handler = Lino.contacts.Partners.insert;
    var ww = this.containing_window;
    var name3811 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var email3812 = new Ext.form.TextField({ "maxLength": 254, "selectOnFocus": true });
    var language3813 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url3814 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone3815 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm3816 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax3817 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country3818 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Partners/country" }) }) });
    var city3819 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Partners/city" }) }) });
    var zip_code3820 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region3821 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Partners/region" }) }) });
    var addr13822 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix3823 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street3824 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no3825 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box3826 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr23827 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks3828 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var name_column_disp3829 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3830 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3831 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3832 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3833 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp3834 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp3835 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var id3836 = new Ext.form.NumberField({ "selectOnFocus": true });
    this.before_row_edit = function(record) {
      city3819.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city3819.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region3821.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks3828.refresh();
    };
    this.onRender = function(ct, position) {
      country3818.on('change',Lino.chooser_handler(city3819,'country'));
      region3821.on('change',Lino.chooser_handler(city3819,'region'));
      country3818.on('change',Lino.chooser_handler(region3821,'country'));
      Lino.contacts.Partners.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name3811, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(contacts.Partners.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "email", "editable": true, "editor": email3812, "filter": { "type": "string" }, "header": "e-mail address", "sortable": true, "tooltip": "(contacts.Partners.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "language", "editable": true, "editor": language3813, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "url", "editable": true, "editor": url3814, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.url) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "phone", "editable": true, "editor": phone3815, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "gsm", "editable": true, "editor": gsm3816, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "fax", "editable": true, "editor": fax3817, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "country", "editable": true, "editor": country3818, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(contacts.Partners.country) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "city", "editable": true, "editor": city3819, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.Partners.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "zip_code", "editable": true, "editor": zip_code3820, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 10, "dataIndex": "region", "editable": true, "editor": region3821, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.Partners.region) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "addr1", "editable": true, "editor": addr13822, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 12, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix3823, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 13, "dataIndex": "street", "editable": true, "editor": street3824, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street_no", "editable": true, "editor": street_no3825, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 15, "dataIndex": "street_box", "editable": true, "editor": street_box3826, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 16, "dataIndex": "addr2", "editable": true, "editor": addr23827, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(contacts.Partners.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "remarks", "editable": true, "editor": remarks3828, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.name_column) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 24, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(contacts.Partners.address_column) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 25, "dataIndex": "id", "editable": true, "editor": id3836, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(contacts.Partners.id) ", "width": Lino.chars2width(6) } ];
    Lino.contacts.Partners.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Partners.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.Partners.insertPanel = Ext.extend(Lino.contacts.Partners.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/contacts/Partners",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Partners.detail;
    this.ls_insert_handler = Lino.contacts.Partners.insert;
    Lino.contacts.Partners.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Partners.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.contacts.Partners.insertPanel(p);
});
Lino.contacts.Partners.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.Partners.detailPanel = Ext.extend(Lino.contacts.Partners.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/contacts/Partners",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Partners.detail;
    this.ls_insert_handler = Lino.contacts.Partners.insert;
    Lino.contacts.Partners.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Partners.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.Partners.detailPanel(p);
});
Lino.contacts.Partners.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.contacts.Partners.ParamsPanel({});
  return new Lino.contacts.Partners.GridPanel(p);
});
Lino.contacts.Partners.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Partners.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Partners", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.Persons
Lino.contacts.Persons.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/Persons",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/Persons','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/Persons','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Inimesed",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 40,
  ls_store_fields : [ { "name": "name_column" }, { "name": "address_column" }, { "name": "email" }, { "name": "phone" }, { "name": "gsm" }, { "name": "id", "type": "int" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "first_name" }, { "name": "middle_name" }, { "name": "last_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Persons.detail;
    this.ls_insert_handler = Lino.contacts.Persons.insert;
    var ww = this.containing_window;
    var name_column_disp449 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var address_column_disp450 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var email451 = new Ext.form.TextField({ "maxLength": 254, "selectOnFocus": true });
    var phone452 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var gsm453 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id454 = new Ext.form.NumberField({ "selectOnFocus": true });
    var language455 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url456 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax457 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country458 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Persons/country" }) }) });
    var city459 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Persons/city" }) }) });
    var zip_code460 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region461 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Persons/region" }) }) });
    var addr1462 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix463 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street464 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no465 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box466 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr2467 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name468 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks469 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title470 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var first_name471 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name472 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var last_name473 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender474 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date475 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private476 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mobile_item_disp477 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp478 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp479 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp480 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp481 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp482 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city459.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city459.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region461.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks469.refresh();
    };
    this.onRender = function(ct, position) {
      country458.on('change',Lino.chooser_handler(city459,'country'));
      region461.on('change',Lino.chooser_handler(city459,'region'));
      country458.on('change',Lino.chooser_handler(region461,'country'));
      Lino.contacts.Persons.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name_column", "editable": false, "header": "Nimi", "sortable": false, "tooltip": "(contacts.Persons.name_column) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "address_column", "editable": false, "header": "Aadres", "sortable": false, "tooltip": "(contacts.Persons.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "email", "editable": true, "editor": email451, "filter": { "type": "string" }, "header": "e-mail address", "sortable": true, "tooltip": "(contacts.Persons.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "phone", "editable": true, "editor": phone452, "filter": { "type": "string" }, "header": "Phone", "sortable": true, "tooltip": "(contacts.Persons.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "gsm", "editable": true, "editor": gsm453, "filter": { "type": "string" }, "header": "GSM", "sortable": true, "tooltip": "(contacts.Persons.gsm) The primary mobile phone number.", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id454, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(contacts.Persons.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language455, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(contacts.Persons.language) The language to use when communicating with this partner.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url456, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "fax", "editable": true, "editor": fax457, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "country", "editable": true, "editor": country458, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(contacts.Persons.country) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "city", "editable": true, "editor": city459, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.Persons.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "zip_code", "editable": true, "editor": zip_code460, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 12, "dataIndex": "region", "editable": true, "editor": region461, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.Persons.region) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "addr1", "editable": true, "editor": addr1462, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix463, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "street", "editable": true, "editor": street464, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_no", "editable": true, "editor": street_no465, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 17, "dataIndex": "street_box", "editable": true, "editor": street_box466, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "addr2", "editable": true, "editor": addr2467, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "name", "editable": true, "editor": name468, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 20, "dataIndex": "remarks", "editable": true, "editor": remarks469, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 21, "dataIndex": "title", "editable": true, "editor": title470, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "first_name", "editable": true, "editor": first_name471, "filter": { "type": "string" }, "header": "Eesnimi", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "middle_name", "editable": true, "editor": middle_name472, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "last_name", "editable": true, "editor": last_name473, "filter": { "type": "string" }, "header": "Perenimi", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "gender", "editable": true, "editor": gender474, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 26, "dataIndex": "birth_date", "editable": true, "editor": birth_date475, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(contacts.Persons.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 27, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.age) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(contacts.Persons.mti_navigator) ", "width": Lino.chars2width(31) } ];
    Lino.contacts.Persons.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Persons.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.Persons.insertPanel = Ext.extend(Lino.contacts.Persons.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/contacts/Persons",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Persons.detail;
    this.ls_insert_handler = Lino.contacts.Persons.insert;
    Lino.contacts.Persons.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Persons.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.contacts.Persons.insertPanel(p);
});
Lino.contacts.Persons.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.Persons.detailPanel = Ext.extend(Lino.contacts.Persons.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/contacts/Persons",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Persons.detail;
    this.ls_insert_handler = Lino.contacts.Persons.insert;
    Lino.contacts.Persons.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Persons.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.Persons.detailPanel(p);
});
Lino.contacts.Persons.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.contacts.Persons.ParamsPanel({});
  return new Lino.contacts.Persons.GridPanel(p);
});
Lino.contacts.Persons.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Persons.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Persons", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.CompanyTypes
Lino.contacts.CompanyTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/CompanyTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/CompanyTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/CompanyTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Organisatsiooniliiged",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "abbr" }, { "name": "abbr_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 9,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var name3838 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3839 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id3840 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var abbr3841 = new Ext.form.TextField({ "hidden": true, "maxLength": 30, "selectOnFocus": true });
    var abbr_et3842 = new Ext.form.TextField({ "hidden": true, "maxLength": 30, "selectOnFocus": true });
    var mobile_item_disp3843 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3844 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3845 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3846 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name3838, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(contacts.CompanyTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et3839, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(contacts.CompanyTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id3840, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(contacts.CompanyTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "abbr", "editable": true, "editor": abbr3841, "filter": { "type": "string" }, "header": "Abbreviation", "hidden": true, "sortable": true, "tooltip": "(contacts.CompanyTypes.abbr) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "abbr_et", "editable": true, "editor": abbr_et3842, "filter": { "type": "string" }, "header": "Abbreviation (et)", "hidden": true, "sortable": true, "tooltip": "(contacts.CompanyTypes.abbr_et) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.CompanyTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.CompanyTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.CompanyTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.CompanyTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.contacts.CompanyTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.CompanyTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompanyTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompanyTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompanyTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompanyTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompanyTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompanyTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompanyTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompanyTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompanyTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompanyTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompanyTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompanyTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.CompanyTypes.GridPanel(p);
});

// js_render_GridPanel_class contacts.Companies
Lino.contacts.Companies.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/Companies",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/Companies','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/Companies','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Organisatsioonid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 38,
  ls_store_fields : [ { "name": "name_column" }, { "name": "address_column" }, { "name": "email" }, { "name": "phone" }, { "name": "gsm" }, { "name": "id", "type": "int" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "parent" }, 'parentHidden', { "name": "prefix" }, { "name": "type" }, 'typeHidden', { "name": "private", "type": "boolean" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mti_navigator" }, { "name": "children_summary" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Companies.detail;
    this.ls_insert_handler = Lino.contacts.Companies.insert;
    var ww = this.containing_window;
    var name_column_disp3848 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var address_column_disp3849 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var email3850 = new Ext.form.TextField({ "maxLength": 254, "selectOnFocus": true });
    var phone3851 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var gsm3852 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id3853 = new Ext.form.NumberField({ "selectOnFocus": true });
    var language3854 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url3855 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax3856 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country3857 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/country" }) }) });
    var city3858 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/city" }) }) });
    var zip_code3859 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region3860 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/region" }) }) });
    var addr13861 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix3862 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street3863 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no3864 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box3865 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr23866 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name3867 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks3868 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var parent3869 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/parent" }) }) });
    var prefix3870 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var type3871 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsiooniliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Companies/type" }) }) });
    var private3872 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mobile_item_disp3873 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3874 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3875 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3876 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp3877 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp3878 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city3858.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city3858.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region3860.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks3868.refresh();
    };
    this.onRender = function(ct, position) {
      country3857.on('change',Lino.chooser_handler(city3858,'country'));
      region3860.on('change',Lino.chooser_handler(city3858,'region'));
      country3857.on('change',Lino.chooser_handler(region3860,'country'));
      Lino.contacts.Companies.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name_column", "editable": false, "header": "Nimi", "sortable": false, "tooltip": "(contacts.Companies.name_column) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "address_column", "editable": false, "header": "Aadres", "sortable": false, "tooltip": "(contacts.Companies.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "email", "editable": true, "editor": email3850, "filter": { "type": "string" }, "header": "e-mail address", "sortable": true, "tooltip": "(contacts.Companies.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "phone", "editable": true, "editor": phone3851, "filter": { "type": "string" }, "header": "Phone", "sortable": true, "tooltip": "(contacts.Companies.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "gsm", "editable": true, "editor": gsm3852, "filter": { "type": "string" }, "header": "GSM", "sortable": true, "tooltip": "(contacts.Companies.gsm) The primary mobile phone number.", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id3853, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(contacts.Companies.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language3854, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(contacts.Companies.language) The language to use when communicating with this partner.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url3855, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "fax", "editable": true, "editor": fax3856, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "country", "editable": true, "editor": country3857, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(contacts.Companies.country) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "city", "editable": true, "editor": city3858, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.Companies.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "zip_code", "editable": true, "editor": zip_code3859, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 12, "dataIndex": "region", "editable": true, "editor": region3860, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.Companies.region) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "addr1", "editable": true, "editor": addr13861, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix3862, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "street", "editable": true, "editor": street3863, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_no", "editable": true, "editor": street_no3864, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 17, "dataIndex": "street_box", "editable": true, "editor": street_box3865, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "addr2", "editable": true, "editor": addr23866, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "name", "editable": true, "editor": name3867, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 20, "dataIndex": "remarks", "editable": true, "editor": remarks3868, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 21, "dataIndex": "parent", "editable": true, "editor": parent3869, "filter": { "type": "string" }, "header": "Parent", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(contacts.Companies.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "prefix", "editable": true, "editor": prefix3870, "filter": { "type": "string" }, "header": "Name prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.Companies.prefix) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "type", "editable": true, "editor": type3871, "filter": { "type": "string" }, "header": "Organisatsiooniliik", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.type) Pointer to the CompanyType.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(contacts.Companies.children_summary) ", "width": Lino.chars2width(31) } ];
    Lino.contacts.Companies.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Companies.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.Companies.insertPanel = Ext.extend(Lino.contacts.Companies.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/contacts/Companies",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Companies.detail;
    this.ls_insert_handler = Lino.contacts.Companies.insert;
    Lino.contacts.Companies.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Companies.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.contacts.Companies.insertPanel(p);
});
Lino.contacts.Companies.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.Companies.detailPanel = Ext.extend(Lino.contacts.Companies.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/contacts/Companies",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.Companies.detail;
    this.ls_insert_handler = Lino.contacts.Companies.insert;
    Lino.contacts.Companies.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Companies.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.Companies.detailPanel(p);
});
Lino.contacts.Companies.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.contacts.Partners.ParamsPanel({});
  return new Lino.contacts.Companies.GridPanel(p);
});
Lino.contacts.Companies.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Companies.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Companies", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.RoleTypes
Lino.contacts.RoleTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/RoleTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/RoleTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/RoleTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Functions",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 4,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id3880 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name3881 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3882 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var mobile_item_disp3883 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3884 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3885 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3886 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3880, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(contacts.RoleTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name3881, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(contacts.RoleTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et3882, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(contacts.RoleTypes.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.RoleTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.RoleTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.RoleTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.RoleTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.contacts.RoleTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.RoleTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RoleTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RoleTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RoleTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RoleTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RoleTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RoleTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RoleTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RoleTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RoleTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RoleTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RoleTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RoleTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.RoleTypes.GridPanel(p);
});

// js_render_GridPanel_class contacts.Roles
Lino.contacts.Roles.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/Roles",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/Roles','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/Roles','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Contact Persons",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 12,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "type" }, 'typeHidden', { "name": "person" }, 'personHidden', { "name": "company" }, 'companyHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 7,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id3888 = new Ext.form.NumberField({ "selectOnFocus": true });
    var type3889 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Roles/type" }) }) });
    var person3890 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Roles/person" }) }) });
    var company3891 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/Roles/company" }) }) });
    var mobile_item_disp3892 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3893 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3894 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3895 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3888, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(contacts.Roles.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type3889, "filter": { "type": "string" }, "header": "Contact Role", "sortable": false, "tooltip": "(contacts.Roles.type) The role of this person in this company.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "person", "editable": true, "editor": person3890, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(contacts.Roles.person) The person having this role in this company.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company3891, "filter": { "type": "string" }, "header": "Organisatsioon", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(contacts.Roles.company) The company where this person has a role.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Roles.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.Roles.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.Roles.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.Roles.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.contacts.Roles.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.Roles.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Roles", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Roles.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Roles", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Roles.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Roles", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Roles.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Roles", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Roles.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Roles", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Roles.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/Roles", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.Roles.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.Roles.GridPanel(p);
});

// js_render_GridPanel_class cal.RemoteCalendars
Lino.cal.RemoteCalendars.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/RemoteCalendars",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/RemoteCalendars','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/RemoteCalendars','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Remote Calendars",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 14,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "type" }, 'typeHidden', { "name": "url_template" }, { "name": "username" }, { "name": "password" }, { "name": "readonly", "type": "boolean" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 19,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id3897 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno3898 = new Ext.form.NumberField({ "selectOnFocus": true });
    var type3899 = new Lino.ChoicesFieldElement({ "allowBlank": false, "selectOnFocus": true, "store": [ [ "local", "Local Calendar" ], [ "google", "Google Calendar" ] ], "value": "local" });
    var url_template3900 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var username3901 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var password3902 = new Ext.form.TextField({ "inputType": "password", "maxLength": 200, "selectOnFocus": true });
    var readonly3903 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var move_buttons_disp3904 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3905 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3906 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3907 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3908 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3897, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.RemoteCalendars.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno3898, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(cal.RemoteCalendars.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "type", "editable": true, "editor": type3899, "filter": { "type": "string" }, "header": "Type", "sortable": false, "tooltip": "(cal.RemoteCalendars.type) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "url_template", "editable": true, "editor": url_template3900, "filter": { "type": "string" }, "header": "URL template", "sortable": true, "tooltip": "(cal.RemoteCalendars.url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "username", "editable": true, "editor": username3901, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(cal.RemoteCalendars.username) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "password", "editable": true, "editor": password3902, "filter": { "type": "string" }, "header": "Password", "sortable": true, "tooltip": "(cal.RemoteCalendars.password) ", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "readonly", "editable": true, "filter": { "type": "boolean" }, "header": "read-only", "sortable": false, "tooltip": "(cal.RemoteCalendars.readonly) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 7, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(cal.RemoteCalendars.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.RemoteCalendars.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.RemoteCalendars.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.RemoteCalendars.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.RemoteCalendars.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.RemoteCalendars.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.RemoteCalendars.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.RemoteCalendars.GridPanel(p);
});
Lino.cal.RemoteCalendars.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RemoteCalendars.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RemoteCalendars", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.Rooms
Lino.cal.Rooms.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Rooms",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Rooms','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Rooms','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Ruumid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 15,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "description" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 13,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Rooms.detail;
    this.ls_insert_handler = Lino.cal.Rooms.insert;
    var ww = this.containing_window;
    var id3910 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name3911 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3912 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var company3913 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/company" }) }) });
    var contact_person3914 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/contact_person" }) }) });
    var contact_role3915 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Rooms/contact_role" }) }) });
    var description3916 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var mobile_item_disp3917 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3918 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3919 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3920 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person3914.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description3916.refresh();
    };
    this.onRender = function(ct, position) {
      company3913.on('change',Lino.chooser_handler(contact_person3914,'company'));
      Lino.cal.Rooms.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3910, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.Rooms.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name3911, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.Rooms.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et3912, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.Rooms.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company3913, "filter": { "type": "string" }, "header": "Responsible", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.Rooms.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "contact_person", "editable": true, "editor": contact_person3914, "filter": { "type": "string" }, "header": "Kontaktisik", "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.Rooms.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "contact_role", "editable": true, "editor": contact_role3915, "filter": { "type": "string" }, "header": "represented as", "sortable": false, "tooltip": "(cal.Rooms.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "description", "editable": true, "editor": description3916, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(cal.Rooms.description) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Rooms.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Rooms.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Rooms.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Rooms.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Rooms.insertPanel = Ext.extend(Lino.cal.Rooms.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/Rooms",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Rooms.detail;
    this.ls_insert_handler = Lino.cal.Rooms.insert;
    Lino.cal.Rooms.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Rooms.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.Rooms.insertPanel(p);
});
Lino.cal.Rooms.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Rooms.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Rooms.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Rooms.detailPanel = Ext.extend(Lino.cal.Rooms.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/Rooms",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Rooms.detail;
    this.ls_insert_handler = Lino.cal.Rooms.insert;
    Lino.cal.Rooms.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Rooms.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Rooms.detailPanel(p);
});
Lino.cal.Rooms.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Rooms.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Rooms.GridPanel(p);
});
Lino.cal.Rooms.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.AllRooms
Lino.cal.AllRooms.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/AllRooms",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/AllRooms','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/AllRooms','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Ruumid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 15,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "description" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 13,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllRooms.detail;
    this.ls_insert_handler = Lino.cal.AllRooms.insert;
    var ww = this.containing_window;
    var id3922 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name3923 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3924 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var company3925 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllRooms/company" }) }) });
    var contact_person3926 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllRooms/contact_person" }) }) });
    var contact_role3927 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllRooms/contact_role" }) }) });
    var description3928 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var mobile_item_disp3929 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3930 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3931 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3932 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person3926.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description3928.refresh();
    };
    this.onRender = function(ct, position) {
      company3925.on('change',Lino.chooser_handler(contact_person3926,'company'));
      Lino.cal.AllRooms.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3922, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.AllRooms.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name3923, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.AllRooms.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et3924, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.AllRooms.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company3925, "filter": { "type": "string" }, "header": "Responsible", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.AllRooms.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "contact_person", "editable": true, "editor": contact_person3926, "filter": { "type": "string" }, "header": "Kontaktisik", "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.AllRooms.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "contact_role", "editable": true, "editor": contact_role3927, "filter": { "type": "string" }, "header": "represented as", "sortable": false, "tooltip": "(cal.AllRooms.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "description", "editable": true, "editor": description3928, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(cal.AllRooms.description) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllRooms.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllRooms.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.AllRooms.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.AllRooms.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.AllRooms.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllRooms.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllRooms.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllRooms.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.AllRooms.insertPanel = Ext.extend(Lino.cal.Rooms.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/AllRooms",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllRooms.detail;
    this.ls_insert_handler = Lino.cal.AllRooms.insert;
    Lino.cal.AllRooms.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllRooms.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.AllRooms.insertPanel(p);
});
Lino.cal.AllRooms.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllRooms.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllRooms.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.AllRooms.detailPanel = Ext.extend(Lino.cal.Rooms.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/AllRooms",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllRooms.detail;
    this.ls_insert_handler = Lino.cal.AllRooms.insert;
    Lino.cal.AllRooms.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllRooms.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.AllRooms.detailPanel(p);
});
Lino.cal.AllRooms.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllRooms.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.AllRooms.GridPanel(p);
});
Lino.cal.AllRooms.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllRooms", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.Priorities
Lino.cal.Priorities.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Priorities",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Priorities','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Priorities','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Priorities",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 9,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "ref" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 17,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var name3934 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3935 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id3936 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref3937 = new Ext.form.TextField({ "allowBlank": false, "boxMinWidth": Lino.chars2width(1), "hidden": true, "maxLength": 1, "selectOnFocus": true });
    var mobile_item_disp3938 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3939 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3940 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3941 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name3934, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.Priorities.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et3935, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.Priorities.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id3936, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.Priorities.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "ref", "editable": true, "editor": ref3937, "filter": { "type": "string" }, "header": "ref", "hidden": true, "sortable": true, "tooltip": "(cal.Priorities.ref) ", "width": Lino.chars2width(5) }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Priorities.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Priorities.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Priorities.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.Priorities.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Priorities.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Priorities.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Priorities", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Priorities.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Priorities", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Priorities.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Priorities", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Priorities.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Priorities", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Priorities.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Priorities", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Priorities.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Priorities", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Priorities.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Priorities.GridPanel(p);
});

// js_render_GridPanel_class cal.Calendars
Lino.cal.Calendars.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Calendars",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Calendars','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Calendars','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Calendars",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "description" }, { "name": "color", "type": "int", "useNull": true }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 21,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Calendars.detail;
    this.ls_insert_handler = Lino.cal.Calendars.insert;
    var ww = this.containing_window;
    var id3943 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name3944 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3945 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var description3946 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var color3947 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true });
    var mobile_item_disp3948 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3949 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3950 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3951 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description3946.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3943, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.Calendars.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name3944, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.Calendars.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et3945, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.Calendars.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "description", "editable": true, "editor": description3946, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(cal.Calendars.description) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 4, "dataIndex": "color", "editable": true, "editor": color3947, "filter": { "type": "numeric" }, "format": "0", "header": "color", "sortable": true, "tooltip": "(cal.Calendars.color) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Calendars.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Calendars.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Calendars.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.Calendars.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Calendars.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Calendars.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Calendars.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Calendars.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Calendars.insertPanel = Ext.extend(Lino.cal.Calendars.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/Calendars",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Calendars.detail;
    this.ls_insert_handler = Lino.cal.Calendars.insert;
    Lino.cal.Calendars.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Calendars.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.Calendars.insertPanel(p);
});
Lino.cal.Calendars.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Calendars.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Calendars.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Calendars.detailPanel = Ext.extend(Lino.cal.Calendars.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/Calendars",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Calendars.detail;
    this.ls_insert_handler = Lino.cal.Calendars.insert;
    Lino.cal.Calendars.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Calendars.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Calendars.detailPanel(p);
});
Lino.cal.Calendars.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Calendars.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Calendars.GridPanel(p);
});
Lino.cal.Calendars.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Calendars", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.Subscriptions
Lino.cal.Subscriptions.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Subscriptions",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Subscriptions','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Subscriptions','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Subscriptions",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "calendar" }, 'calendarHidden', { "name": "is_hidden", "type": "boolean" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 23,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id3953 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user3954 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Subscriptions/user" }) }) });
    var calendar3955 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kalender...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Subscriptions/calendar" }) }) });
    var is_hidden3956 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var mobile_item_disp3957 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3958 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3959 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3960 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3953, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.Subscriptions.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user3954, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.Subscriptions.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "calendar", "editable": true, "editor": calendar3955, "filter": { "type": "string" }, "header": "Kalender", "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.Subscriptions.calendar) The calendar you want to subscribe to.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "is_hidden", "editable": true, "filter": { "type": "boolean" }, "header": "hidden", "sortable": false, "tooltip": "(cal.Subscriptions.is_hidden) Whether this subscription should \"\n        \"initially be displayed as a hidden calendar.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Subscriptions.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Subscriptions.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Subscriptions.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.Subscriptions.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Subscriptions.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Subscriptions.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Subscriptions", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Subscriptions.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Subscriptions", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Subscriptions.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Subscriptions", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Subscriptions.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Subscriptions", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Subscriptions.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Subscriptions", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Subscriptions.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Subscriptions", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Subscriptions.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Subscriptions.ParamsPanel({});
  return new Lino.cal.Subscriptions.GridPanel(p);
});

// js_render_GridPanel_class cal.Tasks
Lino.cal.Tasks.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Tasks",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Tasks','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Tasks','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Tasks",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 29,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "start_time" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "due_date", "type": "date" }, { "name": "due_time" }, { "name": "percent", "type": "int", "useNull": true }, { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 12,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Tasks.detail;
    this.ls_insert_handler = Lino.cal.Tasks.insert;
    var ww = this.containing_window;
    var start_date3962 = new Lino.DateField({ "selectOnFocus": true });
    var summary3963 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp3964 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id3965 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified3966 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3967 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_time3968 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user3969 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Tasks/user" }) }) });
    var owner_type3970 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Tasks/owner_type" }) }) });
    var owner_id3971 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Tasks/owner_id" }) }) });
    var description3972 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class3973 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence3974 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type3975 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var due_date3976 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var due_time3977 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var percent3978 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var state3979 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.TaskStates });
    var owner_disp3980 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp3981 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3982 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3983 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3984 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id3971.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type3970.on('change',Lino.chooser_handler(owner_id3971,'owner_type'));
      Lino.cal.Tasks.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date3962, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.Tasks.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3963, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.Tasks.summary) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.Tasks.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id3965, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "start_time", "editable": true, "editor": start_time3968, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user3969, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.Tasks.user) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_type", "editable": true, "editor": owner_type3970, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.Tasks.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner_id", "editable": true, "editor": owner_id3971, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "description", "editable": true, "editor": description3972, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.description) ", "width": Lino.chars2width(61) }, { "colIndex": 11, "dataIndex": "access_class", "editable": true, "editor": access_class3973, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 12, "dataIndex": "sequence", "editable": true, "editor": sequence3974, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 13, "dataIndex": "auto_type", "editable": true, "editor": auto_type3975, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "due_date", "editable": true, "editor": due_date3976, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Due date", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.due_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 15, "dataIndex": "due_time", "editable": true, "editor": due_time3977, "header": "Due time", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.due_time) ", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 16, "dataIndex": "percent", "editable": true, "editor": percent3978, "filter": { "type": "numeric" }, "format": "0", "header": "Duration value", "hidden": true, "sortable": true, "tooltip": "(cal.Tasks.percent) ", "width": Lino.chars2width(6) }, { "colIndex": 17, "dataIndex": "state", "editable": true, "editor": state3979, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.state) The state of this Task. one of TaskStates.", "width": Lino.chars2width(13) }, { "colIndex": 18, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.Tasks.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Tasks.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Tasks.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Tasks.insertPanel = Ext.extend(Lino.cal.Tasks.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/Tasks",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Tasks.detail;
    this.ls_insert_handler = Lino.cal.Tasks.insert;
    Lino.cal.Tasks.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Tasks.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.Tasks.insertPanel(p);
});
Lino.cal.Tasks.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Tasks.detailPanel = Ext.extend(Lino.cal.Tasks.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/Tasks",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Tasks.detail;
    this.ls_insert_handler = Lino.cal.Tasks.insert;
    Lino.cal.Tasks.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Tasks.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Tasks.detailPanel(p);
});
Lino.cal.Tasks.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Tasks.ParamsPanel({});
  return new Lino.cal.Tasks.GridPanel(p);
});
Lino.cal.Tasks.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Tasks.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Tasks", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyTasks
Lino.cal.MyTasks.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyTasks",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyTasks','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyTasks','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "My tasks",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 5,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 12,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyTasks.detail;
    this.ls_insert_handler = Lino.cal.MyTasks.insert;
    var ww = this.containing_window;
    var start_date3986 = new Lino.DateField({ "selectOnFocus": true });
    var summary3987 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp3988 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date3986, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.MyTasks.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3987, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.MyTasks.summary) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyTasks.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.MyTasks.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyTasks.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyTasks.insertPanel = Ext.extend(Lino.cal.Tasks.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyTasks",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyTasks.detail;
    this.ls_insert_handler = Lino.cal.MyTasks.insert;
    Lino.cal.MyTasks.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyTasks.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyTasks.insertPanel(p);
});
Lino.cal.MyTasks.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyTasks.detailPanel = Ext.extend(Lino.cal.Tasks.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/MyTasks",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyTasks.detail;
    this.ls_insert_handler = Lino.cal.MyTasks.insert;
    Lino.cal.MyTasks.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyTasks.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyTasks.detailPanel(p);
});
Lino.cal.MyTasks.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Tasks.ParamsPanel({});
  return new Lino.cal.MyTasks.GridPanel(p);
});
Lino.cal.MyTasks.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyTasks.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyTasks", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.GuestRoles
Lino.cal.GuestRoles.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/GuestRoles",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/GuestRoles','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/GuestRoles','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Guest Roles",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 20,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestRoles.detail;
    this.ls_insert_handler = Lino.cal.GuestRoles.insert;
    var ww = this.containing_window;
    var id3990 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name3991 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et3992 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var mobile_item_disp3993 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3994 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3995 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3996 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3990, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.GuestRoles.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name3991, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.GuestRoles.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et3992, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.GuestRoles.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.GuestRoles.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.GuestRoles.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.GuestRoles.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.GuestRoles.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.GuestRoles.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestRoles.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestRoles.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestRoles.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestRoles.insertPanel = Ext.extend(Lino.cal.GuestRoles.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/GuestRoles",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestRoles.detail;
    this.ls_insert_handler = Lino.cal.GuestRoles.insert;
    Lino.cal.GuestRoles.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestRoles.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.GuestRoles.insertPanel(p);
});
Lino.cal.GuestRoles.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestRoles.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestRoles.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestRoles.detailPanel = Ext.extend(Lino.cal.GuestRoles.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/GuestRoles",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestRoles.detail;
    this.ls_insert_handler = Lino.cal.GuestRoles.insert;
    Lino.cal.GuestRoles.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestRoles.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.GuestRoles.detailPanel(p);
});
Lino.cal.GuestRoles.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestRoles.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.GuestRoles.GridPanel(p);
});
Lino.cal.GuestRoles.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestRoles", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.Guests
Lino.cal.Guests.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Guests",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Guests','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Guests','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Kohalolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "remark" }, { "name": "event" }, 'eventHidden', { "name": "id", "type": "int" }, { "name": "state" }, 'stateHidden', { "name": "event_summary" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Guests.detail;
    this.ls_insert_handler = Lino.cal.Guests.insert;
    var ww = this.containing_window;
    var partner3998 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/partner" }) }) });
    var role3999 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/role" }) }) });
    var workflow_buttons_disp4000 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var remark4001 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event4002 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni event...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Guests/event" }) }) });
    var id4003 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var state4004 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var event_summary_disp4005 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4006 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4007 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4008 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner3998, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(cal.Guests.partner) The partner to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "role", "editable": true, "editor": role3999, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.Guests.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.Guests.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark4001, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(cal.Guests.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "event", "editable": true, "editor": event4002, "filter": { "type": "string" }, "header": "event", "renderer": Lino.fk_renderer('eventHidden','Lino.cal.OneEvent.detail'), "sortable": false, "tooltip": "(cal.Guests.event) The calendar event to which this presence applies.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id4003, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.Guests.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "state", "editable": true, "editor": state4004, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.Guests.state) The state of this presence.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "event_summary", "editable": false, "header": "Event", "hidden": true, "sortable": false, "tooltip": "(cal.Guests.event_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Guests.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Guests.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Guests.overview) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Guests.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Guests.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Guests.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/Guests",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Guests.detail;
    this.ls_insert_handler = Lino.cal.Guests.insert;
    Lino.cal.Guests.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Guests.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.Guests.insertPanel(p);
});
Lino.cal.Guests.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Guests.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/Guests",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Guests.detail;
    this.ls_insert_handler = Lino.cal.Guests.insert;
    Lino.cal.Guests.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Guests.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Guests.detailPanel(p);
});
Lino.cal.Guests.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.Guests.GridPanel(p);
});
Lino.cal.Guests.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Guests.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Guests", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.AllGuests
Lino.cal.AllGuests.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/AllGuests",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/AllGuests','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/AllGuests','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Kohalolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "remark" }, { "name": "event" }, 'eventHidden', { "name": "id", "type": "int" }, { "name": "state" }, 'stateHidden', { "name": "event_summary" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllGuests.detail;
    this.ls_insert_handler = Lino.cal.AllGuests.insert;
    var ww = this.containing_window;
    var partner4010 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllGuests/partner" }) }) });
    var role4011 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllGuests/role" }) }) });
    var workflow_buttons_disp4012 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var remark4013 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event4014 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni event...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllGuests/event" }) }) });
    var id4015 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var state4016 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var event_summary_disp4017 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4018 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4019 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4020 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner4010, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(cal.AllGuests.partner) The partner to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "role", "editable": true, "editor": role4011, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.AllGuests.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.AllGuests.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark4013, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(cal.AllGuests.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "event", "editable": true, "editor": event4014, "filter": { "type": "string" }, "header": "event", "renderer": Lino.fk_renderer('eventHidden','Lino.cal.OneEvent.detail'), "sortable": false, "tooltip": "(cal.AllGuests.event) The calendar event to which this presence applies.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id4015, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.AllGuests.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "state", "editable": true, "editor": state4016, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.AllGuests.state) The state of this presence.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "event_summary", "editable": false, "header": "Event", "hidden": true, "sortable": false, "tooltip": "(cal.AllGuests.event_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllGuests.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllGuests.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.AllGuests.overview) ", "width": Lino.chars2width(31) } ];
    Lino.cal.AllGuests.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllGuests.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.AllGuests.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/AllGuests",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllGuests.detail;
    this.ls_insert_handler = Lino.cal.AllGuests.insert;
    Lino.cal.AllGuests.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllGuests.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.AllGuests.insertPanel(p);
});
Lino.cal.AllGuests.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.AllGuests.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/AllGuests",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllGuests.detail;
    this.ls_insert_handler = Lino.cal.AllGuests.insert;
    Lino.cal.AllGuests.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllGuests.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.AllGuests.detailPanel(p);
});
Lino.cal.AllGuests.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.AllGuests.GridPanel(p);
});
Lino.cal.AllGuests.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllGuests.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllGuests", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyPresences
Lino.cal.MyPresences.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyPresences",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyPresences','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyPresences','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Minu kohalolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 18,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "event__start_date", "type": "date" }, { "name": "event__start_time" }, { "name": "event_summary" }, { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "remark" }, { "name": "id", "type": "int" }, { "name": "event" }, 'eventHidden', { "name": "partner" }, 'partnerHidden', { "name": "state" }, 'stateHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyPresences.detail;
    this.ls_insert_handler = Lino.cal.MyPresences.insert;
    var ww = this.containing_window;
    var event__start_date4022 = new Lino.DateField({ "disabled": true, "sortable": false });
    var event__start_time4023 = new Lino.TimeField({ "disabled": true, "sortable": false });
    var event_summary_disp4024 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var role4025 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyPresences/role" }) }) });
    var workflow_buttons_disp4026 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var remark4027 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id4028 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event4029 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni event...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyPresences/event" }) }) });
    var partner4030 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyPresences/partner" }) }) });
    var state4031 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var mobile_item_disp4032 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4033 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4034 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "event__start_date", "editable": false, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.MyPresences.event__start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "event__start_time", "editable": false, "header": "Start time", "sortable": true, "tooltip": "(cal.MyPresences.event__start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "event_summary", "editable": false, "header": "Event", "sortable": false, "tooltip": "(cal.MyPresences.event_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "role", "editable": true, "editor": role4025, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.MyPresences.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyPresences.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "remark", "editable": true, "editor": remark4027, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(cal.MyPresences.remark) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id4028, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyPresences.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "event", "editable": true, "editor": event4029, "filter": { "type": "string" }, "header": "event", "hidden": true, "renderer": Lino.fk_renderer('eventHidden','Lino.cal.OneEvent.detail'), "sortable": false, "tooltip": "(cal.MyPresences.event) The calendar event to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "partner", "editable": true, "editor": partner4030, "filter": { "type": "string" }, "header": "Partner", "hidden": true, "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(cal.MyPresences.partner) The partner to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "state", "editable": true, "editor": state4031, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyPresences.state) The state of this presence.", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyPresences.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyPresences.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.MyPresences.overview) ", "width": Lino.chars2width(31) } ];
    Lino.cal.MyPresences.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyPresences.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyPresences.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyPresences",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyPresences.detail;
    this.ls_insert_handler = Lino.cal.MyPresences.insert;
    Lino.cal.MyPresences.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyPresences.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyPresences.insertPanel(p);
});
Lino.cal.MyPresences.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyPresences.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/MyPresences",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyPresences.detail;
    this.ls_insert_handler = Lino.cal.MyPresences.insert;
    Lino.cal.MyPresences.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyPresences.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyPresences.detailPanel(p);
});
Lino.cal.MyPresences.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.MyPresences.GridPanel(p);
});
Lino.cal.MyPresences.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPresences.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPresences", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyPendingPresences
Lino.cal.MyPendingPresences.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyPendingPresences",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyPendingPresences','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyPendingPresences','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "My pending invitations",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "event__when_text" }, { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "remark" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyPendingPresences.detail;
    this.ls_insert_handler = Lino.cal.MyPendingPresences.insert;
    var ww = this.containing_window;
    var event__when_text_disp4036 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "sortable": false, "value": "<br/>" });
    var role4037 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyPendingPresences/role" }) }) });
    var workflow_buttons_disp4038 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var remark4039 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "event__when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.MyPendingPresences.event__when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "role", "editable": true, "editor": role4037, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.MyPendingPresences.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyPendingPresences.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark4039, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(cal.MyPendingPresences.remark) ", "width": Lino.chars2width(22) } ];
    Lino.cal.MyPendingPresences.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyPendingPresences.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyPendingPresences.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyPendingPresences",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyPendingPresences.detail;
    this.ls_insert_handler = Lino.cal.MyPendingPresences.insert;
    Lino.cal.MyPendingPresences.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyPendingPresences.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyPendingPresences.insertPanel(p);
});
Lino.cal.MyPendingPresences.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyPendingPresences.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/MyPendingPresences",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyPendingPresences.detail;
    this.ls_insert_handler = Lino.cal.MyPendingPresences.insert;
    Lino.cal.MyPendingPresences.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyPendingPresences.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyPendingPresences.detailPanel(p);
});
Lino.cal.MyPendingPresences.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.MyPendingPresences.GridPanel(p);
});
Lino.cal.MyPendingPresences.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyPendingPresences.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyPendingPresences", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyGuests
Lino.cal.MyGuests.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyGuests",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyGuests','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyGuests','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "My guests",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 18,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "event__start_date", "type": "date" }, { "name": "event__start_time" }, { "name": "event_summary" }, { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "remark" }, { "name": "id", "type": "int" }, { "name": "event" }, 'eventHidden', { "name": "partner" }, 'partnerHidden', { "name": "state" }, 'stateHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyGuests.detail;
    this.ls_insert_handler = Lino.cal.MyGuests.insert;
    var ww = this.containing_window;
    var event__start_date4041 = new Lino.DateField({ "disabled": true, "sortable": false });
    var event__start_time4042 = new Lino.TimeField({ "disabled": true, "sortable": false });
    var event_summary_disp4043 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var role4044 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyGuests/role" }) }) });
    var workflow_buttons_disp4045 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var remark4046 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id4047 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event4048 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni event...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyGuests/event" }) }) });
    var partner4049 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyGuests/partner" }) }) });
    var state4050 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var mobile_item_disp4051 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4052 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4053 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "event__start_date", "editable": false, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.MyGuests.event__start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "event__start_time", "editable": false, "header": "Start time", "sortable": true, "tooltip": "(cal.MyGuests.event__start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "event_summary", "editable": false, "header": "Event", "sortable": false, "tooltip": "(cal.MyGuests.event_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "role", "editable": true, "editor": role4044, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.MyGuests.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyGuests.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "remark", "editable": true, "editor": remark4046, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(cal.MyGuests.remark) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id4047, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyGuests.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "event", "editable": true, "editor": event4048, "filter": { "type": "string" }, "header": "event", "hidden": true, "renderer": Lino.fk_renderer('eventHidden','Lino.cal.OneEvent.detail'), "sortable": false, "tooltip": "(cal.MyGuests.event) The calendar event to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "partner", "editable": true, "editor": partner4049, "filter": { "type": "string" }, "header": "Partner", "hidden": true, "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(cal.MyGuests.partner) The partner to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "state", "editable": true, "editor": state4050, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyGuests.state) The state of this presence.", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyGuests.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyGuests.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.MyGuests.overview) ", "width": Lino.chars2width(31) } ];
    Lino.cal.MyGuests.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyGuests.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyGuests.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyGuests",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyGuests.detail;
    this.ls_insert_handler = Lino.cal.MyGuests.insert;
    Lino.cal.MyGuests.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyGuests.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyGuests.insertPanel(p);
});
Lino.cal.MyGuests.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyGuests.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/MyGuests",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyGuests.detail;
    this.ls_insert_handler = Lino.cal.MyGuests.insert;
    Lino.cal.MyGuests.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyGuests.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyGuests.detailPanel(p);
});
Lino.cal.MyGuests.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.MyGuests.GridPanel(p);
});
Lino.cal.MyGuests.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyGuests.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyGuests", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.EventTypes
Lino.cal.EventTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/EventTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EventTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EventTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "S\u00fcndmuseliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "attach_to_email", "type": "boolean" }, { "name": "email_template" }, { "name": "description" }, { "name": "is_appointment", "type": "boolean" }, { "name": "all_rooms", "type": "boolean" }, { "name": "locks_user", "type": "boolean" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "event_label" }, { "name": "event_label_et" }, { "name": "max_conflicting", "type": "int", "useNull": true }, { "name": "max_days", "type": "int", "useNull": true }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 15,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EventTypes.detail;
    this.ls_insert_handler = Lino.cal.EventTypes.insert;
    var ww = this.containing_window;
    var name4055 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4056 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id4057 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno4058 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var attach_to_email4059 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var email_template4060 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EventTypes/email_template" }) }) });
    var description4061 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var is_appointment4062 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var all_rooms4063 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var locks_user4064 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var start_date4065 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var event_label4066 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var event_label_et4067 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var max_conflicting4068 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var max_days4069 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var mobile_item_disp4070 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4071 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4072 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4073 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp4074 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description4061.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name4055, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.EventTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et4056, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.EventTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4057, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 3, "dataIndex": "seqno", "editable": true, "editor": seqno4058, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "attach_to_email", "editable": true, "filter": { "type": "boolean" }, "header": "Attach to email", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.attach_to_email) Whether the printable file should be attached to the email\nwhen creating an email from a mailable of this type.\n", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 5, "dataIndex": "email_template", "editable": true, "editor": email_template4060, "filter": { "type": "string" }, "header": "Email template", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.email_template) The name of the file to be used as template when creating an email from a mailable of this type.", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "description", "editable": true, "editor": description4061, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.description) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "is_appointment", "editable": true, "filter": { "type": "boolean" }, "header": "Appointment", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.is_appointment) Whether entries of this type should be considered\n\"appointments\" (i.e. whose time and place have been agreed\nupon with other users or external parties).", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 8, "dataIndex": "all_rooms", "editable": true, "filter": { "type": "boolean" }, "header": "Locks all rooms", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.all_rooms) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "locks_user", "editable": true, "filter": { "type": "boolean" }, "header": "Locks the user", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.locks_user) Whether calendar entries of this type make the user\nunavailable for other locking events at the same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "start_date", "editable": true, "editor": start_date4065, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 11, "dataIndex": "event_label", "editable": true, "editor": event_label4066, "filter": { "type": "string" }, "header": "Entry label", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.event_label) Default text for summary of new entries.", "width": Lino.chars2width(22) }, { "colIndex": 12, "dataIndex": "event_label_et", "editable": true, "editor": event_label_et4067, "filter": { "type": "string" }, "header": "Entry label (et)", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.event_label_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 13, "dataIndex": "max_conflicting", "editable": true, "editor": max_conflicting4068, "filter": { "type": "numeric" }, "format": "0", "header": "Simultaneous entries", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.max_conflicting) How many conflicting events should be tolerated.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 14, "dataIndex": "max_days", "editable": true, "editor": max_days4069, "filter": { "type": "numeric" }, "format": "0", "header": "Maximum days", "hidden": true, "sortable": true, "tooltip": "(cal.EventTypes.max_days) The maximal number of days allowed as duration.", "width": Lino.chars2width(6) }, { "colIndex": 15, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(cal.EventTypes.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.cal.EventTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EventTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EventTypes.insertPanel = Ext.extend(Lino.cal.EventTypes.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/EventTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EventTypes.detail;
    this.ls_insert_handler = Lino.cal.EventTypes.insert;
    Lino.cal.EventTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EventTypes.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.EventTypes.insertPanel(p);
});
Lino.cal.EventTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EventTypes.detailPanel = Ext.extend(Lino.cal.EventTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/cal/EventTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EventTypes.detail;
    this.ls_insert_handler = Lino.cal.EventTypes.insert;
    Lino.cal.EventTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EventTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EventTypes.detailPanel(p);
});
Lino.cal.EventTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EventTypes.GridPanel(p);
});
Lino.cal.EventTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventTypes.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventTypes", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.RecurrentEvents
Lino.cal.RecurrentEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/RecurrentEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/RecurrentEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/RecurrentEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Recurring events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "name" }, { "name": "name_et" }, { "name": "every_unit" }, 'every_unitHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "id", "type": "int" }, { "name": "start_time" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "name": "description" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 14,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.RecurrentEvents.detail;
    this.ls_insert_handler = Lino.cal.RecurrentEvents.insert;
    var ww = this.containing_window;
    var start_date4076 = new Lino.DateField({ "selectOnFocus": true });
    var end_date4077 = new Lino.DateField({ "selectOnFocus": true });
    var name4078 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4079 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var every_unit4080 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.cal.Recurrencies });
    var event_type4081 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/RecurrentEvents/event_type" }) }) });
    var id4082 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_time4083 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_time4084 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user4085 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/RecurrentEvents/user" }) }) });
    var every4086 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var monday4087 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday4088 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday4089 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday4090 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday4091 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday4092 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday4093 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events4094 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var description4095 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var mobile_item_disp4096 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4097 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4098 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4099 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var weekdays_text_disp4100 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp4101 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp4102 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4103 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description4095.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date4076, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.RecurrentEvents.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "end_date", "editable": true, "editor": end_date4077, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "sortable": true, "tooltip": "(cal.RecurrentEvents.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "name", "editable": true, "editor": name4078, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.RecurrentEvents.name) See lino.utils.mldbc.mixins.BabelNamed.name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "name_et", "editable": true, "editor": name_et4079, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.RecurrentEvents.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "every_unit", "editable": true, "editor": every_unit4080, "filter": { "type": "string" }, "header": "Korduvus", "sortable": false, "tooltip": "(cal.RecurrentEvents.every_unit) Inherited from RecurrentSet.every_unit.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "event_type", "editable": true, "editor": event_type4081, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.RecurrentEvents.event_type) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id4082, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.RecurrentEvents.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "start_time", "editable": true, "editor": start_time4083, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.RecurrentEvents.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "end_time", "editable": true, "editor": end_time4084, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.RecurrentEvents.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user4085, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.RecurrentEvents.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 10, "dataIndex": "every", "editable": true, "editor": every4086, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(cal.RecurrentEvents.every) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 18, "dataIndex": "max_events", "editable": true, "editor": max_events4094, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(cal.RecurrentEvents.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4095, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.description) ", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 24, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.what_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 27, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.RecurrentEvents.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.RecurrentEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.RecurrentEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RecurrentEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RecurrentEvents.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.RecurrentEvents.insertPanel = Ext.extend(Lino.cal.RecurrentEvents.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/RecurrentEvents",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.RecurrentEvents.detail;
    this.ls_insert_handler = Lino.cal.RecurrentEvents.insert;
    Lino.cal.RecurrentEvents.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.RecurrentEvents.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.RecurrentEvents.insertPanel(p);
});
Lino.cal.RecurrentEvents.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RecurrentEvents.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RecurrentEvents.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.RecurrentEvents.detailPanel = Ext.extend(Lino.cal.RecurrentEvents.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/RecurrentEvents",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.RecurrentEvents.detail;
    this.ls_insert_handler = Lino.cal.RecurrentEvents.insert;
    Lino.cal.RecurrentEvents.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.RecurrentEvents.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.RecurrentEvents.detailPanel(p);
});
Lino.cal.RecurrentEvents.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RecurrentEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.RecurrentEvents.ParamsPanel({});
  return new Lino.cal.RecurrentEvents.GridPanel(p);
});
Lino.cal.RecurrentEvents.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.RecurrentEvents.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/RecurrentEvents", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.Events
Lino.cal.Events.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/Events",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Events','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Events','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_text" }, { "name": "user" }, 'userHidden', { "name": "summary" }, { "name": "event_type" }, 'event_typeHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Events.detail;
    this.ls_insert_handler = Lino.cal.Events.insert;
    var ww = this.containing_window;
    var when_text_disp4105 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user4106 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/user" }) }) });
    var summary4107 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event_type4108 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/event_type" }) }) });
    var id4109 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified4110 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4111 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4112 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4113 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4114 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4115 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4116 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4117 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4118 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/company" }) }) });
    var contact_person4119 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/contact_person" }) }) });
    var contact_role4120 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/contact_role" }) }) });
    var assigned_to4121 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/assigned_to" }) }) });
    var owner_type4122 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/owner_type" }) }) });
    var owner_id4123 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/owner_id" }) }) });
    var description4124 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4125 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4126 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4127 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4128 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4129 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/room" }) }) });
    var priority4130 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/Events/priority" }) }) });
    var state4131 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4132 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4133 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4134 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4135 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4136 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4137 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4138 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4139 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4140 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4141 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4142 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4143 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4119.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4123.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4118.on('change',Lino.chooser_handler(contact_person4119,'company'));
      owner_type4122.on('change',Lino.chooser_handler(owner_id4123,'owner_type'));
      Lino.cal.Events.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.Events.when_text) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user4106, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.Events.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "summary", "editable": true, "editor": summary4107, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.Events.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "event_type", "editable": true, "editor": event_type4108, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.Events.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4109, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.Events.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.Events.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.Events.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date4112, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.Events.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time4113, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.Events.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date4114, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.Events.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time4115, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.Events.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.Events.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 12, "dataIndex": "build_method", "editable": true, "editor": build_method4117, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.Events.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 13, "dataIndex": "company", "editable": true, "editor": company4118, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.Events.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_person", "editable": true, "editor": contact_person4119, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.Events.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "contact_role", "editable": true, "editor": contact_role4120, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.Events.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4121, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.Events.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type4122, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.Events.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id4123, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.Events.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4124, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Events.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4125, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.Events.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4126, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.Events.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4127, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.Events.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.Events.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "room", "editable": true, "editor": room4129, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.Events.room) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "priority", "editable": true, "editor": priority4130, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.Events.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state4131, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.Events.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 27, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.Events.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.Events.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.Events.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.Events.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.Events.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 32, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.Events.url) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Events.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Events.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.Events.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.Events.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.Events.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.Events.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.Events.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Events.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Events.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/Events",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Events.detail;
    this.ls_insert_handler = Lino.cal.Events.insert;
    Lino.cal.Events.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Events.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.Events.insertPanel(p);
});
Lino.cal.Events.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.Events.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/Events",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.Events.detail;
    this.ls_insert_handler = Lino.cal.Events.insert;
    Lino.cal.Events.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Events.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Events.detailPanel(p);
});
Lino.cal.Events.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.Events.GridPanel(p);
});
Lino.cal.Events.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Events.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Events", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.AllEntries
Lino.cal.AllEntries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/AllEntries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/AllEntries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/AllEntries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_text" }, { "name": "user" }, 'userHidden', { "name": "summary" }, { "name": "event_type" }, 'event_typeHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllEntries.detail;
    this.ls_insert_handler = Lino.cal.AllEntries.insert;
    var ww = this.containing_window;
    var when_text_disp4145 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user4146 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/user" }) }) });
    var summary4147 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event_type4148 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/event_type" }) }) });
    var id4149 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified4150 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4151 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4152 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4153 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4154 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4155 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4156 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4157 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4158 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/company" }) }) });
    var contact_person4159 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/contact_person" }) }) });
    var contact_role4160 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/contact_role" }) }) });
    var assigned_to4161 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/assigned_to" }) }) });
    var owner_type4162 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/owner_type" }) }) });
    var owner_id4163 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/owner_id" }) }) });
    var description4164 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4165 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4166 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4167 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4168 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4169 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/room" }) }) });
    var priority4170 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/AllEntries/priority" }) }) });
    var state4171 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4172 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4173 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4174 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4175 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4176 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4177 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4178 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4179 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4180 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4181 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4182 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4183 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4159.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4163.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4158.on('change',Lino.chooser_handler(contact_person4159,'company'));
      owner_type4162.on('change',Lino.chooser_handler(owner_id4163,'owner_type'));
      Lino.cal.AllEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.AllEntries.when_text) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user4146, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.AllEntries.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "summary", "editable": true, "editor": summary4147, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.AllEntries.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "event_type", "editable": true, "editor": event_type4148, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.AllEntries.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4149, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.AllEntries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date4152, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time4153, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date4154, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time4155, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 12, "dataIndex": "build_method", "editable": true, "editor": build_method4157, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 13, "dataIndex": "company", "editable": true, "editor": company4158, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.AllEntries.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_person", "editable": true, "editor": contact_person4159, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.AllEntries.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "contact_role", "editable": true, "editor": contact_role4160, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4161, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.AllEntries.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type4162, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.AllEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id4163, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4164, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4165, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4166, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4167, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.AllEntries.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "room", "editable": true, "editor": room4169, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.AllEntries.room) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "priority", "editable": true, "editor": priority4170, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state4171, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 27, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.AllEntries.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 32, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.url) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.AllEntries.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.AllEntries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllEntries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.AllEntries.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/AllEntries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllEntries.detail;
    this.ls_insert_handler = Lino.cal.AllEntries.insert;
    Lino.cal.AllEntries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllEntries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.AllEntries.insertPanel(p);
});
Lino.cal.AllEntries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.AllEntries.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/AllEntries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.AllEntries.detail;
    this.ls_insert_handler = Lino.cal.AllEntries.insert;
    Lino.cal.AllEntries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AllEntries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.AllEntries.detailPanel(p);
});
Lino.cal.AllEntries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.AllEntries.GridPanel(p);
});
Lino.cal.AllEntries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AllEntries.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AllEntries", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.EntriesByDay
Lino.cal.EntriesByDay.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/EntriesByDay",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByDay','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByDay','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Kokku leppitud ajad t\u00e4na",
  page_length : 20,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "start_time" }, { "name": "end_time" }, { "name": "duration" }, { "name": "room" }, 'roomHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "summary" }, { "name": "owner" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 10,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByDay.detail;
    this.ls_insert_handler = Lino.cal.EntriesByDay.insert;
    var ww = this.containing_window;
    var start_time4185 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time4186 = new Lino.TimeField({ "selectOnFocus": true });
    var duration4187 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var room4188 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/room" }) }) });
    var event_type4189 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/event_type" }) }) });
    var summary4190 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var owner_disp4191 = new Ext.form.DisplayField({ "disabled": true });
    var workflow_buttons_disp4192 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4193 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4194 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4195 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4196 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date4197 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var build_time4198 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4199 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4200 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/company" }) }) });
    var contact_person4201 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/contact_person" }) }) });
    var contact_role4202 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/contact_role" }) }) });
    var user4203 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/user" }) }) });
    var assigned_to4204 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/assigned_to" }) }) });
    var owner_type4205 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/owner_type" }) }) });
    var owner_id4206 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/owner_id" }) }) });
    var description4207 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4208 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4209 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4210 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4211 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority4212 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByDay/priority" }) }) });
    var state4213 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var calendar4214 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4215 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4216 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4217 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4218 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4219 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4220 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4221 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4222 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4223 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person4201.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4206.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4200.on('change',Lino.chooser_handler(contact_person4201,'company'));
      owner_type4205.on('change',Lino.chooser_handler(owner_id4206,'owner_type'));
      Lino.cal.EntriesByDay.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_time", "editable": true, "editor": start_time4185, "header": "Start time", "sortable": true, "tooltip": "(cal.EntriesByDay.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 1, "dataIndex": "end_time", "editable": true, "editor": end_time4186, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(cal.EntriesByDay.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 2, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "sortable": false, "tooltip": "(cal.EntriesByDay.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 3, "dataIndex": "room", "editable": true, "editor": room4188, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.room) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "event_type", "editable": true, "editor": event_type4189, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "summary", "editable": true, "editor": summary4190, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.EntriesByDay.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(cal.EntriesByDay.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.EntriesByDay.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 8, "dataIndex": "id", "editable": true, "editor": id4193, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.id) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 10, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 11, "dataIndex": "start_date", "editable": true, "editor": start_date4196, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 12, "dataIndex": "end_date", "editable": true, "editor": end_date4197, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 13, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 14, "dataIndex": "build_method", "editable": true, "editor": build_method4199, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 15, "dataIndex": "company", "editable": true, "editor": company4200, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "contact_person", "editable": true, "editor": contact_person4201, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "contact_role", "editable": true, "editor": contact_role4202, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "user", "editable": true, "editor": user4203, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4204, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "owner_type", "editable": true, "editor": owner_type4205, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "owner_id", "editable": true, "editor": owner_id4206, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 22, "dataIndex": "description", "editable": true, "editor": description4207, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "access_class", "editable": true, "editor": access_class4208, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 24, "dataIndex": "sequence", "editable": true, "editor": sequence4209, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 25, "dataIndex": "auto_type", "editable": true, "editor": auto_type4210, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByDay.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 26, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "priority", "editable": true, "editor": priority4212, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 28, "dataIndex": "state", "editable": true, "editor": state4213, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 29, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.EntriesByDay.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 34, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.url) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 38, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByDay.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.cal.EntriesByDay.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByDay.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByDay.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/EntriesByDay",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByDay.detail;
    this.ls_insert_handler = Lino.cal.EntriesByDay.insert;
    Lino.cal.EntriesByDay.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByDay.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.EntriesByDay.insertPanel(p);
});
Lino.cal.EntriesByDay.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByDay.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/EntriesByDay",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByDay.detail;
    this.ls_insert_handler = Lino.cal.EntriesByDay.insert;
    Lino.cal.EntriesByDay.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByDay.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EntriesByDay.detailPanel(p);
});
Lino.cal.EntriesByDay.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.EntriesByDay.GridPanel(p);
});
Lino.cal.EntriesByDay.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByDay.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByDay", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.OneEvent
Lino.cal.OneEvent.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/OneEvent",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/OneEvent','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/OneEvent','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_text" }, { "name": "user" }, 'userHidden', { "name": "summary" }, { "name": "event_type" }, 'event_typeHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.OneEvent.detail;
    this.ls_insert_handler = Lino.cal.OneEvent.insert;
    var ww = this.containing_window;
    var when_text_disp4225 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user4226 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/user" }) }) });
    var summary4227 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event_type4228 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/event_type" }) }) });
    var id4229 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified4230 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4231 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4232 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4233 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4234 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4235 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4236 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4237 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4238 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/company" }) }) });
    var contact_person4239 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/contact_person" }) }) });
    var contact_role4240 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/contact_role" }) }) });
    var assigned_to4241 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/assigned_to" }) }) });
    var owner_type4242 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/owner_type" }) }) });
    var owner_id4243 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/owner_id" }) }) });
    var description4244 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4245 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4246 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4247 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4248 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4249 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/room" }) }) });
    var priority4250 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OneEvent/priority" }) }) });
    var state4251 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4252 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4253 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4254 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4255 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4256 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4257 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4258 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4259 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4260 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4261 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4262 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4263 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4239.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4243.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4238.on('change',Lino.chooser_handler(contact_person4239,'company'));
      owner_type4242.on('change',Lino.chooser_handler(owner_id4243,'owner_type'));
      Lino.cal.OneEvent.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.OneEvent.when_text) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user4226, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.OneEvent.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "summary", "editable": true, "editor": summary4227, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.OneEvent.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "event_type", "editable": true, "editor": event_type4228, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.OneEvent.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4229, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.OneEvent.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date4232, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time4233, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date4234, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time4235, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 12, "dataIndex": "build_method", "editable": true, "editor": build_method4237, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 13, "dataIndex": "company", "editable": true, "editor": company4238, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.OneEvent.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_person", "editable": true, "editor": contact_person4239, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.OneEvent.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "contact_role", "editable": true, "editor": contact_role4240, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4241, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.OneEvent.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type4242, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.OneEvent.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id4243, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4244, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4245, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4246, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4247, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.OneEvent.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "room", "editable": true, "editor": room4249, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.OneEvent.room) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "priority", "editable": true, "editor": priority4250, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state4251, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 27, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.OneEvent.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 32, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.url) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.OneEvent.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.OneEvent.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.OneEvent.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.OneEvent.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/OneEvent",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.OneEvent.detail;
    this.ls_insert_handler = Lino.cal.OneEvent.insert;
    Lino.cal.OneEvent.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.OneEvent.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.OneEvent.insertPanel(p);
});
Lino.cal.OneEvent.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.OneEvent.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/OneEvent",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.OneEvent.detail;
    this.ls_insert_handler = Lino.cal.OneEvent.insert;
    Lino.cal.OneEvent.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.OneEvent.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.OneEvent.detailPanel(p);
});
Lino.cal.OneEvent.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.OneEvent.ParamsPanel({});
  return new Lino.cal.OneEvent.GridPanel(p);
});
Lino.cal.OneEvent.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OneEvent.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OneEvent", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyEntries
Lino.cal.MyEntries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyEntries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyEntries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyEntries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "My appointments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "summary" }, { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "event_type" }, 'event_typeHidden', { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyEntries.detail;
    this.ls_insert_handler = Lino.cal.MyEntries.insert;
    var ww = this.containing_window;
    var overview_disp4265 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp4266 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4267 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4268 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4269 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4270 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4271 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4272 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4273 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4274 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4275 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4276 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/company" }) }) });
    var contact_person4277 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/contact_person" }) }) });
    var contact_role4278 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/contact_role" }) }) });
    var user4279 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/user" }) }) });
    var assigned_to4280 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/assigned_to" }) }) });
    var owner_type4281 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/owner_type" }) }) });
    var owner_id4282 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/owner_id" }) }) });
    var summary4283 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description4284 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4285 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4286 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4287 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event_type4288 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/event_type" }) }) });
    var transparent4289 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4290 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/room" }) }) });
    var priority4291 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntries/priority" }) }) });
    var state4292 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4293 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4294 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4295 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4296 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4297 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4298 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4299 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4300 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4301 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4302 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4303 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4277.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4282.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4276.on('change',Lino.chooser_handler(contact_person4277,'company'));
      owner_type4281.on('change',Lino.chooser_handler(owner_id4282,'owner_type'));
      Lino.cal.MyEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(cal.MyEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyEntries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4267, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "start_date", "editable": true, "editor": start_date4270, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "start_time", "editable": true, "editor": start_time4271, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date4272, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "end_time", "editable": true, "editor": end_time4273, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 10, "dataIndex": "build_method", "editable": true, "editor": build_method4275, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 11, "dataIndex": "company", "editable": true, "editor": company4276, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.MyEntries.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "contact_person", "editable": true, "editor": contact_person4277, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.MyEntries.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_role", "editable": true, "editor": contact_role4278, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "user", "editable": true, "editor": user4279, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyEntries.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4280, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyEntries.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "owner_type", "editable": true, "editor": owner_type4281, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.MyEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_id", "editable": true, "editor": owner_id4282, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "summary", "editable": true, "editor": summary4283, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4284, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4285, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4286, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4287, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntries.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "event_type", "editable": true, "editor": event_type4288, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.MyEntries.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "room", "editable": true, "editor": room4290, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.MyEntries.room) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "priority", "editable": true, "editor": priority4291, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state4292, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 28, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 29, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.MyEntries.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 34, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.url) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntries.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.MyEntries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyEntries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyEntries.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyEntries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyEntries.detail;
    this.ls_insert_handler = Lino.cal.MyEntries.insert;
    Lino.cal.MyEntries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyEntries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyEntries.insertPanel(p);
});
Lino.cal.MyEntries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyEntries.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/MyEntries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyEntries.detail;
    this.ls_insert_handler = Lino.cal.MyEntries.insert;
    Lino.cal.MyEntries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyEntries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyEntries.detailPanel(p);
});
Lino.cal.MyEntries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.MyEntries.GridPanel(p);
});
Lino.cal.MyEntries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntries.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntries", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyEntriesToday
Lino.cal.MyEntriesToday.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyEntriesToday",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyEntriesToday','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyEntriesToday','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "My appointments today",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "start_time" }, { "name": "end_time" }, { "name": "event_type" }, 'event_typeHidden', { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyEntriesToday.detail;
    this.ls_insert_handler = Lino.cal.MyEntriesToday.insert;
    var ww = this.containing_window;
    var start_time4305 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time4306 = new Lino.TimeField({ "selectOnFocus": true });
    var event_type4307 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/event_type" }) }) });
    var summary4308 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp4309 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4310 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4311 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4312 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4313 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date4314 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var build_time4315 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4316 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4317 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/company" }) }) });
    var contact_person4318 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/contact_person" }) }) });
    var contact_role4319 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/contact_role" }) }) });
    var user4320 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/user" }) }) });
    var assigned_to4321 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/assigned_to" }) }) });
    var owner_type4322 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/owner_type" }) }) });
    var owner_id4323 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/owner_id" }) }) });
    var description4324 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4325 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4326 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4327 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4328 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4329 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/room" }) }) });
    var priority4330 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyEntriesToday/priority" }) }) });
    var state4331 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4332 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4333 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4334 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4335 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4336 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4337 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4338 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4339 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4340 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4341 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4342 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4343 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4318.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4323.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4317.on('change',Lino.chooser_handler(contact_person4318,'company'));
      owner_type4322.on('change',Lino.chooser_handler(owner_id4323,'owner_type'));
      Lino.cal.MyEntriesToday.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_time", "editable": true, "editor": start_time4305, "header": "Start time", "sortable": true, "tooltip": "(cal.MyEntriesToday.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 1, "dataIndex": "end_time", "editable": true, "editor": end_time4306, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(cal.MyEntriesToday.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "event_type", "editable": true, "editor": event_type4307, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "summary", "editable": true, "editor": summary4308, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.MyEntriesToday.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyEntriesToday.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id4310, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "start_date", "editable": true, "editor": start_date4313, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date4314, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 11, "dataIndex": "build_method", "editable": true, "editor": build_method4316, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 12, "dataIndex": "company", "editable": true, "editor": company4317, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_person", "editable": true, "editor": contact_person4318, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_role", "editable": true, "editor": contact_role4319, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "user", "editable": true, "editor": user4320, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4321, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type4322, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id4323, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4324, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4325, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4326, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4327, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.MyEntriesToday.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "room", "editable": true, "editor": room4329, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.room) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "priority", "editable": true, "editor": priority4330, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state4331, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 27, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.MyEntriesToday.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 33, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.url) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.MyEntriesToday.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.MyEntriesToday.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyEntriesToday.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyEntriesToday.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyEntriesToday",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyEntriesToday.detail;
    this.ls_insert_handler = Lino.cal.MyEntriesToday.insert;
    Lino.cal.MyEntriesToday.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyEntriesToday.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyEntriesToday.insertPanel(p);
});
Lino.cal.MyEntriesToday.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyEntriesToday.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/MyEntriesToday",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyEntriesToday.detail;
    this.ls_insert_handler = Lino.cal.MyEntriesToday.insert;
    Lino.cal.MyEntriesToday.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyEntriesToday.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyEntriesToday.detailPanel(p);
});
Lino.cal.MyEntriesToday.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.MyEntriesToday.GridPanel(p);
});
Lino.cal.MyEntriesToday.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyEntriesToday.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyEntriesToday", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyAssignedEvents
Lino.cal.MyAssignedEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyAssignedEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyAssignedEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyAssignedEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Events assigned to me",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "summary" }, { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "event_type" }, 'event_typeHidden', { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyAssignedEvents.detail;
    this.ls_insert_handler = Lino.cal.MyAssignedEvents.insert;
    var ww = this.containing_window;
    var overview_disp4345 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp4346 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4347 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4348 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4349 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4350 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4351 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4352 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4353 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4354 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4355 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4356 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/company" }) }) });
    var contact_person4357 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/contact_person" }) }) });
    var contact_role4358 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/contact_role" }) }) });
    var user4359 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/user" }) }) });
    var assigned_to4360 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/assigned_to" }) }) });
    var owner_type4361 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/owner_type" }) }) });
    var owner_id4362 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/owner_id" }) }) });
    var summary4363 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description4364 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4365 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4366 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4367 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event_type4368 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/event_type" }) }) });
    var transparent4369 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4370 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/room" }) }) });
    var priority4371 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyAssignedEvents/priority" }) }) });
    var state4372 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4373 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4374 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4375 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4376 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4377 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4378 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4379 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4380 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4381 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4382 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4383 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4357.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4362.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4356.on('change',Lino.chooser_handler(contact_person4357,'company'));
      owner_type4361.on('change',Lino.chooser_handler(owner_id4362,'owner_type'));
      Lino.cal.MyAssignedEvents.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(cal.MyAssignedEvents.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyAssignedEvents.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4347, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "start_date", "editable": true, "editor": start_date4350, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "start_time", "editable": true, "editor": start_time4351, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date4352, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "end_time", "editable": true, "editor": end_time4353, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 10, "dataIndex": "build_method", "editable": true, "editor": build_method4355, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 11, "dataIndex": "company", "editable": true, "editor": company4356, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "contact_person", "editable": true, "editor": contact_person4357, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_role", "editable": true, "editor": contact_role4358, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "user", "editable": true, "editor": user4359, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4360, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "owner_type", "editable": true, "editor": owner_type4361, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_id", "editable": true, "editor": owner_id4362, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "summary", "editable": true, "editor": summary4363, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4364, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4365, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4366, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4367, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.MyAssignedEvents.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "event_type", "editable": true, "editor": event_type4368, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "room", "editable": true, "editor": room4370, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.room) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "priority", "editable": true, "editor": priority4371, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state4372, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 28, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 29, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.MyAssignedEvents.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 34, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.url) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.MyAssignedEvents.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.MyAssignedEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyAssignedEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyAssignedEvents.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyAssignedEvents",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyAssignedEvents.detail;
    this.ls_insert_handler = Lino.cal.MyAssignedEvents.insert;
    Lino.cal.MyAssignedEvents.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyAssignedEvents.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyAssignedEvents.insertPanel(p);
});
Lino.cal.MyAssignedEvents.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyAssignedEvents.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/MyAssignedEvents",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyAssignedEvents.detail;
    this.ls_insert_handler = Lino.cal.MyAssignedEvents.insert;
    Lino.cal.MyAssignedEvents.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyAssignedEvents.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyAssignedEvents.detailPanel(p);
});
Lino.cal.MyAssignedEvents.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.MyAssignedEvents.GridPanel(p);
});
Lino.cal.MyAssignedEvents.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyAssignedEvents.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyAssignedEvents", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.OverdueAppointments
Lino.cal.OverdueAppointments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/OverdueAppointments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/OverdueAppointments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/OverdueAppointments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Overdue appointments",
  page_length : 20,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_html" }, { "name": "user" }, 'userHidden', { "name": "owner" }, { "name": "event_type" }, 'event_typeHidden', { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "calendar" }, 'calendarHidden', { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.OverdueAppointments.detail;
    this.ls_insert_handler = Lino.cal.OverdueAppointments.insert;
    var ww = this.containing_window;
    var when_html_disp4385 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user4386 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/user" }) }) });
    var owner_disp4387 = new Ext.form.DisplayField({ "disabled": true });
    var event_type4388 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/event_type" }) }) });
    var summary4389 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp4390 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4391 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4392 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4393 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4394 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4395 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4396 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4397 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4398 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4399 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4400 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/company" }) }) });
    var contact_person4401 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/contact_person" }) }) });
    var contact_role4402 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/contact_role" }) }) });
    var assigned_to4403 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/assigned_to" }) }) });
    var owner_type4404 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/owner_type" }) }) });
    var owner_id4405 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/owner_id" }) }) });
    var description4406 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4407 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4408 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4409 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4410 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4411 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/room" }) }) });
    var priority4412 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/OverdueAppointments/priority" }) }) });
    var state4413 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var calendar4414 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var reminder_disp4415 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4416 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4417 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4418 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4419 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4420 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4421 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4422 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4423 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4401.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4405.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4400.on('change',Lino.chooser_handler(contact_person4401,'company'));
      owner_type4404.on('change',Lino.chooser_handler(owner_id4405,'owner_type'));
      Lino.cal.OverdueAppointments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_html", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.OverdueAppointments.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user4386, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(cal.OverdueAppointments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "event_type", "editable": true, "editor": event_type4388, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "summary", "editable": true, "editor": summary4389, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.OverdueAppointments.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.OverdueAppointments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id4391, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 9, "dataIndex": "start_date", "editable": true, "editor": start_date4394, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "start_time", "editable": true, "editor": start_time4395, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "end_date", "editable": true, "editor": end_date4396, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 12, "dataIndex": "end_time", "editable": true, "editor": end_time4397, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 13, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 14, "dataIndex": "build_method", "editable": true, "editor": build_method4399, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 15, "dataIndex": "company", "editable": true, "editor": company4400, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "contact_person", "editable": true, "editor": contact_person4401, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "contact_role", "editable": true, "editor": contact_role4402, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4403, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "owner_type", "editable": true, "editor": owner_type4404, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "owner_id", "editable": true, "editor": owner_id4405, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 21, "dataIndex": "description", "editable": true, "editor": description4406, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "access_class", "editable": true, "editor": access_class4407, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 23, "dataIndex": "sequence", "editable": true, "editor": sequence4408, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 24, "dataIndex": "auto_type", "editable": true, "editor": auto_type4409, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.OverdueAppointments.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 25, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "room", "editable": true, "editor": room4411, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.room) ", "width": Lino.chars2width(21) }, { "colIndex": 27, "dataIndex": "priority", "editable": true, "editor": priority4412, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 28, "dataIndex": "state", "editable": true, "editor": state4413, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 29, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.OverdueAppointments.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 33, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.url) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.OverdueAppointments.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.OverdueAppointments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.OverdueAppointments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.OverdueAppointments.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/OverdueAppointments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.OverdueAppointments.detail;
    this.ls_insert_handler = Lino.cal.OverdueAppointments.insert;
    Lino.cal.OverdueAppointments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.OverdueAppointments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.OverdueAppointments.insertPanel(p);
});
Lino.cal.OverdueAppointments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.OverdueAppointments.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/OverdueAppointments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.OverdueAppointments.detail;
    this.ls_insert_handler = Lino.cal.OverdueAppointments.insert;
    Lino.cal.OverdueAppointments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.OverdueAppointments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.OverdueAppointments.detailPanel(p);
});
Lino.cal.OverdueAppointments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.OverdueAppointments.GridPanel(p);
});
Lino.cal.OverdueAppointments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.OverdueAppointments.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/OverdueAppointments", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyOverdueAppointments
Lino.cal.MyOverdueAppointments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyOverdueAppointments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyOverdueAppointments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyOverdueAppointments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "My overdue appointments",
  page_length : 20,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "overview" }, { "name": "owner" }, { "name": "event_type" }, 'event_typeHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "summary" }, { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyOverdueAppointments.detail;
    this.ls_insert_handler = Lino.cal.MyOverdueAppointments.insert;
    var ww = this.containing_window;
    var overview_disp4425 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var owner_disp4426 = new Ext.form.DisplayField({ "disabled": true });
    var event_type4427 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/event_type" }) }) });
    var workflow_buttons_disp4428 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4429 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4430 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4431 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4432 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4433 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4434 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4435 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4436 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4437 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4438 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/company" }) }) });
    var contact_person4439 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/contact_person" }) }) });
    var contact_role4440 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/contact_role" }) }) });
    var user4441 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/user" }) }) });
    var assigned_to4442 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/assigned_to" }) }) });
    var owner_type4443 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/owner_type" }) }) });
    var owner_id4444 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/owner_id" }) }) });
    var summary4445 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description4446 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4447 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4448 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4449 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent4450 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4451 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/room" }) }) });
    var priority4452 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyOverdueAppointments/priority" }) }) });
    var state4453 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var calendar4454 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp4455 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp4456 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4457 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4458 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4459 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4460 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4461 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4462 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4463 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4439.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4444.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4438.on('change',Lino.chooser_handler(contact_person4439,'company'));
      owner_type4443.on('change',Lino.chooser_handler(owner_id4444,'owner_type'));
      Lino.cal.MyOverdueAppointments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(cal.MyOverdueAppointments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(cal.MyOverdueAppointments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "event_type", "editable": true, "editor": event_type4427, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyOverdueAppointments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4429, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date4432, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time4433, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date4434, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time4435, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 12, "dataIndex": "build_method", "editable": true, "editor": build_method4437, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 13, "dataIndex": "company", "editable": true, "editor": company4438, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_person", "editable": true, "editor": contact_person4439, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "contact_role", "editable": true, "editor": contact_role4440, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "user", "editable": true, "editor": user4441, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4442, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_type", "editable": true, "editor": owner_type4443, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "owner_id", "editable": true, "editor": owner_id4444, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 20, "dataIndex": "summary", "editable": true, "editor": summary4445, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "description", "editable": true, "editor": description4446, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "access_class", "editable": true, "editor": access_class4447, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 23, "dataIndex": "sequence", "editable": true, "editor": sequence4448, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 24, "dataIndex": "auto_type", "editable": true, "editor": auto_type4449, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.MyOverdueAppointments.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 25, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "room", "editable": true, "editor": room4451, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.room) ", "width": Lino.chars2width(21) }, { "colIndex": 27, "dataIndex": "priority", "editable": true, "editor": priority4452, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 28, "dataIndex": "state", "editable": true, "editor": state4453, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 29, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.MyOverdueAppointments.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 34, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.url) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.MyOverdueAppointments.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.MyOverdueAppointments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyOverdueAppointments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyOverdueAppointments.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyOverdueAppointments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyOverdueAppointments.detail;
    this.ls_insert_handler = Lino.cal.MyOverdueAppointments.insert;
    Lino.cal.MyOverdueAppointments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyOverdueAppointments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyOverdueAppointments.insertPanel(p);
});
Lino.cal.MyOverdueAppointments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyOverdueAppointments.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/MyOverdueAppointments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyOverdueAppointments.detail;
    this.ls_insert_handler = Lino.cal.MyOverdueAppointments.insert;
    Lino.cal.MyOverdueAppointments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyOverdueAppointments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyOverdueAppointments.detailPanel(p);
});
Lino.cal.MyOverdueAppointments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.MyOverdueAppointments.GridPanel(p);
});
Lino.cal.MyOverdueAppointments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyOverdueAppointments.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyOverdueAppointments", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.MyUnconfirmedAppointments
Lino.cal.MyUnconfirmedAppointments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/MyUnconfirmedAppointments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/MyUnconfirmedAppointments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/MyUnconfirmedAppointments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Unconfirmed appointments",
  page_length : 20,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_html" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "event_type" }, 'event_typeHidden', { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyUnconfirmedAppointments.detail;
    this.ls_insert_handler = Lino.cal.MyUnconfirmedAppointments.insert;
    var ww = this.containing_window;
    var when_html_disp4465 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var summary4466 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp4467 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4468 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4469 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4470 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date4471 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4472 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4473 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4474 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time4475 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method4476 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4477 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/company" }) }) });
    var contact_person4478 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/contact_person" }) }) });
    var contact_role4479 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/contact_role" }) }) });
    var user4480 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/user" }) }) });
    var assigned_to4481 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/assigned_to" }) }) });
    var owner_type4482 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/owner_type" }) }) });
    var owner_id4483 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/owner_id" }) }) });
    var description4484 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class4485 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence4486 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type4487 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event_type4488 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/event_type" }) }) });
    var transparent4489 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room4490 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/room" }) }) });
    var priority4491 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/MyUnconfirmedAppointments/priority" }) }) });
    var state4492 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp4493 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar4494 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var reminder_disp4495 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp4496 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day4497 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp4498 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4499 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4500 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4501 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4502 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4503 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person4478.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4483.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company4477.on('change',Lino.chooser_handler(contact_person4478,'company'));
      owner_type4482.on('change',Lino.chooser_handler(owner_id4483,'owner_type'));
      Lino.cal.MyUnconfirmedAppointments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_html", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary4466, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id4468, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date4471, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "start_time", "editable": true, "editor": start_time4472, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date4473, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "end_time", "editable": true, "editor": end_time4474, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 11, "dataIndex": "build_method", "editable": true, "editor": build_method4476, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 12, "dataIndex": "company", "editable": true, "editor": company4477, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_person", "editable": true, "editor": contact_person4478, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_role", "editable": true, "editor": contact_role4479, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "user", "editable": true, "editor": user4480, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to4481, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type4482, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id4483, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description4484, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class4485, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence4486, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type4487, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.MyUnconfirmedAppointments.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "event_type", "editable": true, "editor": event_type4488, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "room", "editable": true, "editor": room4490, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.room) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "priority", "editable": true, "editor": priority4491, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state4492, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 28, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 29, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 33, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.url) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.MyUnconfirmedAppointments.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.MyUnconfirmedAppointments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyUnconfirmedAppointments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyUnconfirmedAppointments.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/MyUnconfirmedAppointments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyUnconfirmedAppointments.detail;
    this.ls_insert_handler = Lino.cal.MyUnconfirmedAppointments.insert;
    Lino.cal.MyUnconfirmedAppointments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyUnconfirmedAppointments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.MyUnconfirmedAppointments.insertPanel(p);
});
Lino.cal.MyUnconfirmedAppointments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.MyUnconfirmedAppointments.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/MyUnconfirmedAppointments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.MyUnconfirmedAppointments.detail;
    this.ls_insert_handler = Lino.cal.MyUnconfirmedAppointments.insert;
    Lino.cal.MyUnconfirmedAppointments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.MyUnconfirmedAppointments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.MyUnconfirmedAppointments.detailPanel(p);
});
Lino.cal.MyUnconfirmedAppointments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.MyUnconfirmedAppointments.GridPanel(p);
});
Lino.cal.MyUnconfirmedAppointments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.MyUnconfirmedAppointments.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/MyUnconfirmedAppointments", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.EventPolicies
Lino.cal.EventPolicies.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/EventPolicies",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EventPolicies','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EventPolicies','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Recurrency policies",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 29,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "event_type" }, 'event_typeHidden', { "name": "max_events", "type": "int", "useNull": true }, { "name": "every", "type": "int", "useNull": true }, { "name": "every_unit" }, 'every_unitHidden', { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 15,
  ls_grid_configs : [  ],
  content_type : 22,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var name4505 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4506 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event_type4507 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EventPolicies/event_type" }) }) });
    var max_events4508 = new Ext.form.NumberField({ "selectOnFocus": true });
    var every4509 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 1 });
    var every_unit4510 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var monday4511 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var tuesday4512 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var wednesday4513 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var thursday4514 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var friday4515 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var saturday4516 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var sunday4517 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var id4518 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date4519 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time4520 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date4521 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time4522 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp4523 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4524 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4525 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4526 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var weekdays_text_disp4527 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp4528 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp4529 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration4530 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name4505, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.EventPolicies.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et4506, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.EventPolicies.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "event_type", "editable": true, "editor": event_type4507, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.EventPolicies.event_type) Generated calendar entries will have this type.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "max_events", "editable": true, "editor": max_events4508, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "sortable": true, "tooltip": "(cal.EventPolicies.max_events) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 4, "dataIndex": "every", "editable": true, "editor": every4509, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "sortable": true, "tooltip": "(cal.EventPolicies.every) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "every_unit", "editable": true, "editor": every_unit4510, "filter": { "type": "string" }, "header": "Korduvus", "sortable": false, "tooltip": "(cal.EventPolicies.every_unit) ", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "sortable": false, "tooltip": "(cal.EventPolicies.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 7, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "sortable": false, "tooltip": "(cal.EventPolicies.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 8, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "sortable": false, "tooltip": "(cal.EventPolicies.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "sortable": false, "tooltip": "(cal.EventPolicies.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "sortable": false, "tooltip": "(cal.EventPolicies.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "sortable": false, "tooltip": "(cal.EventPolicies.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "sortable": false, "tooltip": "(cal.EventPolicies.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 13, "dataIndex": "id", "editable": true, "editor": id4518, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.EventPolicies.id) ", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "start_date", "editable": true, "editor": start_date4519, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.EventPolicies.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 15, "dataIndex": "start_time", "editable": true, "editor": start_time4520, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.EventPolicies.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 16, "dataIndex": "end_date", "editable": true, "editor": end_date4521, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.EventPolicies.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 17, "dataIndex": "end_time", "editable": true, "editor": end_time4522, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.EventPolicies.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 24, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.what_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 25, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.EventPolicies.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.EventPolicies.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EventPolicies.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventPolicies", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventPolicies.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventPolicies", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventPolicies.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventPolicies", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventPolicies.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventPolicies", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventPolicies.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventPolicies", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventPolicies.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventPolicies", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventPolicies.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EventPolicies.GridPanel(p);
});

// js_render_GridPanel_class extensible.PanelCalendars
Lino.extensible.PanelCalendars.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/extensible/PanelCalendars",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/extensible/PanelCalendars','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/extensible/PanelCalendars','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Calendars",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "description" }, { "name": "color", "type": "int", "useNull": true }, { "name": "is_hidden", "type": "boolean" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 21,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.extensible.PanelCalendars.detail;
    this.ls_insert_handler = Lino.extensible.PanelCalendars.insert;
    var ww = this.containing_window;
    var id4532 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary_disp4533 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var description4534 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var color4535 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true });
    var is_hidden_disp4536 = new Ext.form.DisplayField({ "disabled": true });
    this.before_row_edit = function(record) {
      description4534.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4532, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(extensible.PanelCalendars.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": false, "header": "summary", "sortable": false, "tooltip": "(extensible.PanelCalendars.summary) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "description", "editable": true, "editor": description4534, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(extensible.PanelCalendars.description) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 3, "dataIndex": "color", "editable": true, "editor": color4535, "filter": { "type": "numeric" }, "format": "0", "header": "color", "sortable": true, "tooltip": "(extensible.PanelCalendars.color) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "is_hidden", "editable": false, "header": "Hidden", "sortable": false, "tooltip": "(extensible.PanelCalendars.is_hidden) ", "width": Lino.chars2width(21) } ];
    Lino.extensible.PanelCalendars.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.extensible.PanelCalendars.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelCalendars.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelCalendars.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.extensible.PanelCalendars.insertPanel = Ext.extend(Lino.cal.Calendars.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/extensible/PanelCalendars",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.extensible.PanelCalendars.detail;
    this.ls_insert_handler = Lino.extensible.PanelCalendars.insert;
    Lino.extensible.PanelCalendars.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.extensible.PanelCalendars.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.extensible.PanelCalendars.insertPanel(p);
});
Lino.extensible.PanelCalendars.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelCalendars.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelCalendars.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.extensible.PanelCalendars.detailPanel = Ext.extend(Lino.cal.Calendars.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/extensible/PanelCalendars",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.extensible.PanelCalendars.detail;
    this.ls_insert_handler = Lino.extensible.PanelCalendars.insert;
    Lino.extensible.PanelCalendars.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.extensible.PanelCalendars.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.extensible.PanelCalendars.detailPanel(p);
});
Lino.extensible.PanelCalendars.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelCalendars.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.extensible.PanelCalendars.GridPanel(p);
});
Lino.extensible.PanelCalendars.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelCalendars", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class extensible.PanelEvents
Lino.extensible.PanelEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/extensible/PanelEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/extensible/PanelEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/extensible/PanelEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 15,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "start_dt" }, { "name": "end_dt" }, { "name": "summary" }, { "name": "description" }, { "name": "user" }, 'userHidden', { "name": "room" }, 'roomHidden', { "name": "calendar" }, 'calendarHidden', { "name": "url" }, { "name": "all_day", "type": "boolean" }, { "name": "reminder" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.extensible.PanelEvents.detail;
    this.ls_insert_handler = Lino.extensible.PanelEvents.insert;
    var ww = this.containing_window;
    var id4538 = new Ext.form.NumberField({ "selectOnFocus": true });
    var start_dt4539 = new Ext.form.DisplayField({ "allowBlank": false, "selectOnFocus": true, "value": "<br>" });
    var end_dt4540 = new Ext.form.DisplayField({ "allowBlank": false, "selectOnFocus": true, "value": "<br>" });
    var summary4541 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var description4542 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var user4543 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/extensible/PanelEvents/user" }) }) });
    var room4544 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/extensible/PanelEvents/room" }) }) });
    var calendar4545 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var url_disp4546 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var all_day4547 = new Ext.form.Checkbox({ "selectOnFocus": true });
    var reminder_disp4548 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4538, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(extensible.PanelEvents.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "start_dt", "editable": true, "editor": start_dt4539, "header": "Start", "sortable": false, "tooltip": "(extensible.PanelEvents.start_dt) ", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "end_dt", "editable": true, "editor": end_dt4540, "header": "End", "sortable": false, "tooltip": "(extensible.PanelEvents.end_dt) ", "width": Lino.chars2width(17) }, { "colIndex": 3, "dataIndex": "summary", "editable": true, "editor": summary4541, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(extensible.PanelEvents.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "description", "editable": true, "editor": description4542, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(extensible.PanelEvents.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 5, "dataIndex": "user", "editable": true, "editor": user4543, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(extensible.PanelEvents.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "room", "editable": true, "editor": room4544, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(extensible.PanelEvents.room) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "calendar", "editable": false, "header": "Kalender", "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(extensible.PanelEvents.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "url", "editable": false, "header": "Link URL", "sortable": false, "tooltip": "(extensible.PanelEvents.url) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "all_day", "editable": true, "header": "all day", "sortable": false, "tooltip": "(extensible.PanelEvents.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "reminder", "editable": false, "header": "Reminder", "sortable": false, "tooltip": "(extensible.PanelEvents.reminder) ", "width": Lino.chars2width(31) } ];
    Lino.extensible.PanelEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.extensible.PanelEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.extensible.PanelEvents.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/extensible/PanelEvents",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.extensible.PanelEvents.detail;
    this.ls_insert_handler = Lino.extensible.PanelEvents.insert;
    Lino.extensible.PanelEvents.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.extensible.PanelEvents.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.extensible.PanelEvents.insertPanel(p);
});
Lino.extensible.PanelEvents.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.extensible.PanelEvents.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/extensible/PanelEvents",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.extensible.PanelEvents.detail;
    this.ls_insert_handler = Lino.extensible.PanelEvents.insert;
    Lino.extensible.PanelEvents.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.extensible.PanelEvents.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.extensible.PanelEvents.detailPanel(p);
});
Lino.extensible.PanelEvents.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.extensible.PanelEvents.GridPanel(p);
});
Lino.extensible.PanelEvents.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.extensible.PanelEvents.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/extensible/PanelEvents", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class addresses.Addresses
Lino.addresses.Addresses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/addresses/Addresses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/addresses/Addresses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/addresses/Addresses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Aadressid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "address_type" }, 'address_typeHidden', { "name": "remark" }, { "name": "address_column" }, { "name": "primary", "type": "boolean" }, { "name": "data_source" }, 'data_sourceHidden', { "name": "id", "type": "int" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 24,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.addresses.Addresses.detail;
    this.ls_insert_handler = Lino.addresses.Addresses.insert;
    var ww = this.containing_window;
    var partner4550 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/partner" }) }) });
    var address_type4551 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.addresses.AddressTypes });
    var remark4552 = new Ext.form.TextField({ "maxLength": 50, "selectOnFocus": true });
    var address_column_disp4553 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var primary4554 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var data_source4555 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "store": Lino.addresses.DataSources });
    var id4556 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var country4557 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/country" }) }) });
    var city4558 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/city" }) }) });
    var zip_code4559 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region4560 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/addresses/Addresses/region" }) }) });
    var addr14561 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix4562 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street4563 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no4564 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box4565 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr24566 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var mobile_item_disp4567 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4568 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4569 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4570 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city4558.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city4558.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region4560.setContextValue('country', record ? record.data['countryHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      country4557.on('change',Lino.chooser_handler(city4558,'country'));
      region4560.on('change',Lino.chooser_handler(city4558,'region'));
      country4557.on('change',Lino.chooser_handler(region4560,'country'));
      Lino.addresses.Addresses.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner4550, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(addresses.Addresses.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "address_type", "editable": true, "editor": address_type4551, "filter": { "type": "string" }, "header": "Aadressiliik", "sortable": false, "tooltip": "(addresses.Addresses.address_type) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "remark", "editable": true, "editor": remark4552, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(addresses.Addresses.remark) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "address_column", "editable": false, "header": "Aadres", "sortable": false, "tooltip": "(addresses.Addresses.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "primary", "editable": true, "filter": { "type": "boolean" }, "header": "Primary", "sortable": false, "tooltip": "(addresses.Addresses.primary) Checking this field will automatically uncheck any previous primary addresses and update the partner's address data fields.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 5, "dataIndex": "data_source", "editable": false, "filter": { "type": "string" }, "header": "Data source", "sortable": false, "tooltip": "(addresses.Addresses.data_source) Pointer to choicelists.DataSources.", "width": Lino.chars2width(20) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id4556, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "country", "editable": true, "editor": country4557, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(addresses.Addresses.country) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "city", "editable": true, "editor": city4558, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(addresses.Addresses.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "zip_code", "editable": true, "editor": zip_code4559, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 10, "dataIndex": "region", "editable": true, "editor": region4560, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(addresses.Addresses.region) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "addr1", "editable": true, "editor": addr14561, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 12, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix4562, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 13, "dataIndex": "street", "editable": true, "editor": street4563, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street_no", "editable": true, "editor": street_no4564, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 15, "dataIndex": "street_box", "editable": true, "editor": street_box4565, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 16, "dataIndex": "addr2", "editable": true, "editor": addr24566, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(addresses.Addresses.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(addresses.Addresses.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(addresses.Addresses.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(addresses.Addresses.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(addresses.Addresses.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.addresses.Addresses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.Addresses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.Addresses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.Addresses.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.addresses.Addresses.insertPanel = Ext.extend(Lino.addresses.Addresses.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/addresses/Addresses",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.addresses.Addresses.detail;
    this.ls_insert_handler = Lino.addresses.Addresses.insert;
    Lino.addresses.Addresses.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.Addresses.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.addresses.Addresses.insertPanel(p);
});
Lino.addresses.Addresses.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.Addresses.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.Addresses.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.addresses.Addresses.detailPanel = Ext.extend(Lino.addresses.Addresses.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/addresses/Addresses",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.addresses.Addresses.detail;
    this.ls_insert_handler = Lino.addresses.Addresses.insert;
    Lino.addresses.Addresses.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.Addresses.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "is_main_window": true };
  return new Lino.addresses.Addresses.detailPanel(p);
});
Lino.addresses.Addresses.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.Addresses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.addresses.Addresses.GridPanel(p);
});
Lino.addresses.Addresses.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/Addresses", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class topics.TopicGroups
Lino.topics.TopicGroups.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/TopicGroups",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/TopicGroups','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/TopicGroups','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Topic groups",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 9,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "description" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 30,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.TopicGroups.detail;
    this.ls_insert_handler = Lino.topics.TopicGroups.insert;
    var ww = this.containing_window;
    var id4572 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name4573 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4574 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var description4575 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var mobile_item_disp4576 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4577 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4578 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4579 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description4575.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4572, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(topics.TopicGroups.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name4573, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(topics.TopicGroups.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et4574, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(topics.TopicGroups.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "description", "editable": true, "editor": description4575, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(topics.TopicGroups.description) ", "width": Lino.chars2width(61) }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.TopicGroups.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.TopicGroups.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.TopicGroups.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.TopicGroups.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.topics.TopicGroups.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.TopicGroups.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicGroups.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicGroups.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.TopicGroups.insertPanel = Ext.extend(Lino.topics.TopicGroups.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/topics/TopicGroups",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.TopicGroups.detail;
    this.ls_insert_handler = Lino.topics.TopicGroups.insert;
    Lino.topics.TopicGroups.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.TopicGroups.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.topics.TopicGroups.insertPanel(p);
});
Lino.topics.TopicGroups.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicGroups.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicGroups.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.TopicGroups.detailPanel = Ext.extend(Lino.topics.TopicGroups.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/topics/TopicGroups",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.TopicGroups.detail;
    this.ls_insert_handler = Lino.topics.TopicGroups.insert;
    Lino.topics.TopicGroups.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.TopicGroups.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.TopicGroups.detailPanel(p);
});
Lino.topics.TopicGroups.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicGroups.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.TopicGroups.GridPanel(p);
});
Lino.topics.TopicGroups.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicGroups", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class topics.Topics
Lino.topics.Topics.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/Topics",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/Topics','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/Topics','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Teemad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "name_et" }, { "name": "topic_group" }, 'topic_groupHidden', { "name": "id", "type": "int" }, { "name": "description" }, { "name": "description_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 31,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.Topics.detail;
    this.ls_insert_handler = Lino.topics.Topics.insert;
    var ww = this.containing_window;
    var ref4581 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name4582 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4583 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var topic_group4584 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Topic group...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/Topics/topic_group" }) }) });
    var id4585 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var description4586 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Long description" });
    var description_et4587 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Long description (et)" });
    var mobile_item_disp4588 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4589 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4590 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4591 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description4586.refresh();
      description_et4587.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref4581, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(topics.Topics.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name4582, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(topics.Topics.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et4583, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(topics.Topics.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "topic_group", "editable": true, "editor": topic_group4584, "filter": { "type": "string" }, "header": "Topic group", "renderer": Lino.fk_renderer('topic_groupHidden','Lino.topics.TopicGroups.detail'), "sortable": false, "tooltip": "(topics.Topics.topic_group) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4585, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.Topics.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "description", "editable": true, "editor": description4586, "filter": { "type": "string" }, "header": "Long description", "hidden": true, "sortable": false, "tooltip": "(topics.Topics.description) ", "width": Lino.chars2width(61) }, { "colIndex": 6, "dataIndex": "description_et", "editable": true, "editor": description_et4587, "filter": { "type": "string" }, "header": "Long description (et)", "hidden": true, "sortable": false, "tooltip": "(topics.Topics.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.Topics.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.Topics.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.Topics.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.Topics.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.topics.Topics.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.Topics.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Topics.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Topics.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.Topics.insertPanel = Ext.extend(Lino.topics.Topics.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/topics/Topics",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.Topics.detail;
    this.ls_insert_handler = Lino.topics.Topics.insert;
    Lino.topics.Topics.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.Topics.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.topics.Topics.insertPanel(p);
});
Lino.topics.Topics.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Topics.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Topics.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.Topics.detailPanel = Ext.extend(Lino.topics.Topics.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/topics/Topics",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.Topics.detail;
    this.ls_insert_handler = Lino.topics.Topics.insert;
    Lino.topics.Topics.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.Topics.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.Topics.detailPanel(p);
});
Lino.topics.Topics.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Topics.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.Topics.GridPanel(p);
});
Lino.topics.Topics.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Topics", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class topics.AllTopics
Lino.topics.AllTopics.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/AllTopics",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/AllTopics','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/AllTopics','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Teemad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "name_et" }, { "name": "topic_group" }, 'topic_groupHidden', { "name": "id", "type": "int" }, { "name": "description" }, { "name": "description_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 31,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.AllTopics.detail;
    this.ls_insert_handler = Lino.topics.AllTopics.insert;
    var ww = this.containing_window;
    var ref4593 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name4594 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4595 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var topic_group4596 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Topic group...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/AllTopics/topic_group" }) }) });
    var id4597 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var description4598 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Long description" });
    var description_et4599 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Long description (et)" });
    var mobile_item_disp4600 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4601 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4602 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4603 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description4598.refresh();
      description_et4599.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref4593, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(topics.AllTopics.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name4594, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(topics.AllTopics.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et4595, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(topics.AllTopics.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "topic_group", "editable": true, "editor": topic_group4596, "filter": { "type": "string" }, "header": "Topic group", "renderer": Lino.fk_renderer('topic_groupHidden','Lino.topics.TopicGroups.detail'), "sortable": false, "tooltip": "(topics.AllTopics.topic_group) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4597, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.AllTopics.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "description", "editable": true, "editor": description4598, "filter": { "type": "string" }, "header": "Long description", "hidden": true, "sortable": false, "tooltip": "(topics.AllTopics.description) ", "width": Lino.chars2width(61) }, { "colIndex": 6, "dataIndex": "description_et", "editable": true, "editor": description_et4599, "filter": { "type": "string" }, "header": "Long description (et)", "hidden": true, "sortable": false, "tooltip": "(topics.AllTopics.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.AllTopics.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.AllTopics.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.AllTopics.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.AllTopics.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.topics.AllTopics.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.AllTopics.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllTopics.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllTopics.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.AllTopics.insertPanel = Ext.extend(Lino.topics.Topics.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/topics/AllTopics",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.AllTopics.detail;
    this.ls_insert_handler = Lino.topics.AllTopics.insert;
    Lino.topics.AllTopics.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.AllTopics.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.topics.AllTopics.insertPanel(p);
});
Lino.topics.AllTopics.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllTopics.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllTopics.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.AllTopics.detailPanel = Ext.extend(Lino.topics.Topics.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/topics/AllTopics",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.AllTopics.detail;
    this.ls_insert_handler = Lino.topics.AllTopics.insert;
    Lino.topics.AllTopics.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.AllTopics.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.AllTopics.detailPanel(p);
});
Lino.topics.AllTopics.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllTopics.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.AllTopics.GridPanel(p);
});
Lino.topics.AllTopics.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllTopics", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class topics.Interests
Lino.topics.Interests.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/Interests",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/Interests','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/Interests','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Interests",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "topic" }, 'topicHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 32,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var partner4605 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/Interests/partner" }) }) });
    var topic4606 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/Interests/topic" }) }) });
    var id4607 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp4608 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4609 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4610 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4611 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner4605, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(topics.Interests.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "topic", "editable": true, "editor": topic4606, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(topics.Interests.topic) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4607, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.Interests.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.Interests.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.Interests.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.Interests.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.Interests.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.topics.Interests.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.Interests.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Interests", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Interests.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Interests", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Interests.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Interests", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Interests.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Interests", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Interests.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Interests", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Interests.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/Interests", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.Interests.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.Interests.GridPanel(p);
});

// js_render_GridPanel_class topics.AllInterests
Lino.topics.AllInterests.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/AllInterests",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/AllInterests','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/AllInterests','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Interests",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "topic" }, 'topicHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 32,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var partner4613 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/AllInterests/partner" }) }) });
    var topic4614 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/AllInterests/topic" }) }) });
    var id4615 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp4616 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4617 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4618 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4619 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner4613, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(topics.AllInterests.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "topic", "editable": true, "editor": topic4614, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(topics.AllInterests.topic) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4615, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.AllInterests.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.AllInterests.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.AllInterests.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.AllInterests.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.AllInterests.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.topics.AllInterests.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.AllInterests.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllInterests", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllInterests.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllInterests", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllInterests.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllInterests", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllInterests.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllInterests", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllInterests.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllInterests", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllInterests.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/AllInterests", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.AllInterests.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.AllInterests.GridPanel(p);
});

// js_render_GridPanel_class gfks.ContentTypes
Lino.gfks.ContentTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/gfks/ContentTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/gfks/ContentTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/gfks/ContentTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "sisut\u00fc\u00fcbid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "app_label" }, { "name": "model" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 34,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.gfks.ContentTypes.detail;
    this.ls_insert_handler = Lino.gfks.ContentTypes.insert;
    var ww = this.containing_window;
    var id4621 = new Ext.form.NumberField({ "selectOnFocus": true });
    var app_label4622 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 100, "selectOnFocus": true });
    var model4623 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 100, "selectOnFocus": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4621, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(gfks.ContentTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "app_label", "editable": true, "editor": app_label4622, "filter": { "type": "string" }, "header": "app label", "sortable": true, "tooltip": "(gfks.ContentTypes.app_label) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "model", "editable": true, "editor": model4623, "filter": { "type": "string" }, "header": "pythoni mudeli klassinimi", "sortable": true, "tooltip": "(gfks.ContentTypes.model) ", "width": Lino.chars2width(22) } ];
    Lino.gfks.ContentTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.ContentTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.ContentTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.ContentTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.gfks.ContentTypes.insertPanel = Ext.extend(Lino.gfks.ContentTypes.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/gfks/ContentTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.gfks.ContentTypes.detail;
    this.ls_insert_handler = Lino.gfks.ContentTypes.insert;
    Lino.gfks.ContentTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.ContentTypes.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.gfks.ContentTypes.insertPanel(p);
});
Lino.gfks.ContentTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.ContentTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.ContentTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.gfks.ContentTypes.detailPanel = Ext.extend(Lino.gfks.ContentTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/gfks/ContentTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.gfks.ContentTypes.detail;
    this.ls_insert_handler = Lino.gfks.ContentTypes.insert;
    Lino.gfks.ContentTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.ContentTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.gfks.ContentTypes.detailPanel(p);
});
Lino.gfks.ContentTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.ContentTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.gfks.ContentTypes.GridPanel(p);
});
Lino.gfks.ContentTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/ContentTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class gfks.HelpTexts
Lino.gfks.HelpTexts.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/gfks/HelpTexts",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/gfks/HelpTexts','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/gfks/HelpTexts','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Help Texts",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "field" }, { "name": "verbose_name" }, { "name": "help_text" }, { "name": "id", "type": "int" }, { "name": "content_type" }, 'content_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 35,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var field4625 = new Lino.SimpleRemoteComboFieldElement({ "allowBlank": false, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/gfks/HelpTexts/field" }) }) });
    var verbose_name4626 = new Ext.form.TextField({ "disabled": true, "maxLength": 200 });
    var help_text4627 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var id4628 = new Ext.form.NumberField({ "selectOnFocus": true });
    var content_type4629 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/gfks/HelpTexts/content_type" }) }) });
    this.before_row_edit = function(record) {
      field4625.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      content_type4629.on('change',Lino.chooser_handler(field4625,'content_type'));
      Lino.gfks.HelpTexts.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "field", "editable": true, "editor": field4625, "filter": { "type": "string" }, "header": "Field", "sortable": false, "tooltip": "(gfks.HelpTexts.field) ", "width": Lino.chars2width(11) }, { "colIndex": 1, "dataIndex": "verbose_name", "editable": false, "header": "Verbose name", "sortable": false, "tooltip": "(gfks.HelpTexts.verbose_name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "help_text", "editable": true, "editor": help_text4627, "filter": { "type": "string" }, "header": "HelpText", "sortable": false, "tooltip": "(gfks.HelpTexts.help_text) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id4628, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(gfks.HelpTexts.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "content_type", "editable": true, "editor": content_type4629, "filter": { "type": "string" }, "header": "Model", "renderer": Lino.fk_renderer('content_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(gfks.HelpTexts.content_type) ", "width": Lino.chars2width(21) } ];
    Lino.gfks.HelpTexts.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.HelpTexts.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTexts", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTexts.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTexts", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTexts.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTexts", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTexts.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTexts", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTexts.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTexts", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTexts.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTexts", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTexts.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.gfks.HelpTexts.GridPanel(p);
});

// js_render_GridPanel_class excerpts.ExcerptTypes
Lino.excerpts.ExcerptTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/excerpts/ExcerptTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/ExcerptTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/ExcerptTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "V\u00e4ljav\u00f5teliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 24,
  ls_store_fields : [ { "name": "content_type_display" }, { "name": "primary", "type": "boolean" }, { "name": "certifying", "type": "boolean" }, { "name": "name" }, { "name": "name_et" }, { "name": "build_method" }, 'build_methodHidden', { "name": "template" }, { "name": "body_template" }, { "name": "id", "type": "int" }, { "name": "attach_to_email", "type": "boolean" }, { "name": "email_template" }, { "name": "remark" }, { "name": "content_type" }, 'content_typeHidden', { "name": "backward_compat", "type": "boolean" }, { "name": "print_recipient", "type": "boolean" }, { "name": "print_directly", "type": "boolean" }, { "name": "shortcut" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 36,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptTypes.detail;
    this.ls_insert_handler = Lino.excerpts.ExcerptTypes.insert;
    var ww = this.containing_window;
    var content_type_display_disp4631 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var primary4632 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var certifying4633 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var name4634 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4635 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var build_method4636 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var template4637 = new Lino.SimpleRemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/template" }) }) });
    var body_template4638 = new Lino.SimpleRemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/body_template" }) }) });
    var id4639 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var attach_to_email4640 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var email_template4641 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/email_template" }) }) });
    var remark4642 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var content_type4643 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptTypes/content_type" }) }) });
    var backward_compat4644 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var print_recipient4645 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var print_directly4646 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var shortcut4647 = new Ext.form.TextField({ "hidden": true, "maxLength": 50, "selectOnFocus": true });
    var mobile_item_disp4648 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4649 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4650 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4651 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      template4637.setContextValue('build_method', record ? record.data['build_methodHidden'] : undefined);
      template4637.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      body_template4638.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      email_template4641.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      remark4642.refresh();
    };
    this.onRender = function(ct, position) {
      build_method4636.on('change',Lino.chooser_handler(template4637,'build_method'));
      content_type4643.on('change',Lino.chooser_handler(template4637,'content_type'));
      content_type4643.on('change',Lino.chooser_handler(body_template4638,'content_type'));
      content_type4643.on('change',Lino.chooser_handler(email_template4641,'content_type'));
      Lino.excerpts.ExcerptTypes.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "content_type_display", "editable": false, "header": "Model", "sortable": false, "tooltip": "(excerpts.ExcerptTypes.content_type_display) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "primary", "editable": true, "filter": { "type": "boolean" }, "header": "Primary", "sortable": false, "tooltip": "(excerpts.ExcerptTypes.primary) Whether this is the default type to use for this model. There's at most one primary type per model. Enabling this field will automatically make the other types non-primary.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 2, "dataIndex": "certifying", "editable": true, "filter": { "type": "boolean" }, "header": "Tsertifitseeriv", "sortable": false, "tooltip": "(excerpts.ExcerptTypes.certifying) Whether an excerpt of this type is a unique printout.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 3, "dataIndex": "name", "editable": true, "editor": name4634, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(excerpts.ExcerptTypes.name) The designation of this excerpt type.\nOne field for every language.", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "name_et", "editable": true, "editor": name_et4635, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(excerpts.ExcerptTypes.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "build_method", "editable": true, "editor": build_method4636, "filter": { "type": "string" }, "header": "Build method", "sortable": false, "tooltip": "(excerpts.ExcerptTypes.build_method) See lino.modlib.printing.mixins.PrintableType.build_method.", "width": Lino.chars2width(24) }, { "colIndex": 6, "dataIndex": "template", "editable": true, "editor": template4637, "filter": { "type": "string" }, "header": "Template", "sortable": false, "tooltip": "(excerpts.ExcerptTypes.template) The main template to be used when printing an excerpt of this type.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "body_template", "editable": true, "editor": body_template4638, "filter": { "type": "string" }, "header": "Body template", "sortable": false, "tooltip": "(excerpts.ExcerptTypes.body_template) The body template to be used when         rendering a printable of this type. This is a list of files         with extension `.body.html`.", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 8, "dataIndex": "id", "editable": true, "editor": id4639, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(excerpts.ExcerptTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "attach_to_email", "editable": true, "filter": { "type": "boolean" }, "header": "Attach to email", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.attach_to_email) Whether the printable file should be attached to the email\nwhen creating an email from a mailable of this type.\n", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "email_template", "editable": true, "editor": email_template4641, "filter": { "type": "string" }, "header": "Email template", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.email_template) The name of the file to be used as template when creating an email from a mailable of this type.", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "remark", "editable": true, "editor": remark4642, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 12, "dataIndex": "content_type", "editable": true, "editor": content_type4643, "filter": { "type": "string" }, "header": "Model", "hidden": true, "renderer": Lino.fk_renderer('content_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptTypes.content_type) The model that can issue printouts of this type.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "backward_compat", "editable": true, "filter": { "type": "boolean" }, "header": "Backward compatible", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.backward_compat) Check this to have `this` in template context point to owner instead of excerpt.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "print_recipient", "editable": true, "filter": { "type": "boolean" }, "header": "Print recipient", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.print_recipient) Whether to print a recipient field in document.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "print_directly", "editable": true, "filter": { "type": "boolean" }, "header": "Print directly", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.print_directly) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "shortcut", "editable": true, "editor": shortcut4647, "filter": { "type": "string" }, "header": "Excerpt shortcut", "hidden": true, "sortable": true, "tooltip": "(excerpts.ExcerptTypes.shortcut) Optional pointer to a shortcut field.  If this is not empty, then\nthe given shortcut field will manage excerpts of this type.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.excerpts.ExcerptTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.ExcerptTypes.insertPanel = Ext.extend(Lino.excerpts.ExcerptTypes.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/excerpts/ExcerptTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptTypes.detail;
    this.ls_insert_handler = Lino.excerpts.ExcerptTypes.insert;
    Lino.excerpts.ExcerptTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptTypes.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.excerpts.ExcerptTypes.insertPanel(p);
});
Lino.excerpts.ExcerptTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.ExcerptTypes.detailPanel = Ext.extend(Lino.excerpts.ExcerptTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/excerpts/ExcerptTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptTypes.detail;
    this.ls_insert_handler = Lino.excerpts.ExcerptTypes.insert;
    Lino.excerpts.ExcerptTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.ExcerptTypes.detailPanel(p);
});
Lino.excerpts.ExcerptTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.ExcerptTypes.GridPanel(p);
});
Lino.excerpts.ExcerptTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class excerpts.Excerpts
Lino.excerpts.Excerpts.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/excerpts/Excerpts",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/Excerpts','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/Excerpts','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" } ],
  cell_edit : true,
  title : "V\u00e4ljav\u00f5ted",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "excerpt_type" }, 'excerpt_typeHidden', { "name": "owner" }, { "name": "company" }, 'companyHidden', { "name": "language" }, 'languageHidden', { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "body_template_content" }, { "name": "preview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 37,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.Excerpts.detail;
    var ww = this.containing_window;
    var id4653 = new Ext.form.NumberField({ "selectOnFocus": true });
    var excerpt_type4654 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/excerpt_type" }) }) });
    var owner_disp4655 = new Ext.form.DisplayField({ "disabled": true });
    var company4656 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/company" }) }) });
    var language4657 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var build_time4658 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var build_method4659 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var contact_person4660 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/contact_person" }) }) });
    var contact_role4661 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/contact_role" }) }) });
    var user4662 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/user" }) }) });
    var owner_type4663 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/owner_type" }) }) });
    var owner_id4664 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/Excerpts/owner_id" }) }) });
    var body_template_content4665 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body template" });
    var preview_htmlbox4666 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "preview", "title": "Eelvaade", "value": "<br/>" });
    var mobile_item_disp4667 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4668 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4669 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4670 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      excerpt_type4654.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person4660.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4664.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body_template_content4665.refresh();
      preview_htmlbox4666.refresh();
    };
    this.onRender = function(ct, position) {
      owner_disp4655.on('change',Lino.chooser_handler(excerpt_type4654,'owner'));
      company4656.on('change',Lino.chooser_handler(contact_person4660,'company'));
      owner_type4663.on('change',Lino.chooser_handler(owner_id4664,'owner_type'));
      Lino.excerpts.Excerpts.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4653, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(excerpts.Excerpts.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "excerpt_type", "editable": true, "editor": excerpt_type4654, "filter": { "type": "string" }, "header": "V\u00e4ljav\u00f5teliik", "renderer": Lino.fk_renderer('excerpt_typeHidden','Lino.excerpts.ExcerptTypes.detail'), "sortable": false, "tooltip": "(excerpts.Excerpts.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(excerpts.Excerpts.owner) The object being printed by this excerpt.\nSee Controllable.owner.", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company4656, "filter": { "type": "string" }, "header": "Saaja (Firma)", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(excerpts.Excerpts.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "language", "editable": true, "editor": language4657, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(excerpts.Excerpts.language) The language used for printing this excerpt.", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "build_time", "editable": false, "header": "build time", "sortable": true, "tooltip": "(excerpts.Excerpts.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "build_method", "editable": true, "editor": build_method4659, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 7, "dataIndex": "contact_person", "editable": true, "editor": contact_person4660, "filter": { "type": "string" }, "header": "Saaja (Isik)", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(excerpts.Excerpts.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_role", "editable": true, "editor": contact_role4661, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user4662, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(excerpts.Excerpts.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner_type", "editable": true, "editor": owner_type4663, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(excerpts.Excerpts.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "owner_id", "editable": true, "editor": owner_id4664, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 12, "dataIndex": "body_template_content", "editable": false, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.body_template_content) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "preview", "editable": false, "header": "Eelvaade", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.preview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(excerpts.Excerpts.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.excerpts.Excerpts.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.Excerpts.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.Excerpts.detailPanel = Ext.extend(Lino.excerpts.Excerpts.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" } ],
  ls_url: "/excerpts/Excerpts",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.Excerpts.detail;
    Lino.excerpts.Excerpts.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.Excerpts.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.Excerpts.detailPanel(p);
});
Lino.excerpts.Excerpts.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.excerpts.Excerpts.ParamsPanel({});
  return new Lino.excerpts.Excerpts.GridPanel(p);
});
Lino.excerpts.Excerpts.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Excerpts.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Excerpts", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class excerpts.AllExcerpts
Lino.excerpts.AllExcerpts.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/excerpts/AllExcerpts",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/AllExcerpts','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/AllExcerpts','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  cell_edit : true,
  title : "V\u00e4ljav\u00f5ted",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "excerpt_type" }, 'excerpt_typeHidden', { "name": "owner" }, { "name": "company" }, 'companyHidden', { "name": "language" }, 'languageHidden', { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "body_template_content" }, { "name": "preview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 37,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.AllExcerpts.detail;
    var ww = this.containing_window;
    var id4672 = new Ext.form.NumberField({ "selectOnFocus": true });
    var excerpt_type4673 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/excerpt_type" }) }) });
    var owner_disp4674 = new Ext.form.DisplayField({ "disabled": true });
    var company4675 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/company" }) }) });
    var language4676 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var build_time4677 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var build_method4678 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var contact_person4679 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/contact_person" }) }) });
    var contact_role4680 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/contact_role" }) }) });
    var user4681 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/user" }) }) });
    var owner_type4682 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/owner_type" }) }) });
    var owner_id4683 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/AllExcerpts/owner_id" }) }) });
    var body_template_content4684 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body template" });
    var preview_htmlbox4685 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "preview", "title": "Eelvaade", "value": "<br/>" });
    var mobile_item_disp4686 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4687 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4688 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4689 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      excerpt_type4673.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person4679.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4683.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body_template_content4684.refresh();
      preview_htmlbox4685.refresh();
    };
    this.onRender = function(ct, position) {
      owner_disp4674.on('change',Lino.chooser_handler(excerpt_type4673,'owner'));
      company4675.on('change',Lino.chooser_handler(contact_person4679,'company'));
      owner_type4682.on('change',Lino.chooser_handler(owner_id4683,'owner_type'));
      Lino.excerpts.AllExcerpts.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4672, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(excerpts.AllExcerpts.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "excerpt_type", "editable": true, "editor": excerpt_type4673, "filter": { "type": "string" }, "header": "V\u00e4ljav\u00f5teliik", "renderer": Lino.fk_renderer('excerpt_typeHidden','Lino.excerpts.ExcerptTypes.detail'), "sortable": false, "tooltip": "(excerpts.AllExcerpts.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(excerpts.AllExcerpts.owner) The object being printed by this excerpt.\nSee Controllable.owner.", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company4675, "filter": { "type": "string" }, "header": "Saaja (Firma)", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(excerpts.AllExcerpts.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "language", "editable": true, "editor": language4676, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(excerpts.AllExcerpts.language) The language used for printing this excerpt.", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "build_time", "editable": false, "header": "build time", "sortable": true, "tooltip": "(excerpts.AllExcerpts.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "build_method", "editable": true, "editor": build_method4678, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 7, "dataIndex": "contact_person", "editable": true, "editor": contact_person4679, "filter": { "type": "string" }, "header": "Saaja (Isik)", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(excerpts.AllExcerpts.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_role", "editable": true, "editor": contact_role4680, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user4681, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(excerpts.AllExcerpts.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner_type", "editable": true, "editor": owner_type4682, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(excerpts.AllExcerpts.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "owner_id", "editable": true, "editor": owner_id4683, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 12, "dataIndex": "body_template_content", "editable": false, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.body_template_content) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "preview", "editable": false, "header": "Eelvaade", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.preview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(excerpts.AllExcerpts.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.excerpts.AllExcerpts.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.AllExcerpts.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.AllExcerpts.detailPanel = Ext.extend(Lino.excerpts.Excerpts.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  ls_url: "/excerpts/AllExcerpts",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.AllExcerpts.detail;
    Lino.excerpts.AllExcerpts.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.AllExcerpts.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.AllExcerpts.detailPanel(p);
});
Lino.excerpts.AllExcerpts.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.excerpts.Excerpts.ParamsPanel({});
  return new Lino.excerpts.AllExcerpts.GridPanel(p);
});
Lino.excerpts.AllExcerpts.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.AllExcerpts.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/AllExcerpts", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class excerpts.MyExcerpts
Lino.excerpts.MyExcerpts.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/excerpts/MyExcerpts",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/MyExcerpts','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/MyExcerpts','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  cell_edit : true,
  title : "Minu V\u00e4ljav\u00f5ted",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "name": "build_time" }, { "name": "excerpt_type" }, 'excerpt_typeHidden', { "name": "id", "type": "int" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "language" }, 'languageHidden', { "name": "owner" }, { "name": "body_template_content" }, { "name": "preview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 37,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.MyExcerpts.detail;
    var ww = this.containing_window;
    var build_time4691 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var excerpt_type4692 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/excerpt_type" }) }) });
    var id4693 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var build_method4694 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company4695 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/company" }) }) });
    var contact_person4696 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/contact_person" }) }) });
    var contact_role4697 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/contact_role" }) }) });
    var user4698 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/user" }) }) });
    var owner_type4699 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/owner_type" }) }) });
    var owner_id4700 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/MyExcerpts/owner_id" }) }) });
    var language4701 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp4702 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var body_template_content4703 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body template" });
    var preview_htmlbox4704 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "preview", "title": "Eelvaade", "value": "<br/>" });
    var mobile_item_disp4705 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4706 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4707 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4708 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      excerpt_type4692.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person4696.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id4700.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body_template_content4703.refresh();
      preview_htmlbox4704.refresh();
    };
    this.onRender = function(ct, position) {
      owner_disp4702.on('change',Lino.chooser_handler(excerpt_type4692,'owner'));
      company4695.on('change',Lino.chooser_handler(contact_person4696,'company'));
      owner_type4699.on('change',Lino.chooser_handler(owner_id4700,'owner_type'));
      Lino.excerpts.MyExcerpts.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "build_time", "editable": false, "header": "build time", "sortable": true, "tooltip": "(excerpts.MyExcerpts.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "excerpt_type", "editable": true, "editor": excerpt_type4692, "filter": { "type": "string" }, "header": "V\u00e4ljav\u00f5teliik", "renderer": Lino.fk_renderer('excerpt_typeHidden','Lino.excerpts.ExcerptTypes.detail'), "sortable": false, "tooltip": "(excerpts.MyExcerpts.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4693, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(excerpts.MyExcerpts.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "build_method", "editable": true, "editor": build_method4694, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 4, "dataIndex": "company", "editable": true, "editor": company4695, "filter": { "type": "string" }, "header": "Saaja (Firma)", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(excerpts.MyExcerpts.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "contact_person", "editable": true, "editor": contact_person4696, "filter": { "type": "string" }, "header": "Saaja (Isik)", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(excerpts.MyExcerpts.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "contact_role", "editable": true, "editor": contact_role4697, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user4698, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(excerpts.MyExcerpts.user) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_type", "editable": true, "editor": owner_type4699, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(excerpts.MyExcerpts.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner_id", "editable": true, "editor": owner_id4700, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "language", "editable": true, "editor": language4701, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.language) The language used for printing this excerpt.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.owner) The object being printed by this excerpt.\nSee Controllable.owner.", "width": Lino.chars2width(11) }, { "colIndex": 12, "dataIndex": "body_template_content", "editable": false, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.body_template_content) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "preview", "editable": false, "header": "Eelvaade", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.preview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(excerpts.MyExcerpts.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.excerpts.MyExcerpts.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.MyExcerpts.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.MyExcerpts.detailPanel = Ext.extend(Lino.excerpts.Excerpts.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  ls_url: "/excerpts/MyExcerpts",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.MyExcerpts.detail;
    Lino.excerpts.MyExcerpts.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.MyExcerpts.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.MyExcerpts.detailPanel(p);
});
Lino.excerpts.MyExcerpts.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.excerpts.Excerpts.ParamsPanel({});
  return new Lino.excerpts.MyExcerpts.GridPanel(p);
});
Lino.excerpts.MyExcerpts.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.MyExcerpts.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/MyExcerpts", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.CommentTypes
Lino.comments.CommentTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/CommentTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/CommentTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/CommentTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Comment Types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 39,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentTypes.detail;
    this.ls_insert_handler = Lino.comments.CommentTypes.insert;
    var ww = this.containing_window;
    var name4710 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4711 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id4712 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp4713 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4714 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4715 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4716 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name4710, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(comments.CommentTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et4711, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(comments.CommentTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4712, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(comments.CommentTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.CommentTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.CommentTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.comments.CommentTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentTypes.insertPanel = Ext.extend(Lino.comments.CommentTypes.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/CommentTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentTypes.detail;
    this.ls_insert_handler = Lino.comments.CommentTypes.insert;
    Lino.comments.CommentTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentTypes.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.CommentTypes.insertPanel(p);
});
Lino.comments.CommentTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentTypes.detailPanel = Ext.extend(Lino.comments.CommentTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/CommentTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentTypes.detail;
    this.ls_insert_handler = Lino.comments.CommentTypes.insert;
    Lino.comments.CommentTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.CommentTypes.detailPanel(p);
});
Lino.comments.CommentTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.CommentTypes.GridPanel(p);
});
Lino.comments.CommentTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.Comments
Lino.comments.Comments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/Comments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/Comments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/Comments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "short_text" }, { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "owner" }, { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.Comments.detail;
    this.ls_insert_handler = Lino.comments.Comments.insert;
    var ww = this.containing_window;
    var id4718 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified4719 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var created4720 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var user4721 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var owner_type4722 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/owner_type" }) }) });
    var owner_id4723 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/owner_id" }) }) });
    var short_text4724 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var reply_to4725 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/reply_to" }) }) });
    var more_text4726 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "More text" });
    var comment_type4727 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/Comments/comment_type" }) }) });
    var owner_disp4728 = new Ext.form.DisplayField({ "disabled": true });
    var created_natural_disp4729 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4730 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4731 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4732 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4733 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id4723.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      short_text4724.refresh();
      more_text4726.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type4722.on('change',Lino.chooser_handler(owner_id4723,'owner_type'));
      Lino.comments.Comments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4718, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(comments.Comments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "modified", "editable": false, "header": "Muudatud", "sortable": true, "tooltip": "(comments.Comments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(comments.Comments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 3, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.Comments.user) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type4722, "filter": { "type": "string" }, "header": "Controlled by (type)", "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.Comments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id4723, "filter": { "type": "string" }, "header": "Controlled by (object)", "sortable": false, "tooltip": "(comments.Comments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "short_text", "editable": true, "editor": short_text4724, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.Comments.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "reply_to", "editable": true, "editor": reply_to4725, "filter": { "type": "string" }, "header": "Reply to", "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.Comments.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "more_text", "editable": true, "editor": more_text4726, "filter": { "type": "string" }, "header": "More text", "sortable": false, "tooltip": "(comments.Comments.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "comment_type", "editable": true, "editor": comment_type4727, "filter": { "type": "string" }, "header": "Comment Type", "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.Comments.comment_type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(comments.Comments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.Comments.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.Comments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.Comments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.Comments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.Comments.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.comments.Comments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.Comments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.Comments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.Comments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.Comments.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/Comments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.Comments.detail;
    this.ls_insert_handler = Lino.comments.Comments.insert;
    Lino.comments.Comments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.Comments.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.Comments.insertPanel(p);
});
Lino.comments.Comments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.Comments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.Comments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.Comments.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/Comments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.Comments.detail;
    this.ls_insert_handler = Lino.comments.Comments.insert;
    Lino.comments.Comments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.Comments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.Comments.detailPanel(p);
});
Lino.comments.Comments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.Comments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.Comments.GridPanel(p);
});
Lino.comments.Comments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/Comments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.MyComments
Lino.comments.MyComments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/MyComments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/MyComments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/MyComments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Minu Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "modified" }, { "name": "short_text" }, { "name": "owner" }, { "name": "id", "type": "int" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.MyComments.detail;
    this.ls_insert_handler = Lino.comments.MyComments.insert;
    var ww = this.containing_window;
    var modified4735 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var short_text4736 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var owner_disp4737 = new Ext.form.DisplayField({ "disabled": true });
    var id4738 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var created4739 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var user4740 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var owner_type4741 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/MyComments/owner_type" }) }) });
    var owner_id4742 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/MyComments/owner_id" }) }) });
    var reply_to4743 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/MyComments/reply_to" }) }) });
    var more_text4744 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "More text" });
    var comment_type4745 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/MyComments/comment_type" }) }) });
    var created_natural_disp4746 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4747 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4748 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4749 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4750 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      short_text4736.refresh();
      owner_id4742.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      more_text4744.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type4741.on('change',Lino.chooser_handler(owner_id4742,'owner_type'));
      Lino.comments.MyComments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "modified", "editable": false, "header": "Muudatud", "sortable": true, "tooltip": "(comments.MyComments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "short_text", "editable": true, "editor": short_text4736, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.MyComments.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 2, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(comments.MyComments.owner) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id4738, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(comments.MyComments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(comments.MyComments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.MyComments.user) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type4741, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.MyComments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id4742, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "reply_to", "editable": true, "editor": reply_to4743, "filter": { "type": "string" }, "header": "Reply to", "hidden": true, "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.MyComments.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "more_text", "editable": true, "editor": more_text4744, "filter": { "type": "string" }, "header": "More text", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 10, "dataIndex": "comment_type", "editable": true, "editor": comment_type4745, "filter": { "type": "string" }, "header": "Comment Type", "hidden": true, "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.MyComments.comment_type) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.MyComments.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.comments.MyComments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.MyComments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.MyComments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.MyComments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.MyComments.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/MyComments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.MyComments.detail;
    this.ls_insert_handler = Lino.comments.MyComments.insert;
    Lino.comments.MyComments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.MyComments.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.MyComments.insertPanel(p);
});
Lino.comments.MyComments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.MyComments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.MyComments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.MyComments.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/MyComments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.MyComments.detail;
    this.ls_insert_handler = Lino.comments.MyComments.insert;
    Lino.comments.MyComments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.MyComments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.MyComments.detailPanel(p);
});
Lino.comments.MyComments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.MyComments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.MyComments.GridPanel(p);
});
Lino.comments.MyComments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/MyComments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.CommentsByX
Lino.comments.CommentsByX.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/CommentsByX",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/CommentsByX','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/CommentsByX','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "short_text" }, { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "owner" }, { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByX.detail;
    this.ls_insert_handler = Lino.comments.CommentsByX.insert;
    var ww = this.containing_window;
    var id4752 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified4753 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var created4754 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var user4755 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var owner_type4756 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByX/owner_type" }) }) });
    var owner_id4757 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByX/owner_id" }) }) });
    var short_text4758 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var reply_to4759 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByX/reply_to" }) }) });
    var more_text4760 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "More text" });
    var comment_type4761 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByX/comment_type" }) }) });
    var owner_disp4762 = new Ext.form.DisplayField({ "disabled": true });
    var created_natural_disp4763 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4764 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4765 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4766 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4767 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id4757.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      short_text4758.refresh();
      more_text4760.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type4756.on('change',Lino.chooser_handler(owner_id4757,'owner_type'));
      Lino.comments.CommentsByX.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4752, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(comments.CommentsByX.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "modified", "editable": false, "header": "Muudatud", "sortable": true, "tooltip": "(comments.CommentsByX.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(comments.CommentsByX.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 3, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.CommentsByX.user) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type4756, "filter": { "type": "string" }, "header": "Controlled by (type)", "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.CommentsByX.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id4757, "filter": { "type": "string" }, "header": "Controlled by (object)", "sortable": false, "tooltip": "(comments.CommentsByX.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "short_text", "editable": true, "editor": short_text4758, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.CommentsByX.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "reply_to", "editable": true, "editor": reply_to4759, "filter": { "type": "string" }, "header": "Reply to", "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.CommentsByX.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "more_text", "editable": true, "editor": more_text4760, "filter": { "type": "string" }, "header": "More text", "sortable": false, "tooltip": "(comments.CommentsByX.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "comment_type", "editable": true, "editor": comment_type4761, "filter": { "type": "string" }, "header": "Comment Type", "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.CommentsByX.comment_type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(comments.CommentsByX.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByX.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByX.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByX.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByX.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByX.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.comments.CommentsByX.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByX.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByX.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByX.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentsByX.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/CommentsByX",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByX.detail;
    this.ls_insert_handler = Lino.comments.CommentsByX.insert;
    Lino.comments.CommentsByX.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByX.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.CommentsByX.insertPanel(p);
});
Lino.comments.CommentsByX.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByX.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByX.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentsByX.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/CommentsByX",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByX.detail;
    this.ls_insert_handler = Lino.comments.CommentsByX.insert;
    Lino.comments.CommentsByX.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByX.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.CommentsByX.detailPanel(p);
});
Lino.comments.CommentsByX.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByX.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.CommentsByX.GridPanel(p);
});
Lino.comments.CommentsByX.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByX", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.AllComments
Lino.comments.AllComments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/AllComments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/AllComments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/AllComments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "short_text" }, { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "owner" }, { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.AllComments.detail;
    this.ls_insert_handler = Lino.comments.AllComments.insert;
    var ww = this.containing_window;
    var id4769 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified4770 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var created4771 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var user4772 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var owner_type4773 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/AllComments/owner_type" }) }) });
    var owner_id4774 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/AllComments/owner_id" }) }) });
    var short_text4775 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var reply_to4776 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/AllComments/reply_to" }) }) });
    var more_text4777 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "More text" });
    var comment_type4778 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/AllComments/comment_type" }) }) });
    var owner_disp4779 = new Ext.form.DisplayField({ "disabled": true });
    var created_natural_disp4780 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4781 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4782 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4783 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4784 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id4774.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      short_text4775.refresh();
      more_text4777.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type4773.on('change',Lino.chooser_handler(owner_id4774,'owner_type'));
      Lino.comments.AllComments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4769, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(comments.AllComments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "modified", "editable": false, "header": "Muudatud", "sortable": true, "tooltip": "(comments.AllComments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(comments.AllComments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 3, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.AllComments.user) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type4773, "filter": { "type": "string" }, "header": "Controlled by (type)", "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.AllComments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id4774, "filter": { "type": "string" }, "header": "Controlled by (object)", "sortable": false, "tooltip": "(comments.AllComments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "short_text", "editable": true, "editor": short_text4775, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.AllComments.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "reply_to", "editable": true, "editor": reply_to4776, "filter": { "type": "string" }, "header": "Reply to", "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.AllComments.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "more_text", "editable": true, "editor": more_text4777, "filter": { "type": "string" }, "header": "More text", "sortable": false, "tooltip": "(comments.AllComments.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "comment_type", "editable": true, "editor": comment_type4778, "filter": { "type": "string" }, "header": "Comment Type", "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.AllComments.comment_type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(comments.AllComments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.AllComments.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.AllComments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.AllComments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.AllComments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.AllComments.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.comments.AllComments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.AllComments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.AllComments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.AllComments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.AllComments.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/AllComments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.AllComments.detail;
    this.ls_insert_handler = Lino.comments.AllComments.insert;
    Lino.comments.AllComments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.AllComments.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.AllComments.insertPanel(p);
});
Lino.comments.AllComments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.AllComments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.AllComments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.AllComments.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/AllComments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.AllComments.detail;
    this.ls_insert_handler = Lino.comments.AllComments.insert;
    Lino.comments.AllComments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.AllComments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.AllComments.detailPanel(p);
});
Lino.comments.AllComments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.AllComments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.AllComments.GridPanel(p);
});
Lino.comments.AllComments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/AllComments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.RecentComments
Lino.comments.RecentComments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/RecentComments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/RecentComments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/RecentComments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Recent Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "short_text" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "owner" }, { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.RecentComments.detail;
    this.ls_insert_handler = Lino.comments.RecentComments.insert;
    var ww = this.containing_window;
    var short_text4786 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var created4787 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var user4788 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var id4789 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4790 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var owner_type4791 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/RecentComments/owner_type" }) }) });
    var owner_id4792 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/RecentComments/owner_id" }) }) });
    var reply_to4793 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/RecentComments/reply_to" }) }) });
    var more_text4794 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "More text" });
    var comment_type4795 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/RecentComments/comment_type" }) }) });
    var owner_disp4796 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var created_natural_disp4797 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4798 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4799 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4800 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4801 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      short_text4786.refresh();
      owner_id4792.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      more_text4794.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type4791.on('change',Lino.chooser_handler(owner_id4792,'owner_type'));
      Lino.comments.RecentComments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "short_text", "editable": true, "editor": short_text4786, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.RecentComments.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 1, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(comments.RecentComments.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.RecentComments.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id4789, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(comments.RecentComments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(comments.RecentComments.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type4791, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.RecentComments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id4792, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "reply_to", "editable": true, "editor": reply_to4793, "filter": { "type": "string" }, "header": "Reply to", "hidden": true, "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.RecentComments.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "more_text", "editable": true, "editor": more_text4794, "filter": { "type": "string" }, "header": "More text", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "comment_type", "editable": true, "editor": comment_type4795, "filter": { "type": "string" }, "header": "Comment Type", "hidden": true, "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.RecentComments.comment_type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.RecentComments.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.comments.RecentComments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.RecentComments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.RecentComments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.RecentComments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.RecentComments.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/RecentComments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.RecentComments.detail;
    this.ls_insert_handler = Lino.comments.RecentComments.insert;
    Lino.comments.RecentComments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.RecentComments.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.RecentComments.insertPanel(p);
});
Lino.comments.RecentComments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.RecentComments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.RecentComments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.RecentComments.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/RecentComments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.RecentComments.detail;
    this.ls_insert_handler = Lino.comments.RecentComments.insert;
    Lino.comments.RecentComments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.RecentComments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.RecentComments.detailPanel(p);
});
Lino.comments.RecentComments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.RecentComments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.RecentComments.GridPanel(p);
});
Lino.comments.RecentComments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/RecentComments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class changes.Changes
Lino.changes.Changes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/changes/Changes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/changes/Changes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/changes/Changes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" } ],
  cell_edit : true,
  title : "Changes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "time" }, { "name": "type" }, 'typeHidden', { "name": "user" }, 'userHidden', { "name": "object_type" }, 'object_typeHidden', { "name": "object_id" }, 'object_idHidden', { "name": "master_type" }, 'master_typeHidden', { "name": "master_id" }, 'master_idHidden', { "name": "diff" }, { "name": "changed_fields" }, { "name": "object" }, { "name": "master" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 40,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.changes.Changes.detail;
    var ww = this.containing_window;
    var id4803 = new Ext.form.NumberField({ "selectOnFocus": true });
    var time4804 = new Ext.form.DisplayField({ "allowBlank": false, "selectOnFocus": true, "value": "<br>" });
    var type4805 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.changes.ChangeTypes });
    var user4806 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/user" }) }) });
    var object_type4807 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/object_type" }) }) });
    var object_id4808 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/object_id" }) }) });
    var master_type4809 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/master_type" }) }) });
    var master_id4810 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/Changes/master_id" }) }) });
    var diff4811 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var changed_fields4812 = new Ext.form.TextField({ "maxLength": 250, "selectOnFocus": true });
    var object_disp4813 = new Ext.form.DisplayField({ "disabled": true });
    var master_disp4814 = new Ext.form.DisplayField({ "disabled": true });
    var mobile_item_disp4815 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4816 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4817 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4818 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.onRender = function(ct, position) {
      object_type4807.on('change',Lino.chooser_handler(object_id4808,'object_type'));
      master_type4809.on('change',Lino.chooser_handler(master_id4810,'master_type'));
      Lino.changes.Changes.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4803, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(changes.Changes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "time", "editable": true, "editor": time4804, "header": "time", "sortable": true, "tooltip": "(changes.Changes.time) ", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "type", "editable": true, "editor": type4805, "filter": { "type": "string" }, "header": "Change Type", "sortable": false, "tooltip": "(changes.Changes.type) ", "width": Lino.chars2width(16) }, { "colIndex": 3, "dataIndex": "user", "editable": true, "editor": user4806, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(changes.Changes.user) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "object_type", "editable": true, "editor": object_type4807, "filter": { "type": "string" }, "header": "Object type", "renderer": Lino.fk_renderer('object_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(changes.Changes.object_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "object_id", "editable": true, "editor": object_id4808, "filter": { "type": "string" }, "header": "object id", "sortable": false, "tooltip": "(changes.Changes.object_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "master_type", "editable": true, "editor": master_type4809, "filter": { "type": "string" }, "header": "Master type", "renderer": Lino.fk_renderer('master_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(changes.Changes.master_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "master_id", "editable": true, "editor": master_id4810, "filter": { "type": "string" }, "header": "master id", "sortable": false, "tooltip": "(changes.Changes.master_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "diff", "editable": true, "editor": diff4811, "filter": { "type": "string" }, "header": "Changes", "sortable": false, "tooltip": "(changes.Changes.diff) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "changed_fields", "editable": true, "editor": changed_fields4812, "filter": { "type": "string" }, "header": "Fields", "sortable": true, "tooltip": "(changes.Changes.changed_fields) ", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "object", "editable": false, "header": "Object", "sortable": false, "tooltip": "(changes.Changes.object) The database object which has been modified.", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "master", "editable": false, "header": "Master", "sortable": false, "tooltip": "(changes.Changes.master) The database object which acts as \"master\".", "width": Lino.chars2width(11) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(changes.Changes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(changes.Changes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(changes.Changes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(changes.Changes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.changes.Changes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.Changes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/Changes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.Changes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/Changes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.Changes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/Changes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.Changes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/Changes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.changes.Changes.detailPanel = Ext.extend(Lino.changes.Changes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/changes/Changes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.changes.Changes.detail;
    Lino.changes.Changes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.Changes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.changes.Changes.detailPanel(p);
});
Lino.changes.Changes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.changes.Changes.ParamsPanel({});
  return new Lino.changes.Changes.GridPanel(p);
});

// js_render_GridPanel_class tickets.ProjectTypes
Lino.tickets.ProjectTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/ProjectTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Project Types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 44,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectTypes.detail;
    this.ls_insert_handler = Lino.tickets.ProjectTypes.insert;
    var ww = this.containing_window;
    var name4820 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4821 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id4822 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp4823 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4824 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4825 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4826 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name4820, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(tickets.ProjectTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et4821, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(tickets.ProjectTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4822, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.ProjectTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectTypes.insertPanel = Ext.extend(Lino.tickets.ProjectTypes.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/ProjectTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectTypes.detail;
    this.ls_insert_handler = Lino.tickets.ProjectTypes.insert;
    Lino.tickets.ProjectTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectTypes.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.ProjectTypes.insertPanel(p);
});
Lino.tickets.ProjectTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectTypes.detailPanel = Ext.extend(Lino.tickets.ProjectTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/ProjectTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectTypes.detail;
    this.ls_insert_handler = Lino.tickets.ProjectTypes.insert;
    Lino.tickets.ProjectTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectTypes.detailPanel(p);
});
Lino.tickets.ProjectTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectTypes.GridPanel(p);
});
Lino.tickets.ProjectTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketTypes
Lino.tickets.TicketTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikuliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 45,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketTypes.detail;
    this.ls_insert_handler = Lino.tickets.TicketTypes.insert;
    var ww = this.containing_window;
    var name4828 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et4829 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id4830 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp4831 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4832 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4833 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4834 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name4828, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(tickets.TicketTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et4829, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(tickets.TicketTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id4830, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.TicketTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketTypes.insertPanel = Ext.extend(Lino.tickets.TicketTypes.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketTypes.detail;
    this.ls_insert_handler = Lino.tickets.TicketTypes.insert;
    Lino.tickets.TicketTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketTypes.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketTypes.insertPanel(p);
});
Lino.tickets.TicketTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketTypes.detailPanel = Ext.extend(Lino.tickets.TicketTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketTypes.detail;
    this.ls_insert_handler = Lino.tickets.TicketTypes.insert;
    Lino.tickets.TicketTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketTypes.detailPanel(p);
});
Lino.tickets.TicketTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketTypes.GridPanel(p);
});
Lino.tickets.TicketTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.Projects
Lino.tickets.Projects.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/Projects",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/Projects','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/Projects','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Eesm\u00e4rgid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "parent" }, 'parentHidden', { "name": "company" }, 'companyHidden', { "name": "private", "type": "boolean" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Projects.detail;
    this.ls_insert_handler = Lino.tickets.Projects.insert;
    var ww = this.containing_window;
    var ref4836 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name4837 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var parent4838 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/parent" }) }) });
    var company4839 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/company" }) }) });
    var private4840 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var id4841 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date4842 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date4843 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var contact_person4844 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/contact_person" }) }) });
    var contact_role4845 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/contact_role" }) }) });
    var closed4846 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time4847 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to4848 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/assign_to" }) }) });
    var type4849 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Projects/type" }) }) });
    var description4850 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template4851 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template4852 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type4853 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp4854 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4855 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4856 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4857 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4858 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp4859 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person4844.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description4850.refresh();
    };
    this.onRender = function(ct, position) {
      company4839.on('change',Lino.chooser_handler(contact_person4844,'company'));
      Lino.tickets.Projects.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref4836, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.Projects.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name4837, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.Projects.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent4838, "filter": { "type": "string" }, "header": "Parent", "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.Projects.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company4839, "filter": { "type": "string" }, "header": "Organisatsioon", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.Projects.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "sortable": false, "tooltip": "(tickets.Projects.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id4841, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.Projects.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date4842, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.Projects.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date4843, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.Projects.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "contact_person", "editable": true, "editor": contact_person4844, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.Projects.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "contact_role", "editable": true, "editor": contact_role4845, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time4847, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.Projects.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "assign_to", "editable": true, "editor": assign_to4848, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.Projects.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "type", "editable": true, "editor": type4849, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.Projects.type) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description4850, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template4851, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.Projects.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template4852, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.Projects.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type4853, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(tickets.Projects.children_summary) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.Projects.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Projects.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Projects.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Projects.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.Projects.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/Projects",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Projects.detail;
    this.ls_insert_handler = Lino.tickets.Projects.insert;
    Lino.tickets.Projects.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Projects.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.Projects.insertPanel(p);
});
Lino.tickets.Projects.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Projects.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Projects.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Projects.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.Projects.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/Projects",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Projects.detail;
    this.ls_insert_handler = Lino.tickets.Projects.insert;
    Lino.tickets.Projects.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Projects.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.Projects.detailPanel(p);
});
Lino.tickets.Projects.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Projects.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.Projects.GridPanel(p);
});
Lino.tickets.Projects.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Projects", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.AllProjects
Lino.tickets.AllProjects.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/AllProjects",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/AllProjects','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/AllProjects','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Eesm\u00e4rgid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "parent" }, 'parentHidden', { "name": "company" }, 'companyHidden', { "name": "private", "type": "boolean" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.AllProjects.detail;
    this.ls_insert_handler = Lino.tickets.AllProjects.insert;
    var ww = this.containing_window;
    var ref4861 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name4862 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var parent4863 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllProjects/parent" }) }) });
    var company4864 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllProjects/company" }) }) });
    var private4865 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var id4866 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date4867 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date4868 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var contact_person4869 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllProjects/contact_person" }) }) });
    var contact_role4870 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllProjects/contact_role" }) }) });
    var closed4871 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time4872 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to4873 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllProjects/assign_to" }) }) });
    var type4874 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllProjects/type" }) }) });
    var description4875 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template4876 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template4877 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type4878 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp4879 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4880 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4881 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4882 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4883 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp4884 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person4869.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description4875.refresh();
    };
    this.onRender = function(ct, position) {
      company4864.on('change',Lino.chooser_handler(contact_person4869,'company'));
      Lino.tickets.AllProjects.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref4861, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.AllProjects.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name4862, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.AllProjects.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent4863, "filter": { "type": "string" }, "header": "Parent", "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.AllProjects.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company4864, "filter": { "type": "string" }, "header": "Organisatsioon", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.AllProjects.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "sortable": false, "tooltip": "(tickets.AllProjects.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id4866, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.AllProjects.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date4867, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.AllProjects.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date4868, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.AllProjects.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "contact_person", "editable": true, "editor": contact_person4869, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.AllProjects.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "contact_role", "editable": true, "editor": contact_role4870, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time4872, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.AllProjects.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "assign_to", "editable": true, "editor": assign_to4873, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.AllProjects.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "type", "editable": true, "editor": type4874, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.AllProjects.type) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description4875, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template4876, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.AllProjects.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template4877, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.AllProjects.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type4878, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(tickets.AllProjects.children_summary) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.AllProjects.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.AllProjects.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllProjects.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllProjects.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.AllProjects.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/AllProjects",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.AllProjects.detail;
    this.ls_insert_handler = Lino.tickets.AllProjects.insert;
    Lino.tickets.AllProjects.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.AllProjects.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.AllProjects.insertPanel(p);
});
Lino.tickets.AllProjects.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllProjects.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllProjects.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllProjects.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.AllProjects.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/AllProjects",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.AllProjects.detail;
    this.ls_insert_handler = Lino.tickets.AllProjects.insert;
    Lino.tickets.AllProjects.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.AllProjects.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.AllProjects.detailPanel(p);
});
Lino.tickets.AllProjects.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllProjects.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.AllProjects.GridPanel(p);
});
Lino.tickets.AllProjects.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllProjects", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TopLevelProjects
Lino.tickets.TopLevelProjects.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "cellTpl": Lino.auto_height_cell_template, "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TopLevelProjects",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TopLevelProjects','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TopLevelProjects','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Projects (tree)",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "parent" }, 'parentHidden', { "name": "children_summary" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "private", "type": "boolean" }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TopLevelProjects.detail;
    this.ls_insert_handler = Lino.tickets.TopLevelProjects.insert;
    var ww = this.containing_window;
    var ref4886 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name4887 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var parent4888 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TopLevelProjects/parent" }) }) });
    var children_summary_disp4889 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id4890 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date4891 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date4892 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var company4893 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TopLevelProjects/company" }) }) });
    var contact_person4894 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TopLevelProjects/contact_person" }) }) });
    var contact_role4895 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TopLevelProjects/contact_role" }) }) });
    var private4896 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var closed4897 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time4898 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to4899 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TopLevelProjects/assign_to" }) }) });
    var type4900 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TopLevelProjects/type" }) }) });
    var description4901 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template4902 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template4903 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type4904 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp4905 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4906 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4907 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4908 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4909 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person4894.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description4901.refresh();
    };
    this.onRender = function(ct, position) {
      company4893.on('change',Lino.chooser_handler(contact_person4894,'company'));
      Lino.tickets.TopLevelProjects.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref4886, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.TopLevelProjects.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name4887, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.TopLevelProjects.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent4888, "filter": { "type": "string" }, "header": "Parent", "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TopLevelProjects.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "children_summary", "editable": false, "header": "Children", "sortable": false, "tooltip": "(tickets.TopLevelProjects.children_summary) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4890, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TopLevelProjects.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "start_date", "editable": true, "editor": start_date4891, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.TopLevelProjects.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "end_date", "editable": true, "editor": end_date4892, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.TopLevelProjects.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "company", "editable": true, "editor": company4893, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.TopLevelProjects.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_person", "editable": true, "editor": contact_person4894, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.TopLevelProjects.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "contact_role", "editable": true, "editor": contact_role4895, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "planned_time", "editable": true, "editor": planned_time4898, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TopLevelProjects.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 13, "dataIndex": "assign_to", "editable": true, "editor": assign_to4899, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TopLevelProjects.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "type", "editable": true, "editor": type4900, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.TopLevelProjects.type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "description", "editable": true, "editor": description4901, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.description) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template4902, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.TopLevelProjects.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template4903, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.TopLevelProjects.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type4904, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TopLevelProjects.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.TopLevelProjects.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TopLevelProjects.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TopLevelProjects.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TopLevelProjects.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TopLevelProjects.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TopLevelProjects",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TopLevelProjects.detail;
    this.ls_insert_handler = Lino.tickets.TopLevelProjects.insert;
    Lino.tickets.TopLevelProjects.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TopLevelProjects.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TopLevelProjects.insertPanel(p);
});
Lino.tickets.TopLevelProjects.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TopLevelProjects.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TopLevelProjects.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TopLevelProjects.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TopLevelProjects.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TopLevelProjects",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TopLevelProjects.detail;
    this.ls_insert_handler = Lino.tickets.TopLevelProjects.insert;
    Lino.tickets.TopLevelProjects.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TopLevelProjects.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TopLevelProjects.detailPanel(p);
});
Lino.tickets.TopLevelProjects.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TopLevelProjects.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.TopLevelProjects.GridPanel(p);
});
Lino.tickets.TopLevelProjects.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TopLevelProjects", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.Links
Lino.tickets.Links.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/Links",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/Links','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/Links','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Dependencies",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 14,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "type" }, 'typeHidden', { "name": "parent" }, 'parentHidden', { "name": "child" }, 'childHidden', { "name": "type_as_child" }, { "name": "type_as_parent" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 42,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Links.detail;
    this.ls_insert_handler = Lino.tickets.Links.insert;
    var ww = this.containing_window;
    var id4911 = new Ext.form.NumberField({ "selectOnFocus": true });
    var type4912 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.LinkTypes });
    var parent4913 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Links/parent" }) }) });
    var child4914 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Links/child" }) }) });
    var type_as_child_disp4915 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_as_parent_disp4916 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4917 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4918 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4919 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp4920 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4911, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.Links.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type4912, "filter": { "type": "string" }, "header": "Dependency type", "sortable": false, "tooltip": "(tickets.Links.type) ", "width": Lino.chars2width(13) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent4913, "filter": { "type": "string" }, "header": "Parent", "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.Links.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "child", "editable": true, "editor": child4914, "filter": { "type": "string" }, "header": "Child", "renderer": Lino.fk_renderer('childHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.Links.child) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "type_as_child", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(tickets.Links.type_as_child) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "type_as_parent", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(tickets.Links.type_as_parent) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Links.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Links.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.Links.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.Links.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.Links.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Links.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Links.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Links.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.Links.insertPanel = Ext.extend(Lino.tickets.Links.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/Links",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Links.detail;
    this.ls_insert_handler = Lino.tickets.Links.insert;
    Lino.tickets.Links.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Links.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.Links.insertPanel(p);
});
Lino.tickets.Links.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Links.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Links.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.Links.detailPanel = Ext.extend(Lino.tickets.Links.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/Links",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Links.detail;
    this.ls_insert_handler = Lino.tickets.Links.insert;
    Lino.tickets.Links.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Links.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.Links.detailPanel(p);
});
Lino.tickets.Links.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Links.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.Links.GridPanel(p);
});
Lino.tickets.Links.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Links", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.Tickets
Lino.tickets.Tickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/Tickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/Tickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/Tickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "topic" }, 'topicHidden', { "name": "workflow_buttons" }, { "name": "project" }, 'projectHidden', { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Tickets.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    var ww = this.containing_window;
    var id2940 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary2941 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user2942 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/user" }) }) });
    var topic2943 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/topic" }) }) });
    var workflow_buttons_disp2944 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project2945 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/project" }) }) });
    var modified2946 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2947 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref2948 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private2949 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority2950 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed2951 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time2952 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site2953 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/site" }) }) });
    var description2954 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes2955 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type2956 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/ticket_type" }) }) });
    var duplicate_of2957 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/duplicate_of" }) }) });
    var end_user2958 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/end_user" }) }) });
    var state2959 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline2960 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for2961 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/reported_for" }) }) });
    var fixed_for2962 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/fixed_for" }) }) });
    var reporter2963 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/Tickets/reporter" }) }) });
    var waiting_for2964 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback2965 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby2966 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp2967 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp2968 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2969 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2970 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2971 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp2972 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description2954.refresh();
      reported_for2961.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for2962.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site2953.on('change',Lino.chooser_handler(reported_for2961,'site'));
      site2953.on('change',Lino.chooser_handler(fixed_for2962,'site'));
      Lino.tickets.Tickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id2940, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.Tickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary2941, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.Tickets.summary) Short summary of the problem.", "width": Lino.chars2width(51) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user2942, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.Tickets.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic2943, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.Tickets.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.Tickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "project", "editable": true, "editor": project2945, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.Tickets.project) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "ref", "editable": true, "editor": ref2948, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 10, "dataIndex": "priority", "editable": true, "editor": priority2950, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "planned_time", "editable": true, "editor": planned_time2952, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 13, "dataIndex": "site", "editable": true, "editor": site2953, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.Tickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description2954, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes2955, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type2956, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.Tickets.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of2957, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.Tickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "end_user", "editable": true, "editor": end_user2958, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.Tickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state2959, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline2960, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for2961, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.Tickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for2962, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.Tickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter2963, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.Tickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for2964, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.Tickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Tickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.Tickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/Tickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Tickets.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    Lino.tickets.Tickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Tickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.Tickets.insertPanel(p);
});
Lino.tickets.Tickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.Tickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/Tickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.Tickets.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    Lino.tickets.Tickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.Tickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.Tickets.detailPanel(p);
});
Lino.tickets.Tickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.Tickets.GridPanel(p);
});
Lino.tickets.Tickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.AllTickets
Lino.tickets.AllTickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/AllTickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/AllTickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/AllTickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "K\u00f5ik lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "topic" }, 'topicHidden', { "name": "workflow_buttons" }, { "name": "project" }, 'projectHidden', { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.AllTickets.detail;
    this.ls_insert_handler = Lino.tickets.AllTickets.insert;
    var ww = this.containing_window;
    var id4922 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary4923 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user4924 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/user" }) }) });
    var topic4925 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/topic" }) }) });
    var workflow_buttons_disp4926 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project4927 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/project" }) }) });
    var modified4928 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4929 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref4930 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private4931 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority4932 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed4933 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time4934 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site4935 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/site" }) }) });
    var description4936 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes4937 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type4938 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/ticket_type" }) }) });
    var duplicate_of4939 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/duplicate_of" }) }) });
    var end_user4940 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/end_user" }) }) });
    var state4941 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline4942 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for4943 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/reported_for" }) }) });
    var fixed_for4944 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/fixed_for" }) }) });
    var reporter4945 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/AllTickets/reporter" }) }) });
    var waiting_for4946 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback4947 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby4948 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp4949 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp4950 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4951 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4952 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4953 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4954 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description4936.refresh();
      reported_for4943.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for4944.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site4935.on('change',Lino.chooser_handler(reported_for4943,'site'));
      site4935.on('change',Lino.chooser_handler(fixed_for4944,'site'));
      Lino.tickets.AllTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4922, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.AllTickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary4923, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.AllTickets.summary) Short summary of the problem.", "width": Lino.chars2width(51) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user4924, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic4925, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.AllTickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "project", "editable": true, "editor": project4927, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.project) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "ref", "editable": true, "editor": ref4930, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 10, "dataIndex": "priority", "editable": true, "editor": priority4932, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "planned_time", "editable": true, "editor": planned_time4934, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 13, "dataIndex": "site", "editable": true, "editor": site4935, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description4936, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes4937, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type4938, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of4939, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "end_user", "editable": true, "editor": end_user4940, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state4941, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline4942, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for4943, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for4944, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter4945, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.AllTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for4946, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.AllTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.AllTickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.AllTickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.AllTickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.AllTickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/AllTickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.AllTickets.detail;
    this.ls_insert_handler = Lino.tickets.AllTickets.insert;
    Lino.tickets.AllTickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.AllTickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.AllTickets.insertPanel(p);
});
Lino.tickets.AllTickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.AllTickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/AllTickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.AllTickets.detail;
    this.ls_insert_handler = Lino.tickets.AllTickets.insert;
    Lino.tickets.AllTickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.AllTickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.AllTickets.detailPanel(p);
});
Lino.tickets.AllTickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.AllTickets.GridPanel(p);
});
Lino.tickets.AllTickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.AllTickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/AllTickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.RefTickets
Lino.tickets.RefTickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/RefTickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/RefTickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/RefTickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Reference Tickets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "ref" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "topic" }, 'topicHidden', { "name": "workflow_buttons" }, { "name": "project" }, 'projectHidden', { "name": "modified" }, { "name": "created" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.RefTickets.detail;
    this.ls_insert_handler = Lino.tickets.RefTickets.insert;
    var ww = this.containing_window;
    var id4956 = new Ext.form.NumberField({ "selectOnFocus": true });
    var ref4957 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var summary4958 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user4959 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/user" }) }) });
    var topic4960 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/topic" }) }) });
    var workflow_buttons_disp4961 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project4962 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/project" }) }) });
    var modified4963 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4964 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var private4965 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority4966 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed4967 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time4968 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site4969 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/site" }) }) });
    var description4970 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes4971 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type4972 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/ticket_type" }) }) });
    var duplicate_of4973 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/duplicate_of" }) }) });
    var end_user4974 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/end_user" }) }) });
    var state4975 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline4976 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for4977 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/reported_for" }) }) });
    var fixed_for4978 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/fixed_for" }) }) });
    var reporter4979 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/RefTickets/reporter" }) }) });
    var waiting_for4980 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback4981 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby4982 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp4983 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp4984 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp4985 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp4986 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp4987 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp4988 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description4970.refresh();
      reported_for4977.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for4978.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site4969.on('change',Lino.chooser_handler(reported_for4977,'site'));
      site4969.on('change',Lino.chooser_handler(fixed_for4978,'site'));
      Lino.tickets.RefTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id4956, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.RefTickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "ref", "editable": true, "editor": ref4957, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.RefTickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "summary", "editable": true, "editor": summary4958, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.RefTickets.summary) Short summary of the problem.", "width": Lino.chars2width(51) }, { "colIndex": 3, "dataIndex": "user", "editable": true, "editor": user4959, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.user) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "topic", "editable": true, "editor": topic4960, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.RefTickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "project", "editable": true, "editor": project4962, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.project) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.RefTickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.RefTickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 10, "dataIndex": "priority", "editable": true, "editor": priority4966, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.RefTickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "planned_time", "editable": true, "editor": planned_time4968, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.RefTickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 13, "dataIndex": "site", "editable": true, "editor": site4969, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description4970, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes4971, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type4972, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of4973, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "end_user", "editable": true, "editor": end_user4974, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state4975, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline4976, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.RefTickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for4977, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for4978, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter4979, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.RefTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for4980, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.RefTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.RefTickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.RefTickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.RefTickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.RefTickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/RefTickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.RefTickets.detail;
    this.ls_insert_handler = Lino.tickets.RefTickets.insert;
    Lino.tickets.RefTickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.RefTickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.RefTickets.insertPanel(p);
});
Lino.tickets.RefTickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.RefTickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/RefTickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.RefTickets.detail;
    this.ls_insert_handler = Lino.tickets.RefTickets.insert;
    Lino.tickets.RefTickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.RefTickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.RefTickets.detailPanel(p);
});
Lino.tickets.RefTickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.RefTickets.GridPanel(p);
});
Lino.tickets.RefTickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.RefTickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/RefTickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.UnassignedTickets
Lino.tickets.UnassignedTickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/UnassignedTickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/UnassignedTickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/UnassignedTickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Unassigned Tickets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 46,
  ls_store_fields : [ { "name": "summary" }, { "name": "project" }, 'projectHidden', { "name": "user" }, 'userHidden', { "name": "votes_by_ticket" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.UnassignedTickets.detail;
    this.ls_insert_handler = Lino.tickets.UnassignedTickets.insert;
    var ww = this.containing_window;
    var summary4990 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var project4991 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/project" }) }) });
    var user4992 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/user" }) }) });
    var votes_by_ticket_htmlbox4993 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "votes_by_ticket", "title": "votes_by_ticket", "value": "<br/>" });
    var id4994 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified4995 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created4996 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref4997 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private4998 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority4999 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed5000 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time5001 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site5002 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/site" }) }) });
    var topic5003 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/topic" }) }) });
    var description5004 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes5005 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type5006 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/ticket_type" }) }) });
    var duplicate_of5007 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/duplicate_of" }) }) });
    var end_user5008 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/end_user" }) }) });
    var state5009 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline5010 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for5011 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/reported_for" }) }) });
    var fixed_for5012 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/fixed_for" }) }) });
    var reporter5013 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/UnassignedTickets/reporter" }) }) });
    var waiting_for5014 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback5015 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby5016 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp5017 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp5018 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5019 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5020 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5021 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5022 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5023 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      votes_by_ticket_htmlbox4993.refresh();
      description5004.refresh();
      reported_for5011.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for5012.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site5002.on('change',Lino.chooser_handler(reported_for5011,'site'));
      site5002.on('change',Lino.chooser_handler(fixed_for5012,'site'));
      Lino.tickets.UnassignedTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "summary", "editable": true, "editor": summary4990, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.UnassignedTickets.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "project", "editable": true, "editor": project4991, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.project) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user4992, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "votes_by_ticket", "editable": false, "header": "votes_by_ticket", "sortable": false, "tooltip": "(tickets.UnassignedTickets.votes_by_ticket) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id4994, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "ref", "editable": true, "editor": ref4997, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 9, "dataIndex": "priority", "editable": true, "editor": priority4999, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time5001, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "site", "editable": true, "editor": site5002, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "topic", "editable": true, "editor": topic5003, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description5004, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes5005, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type5006, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of5007, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "end_user", "editable": true, "editor": end_user5008, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state5009, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline5010, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for5011, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for5012, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter5013, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.UnassignedTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for5014, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.UnassignedTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.UnassignedTickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.UnassignedTickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.UnassignedTickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.UnassignedTickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/UnassignedTickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.UnassignedTickets.detail;
    this.ls_insert_handler = Lino.tickets.UnassignedTickets.insert;
    Lino.tickets.UnassignedTickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.UnassignedTickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.UnassignedTickets.insertPanel(p);
});
Lino.tickets.UnassignedTickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.UnassignedTickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/UnassignedTickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.UnassignedTickets.detail;
    this.ls_insert_handler = Lino.tickets.UnassignedTickets.insert;
    Lino.tickets.UnassignedTickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.UnassignedTickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.UnassignedTickets.detailPanel(p);
});
Lino.tickets.UnassignedTickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.UnassignedTickets.GridPanel(p);
});
Lino.tickets.UnassignedTickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.UnassignedTickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/UnassignedTickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.PublicTickets
Lino.tickets.PublicTickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/PublicTickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/PublicTickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/PublicTickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Avalikud lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "topic" }, 'topicHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.PublicTickets.detail;
    this.ls_insert_handler = Lino.tickets.PublicTickets.insert;
    var ww = this.containing_window;
    var overview_disp2974 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var ticket_type2975 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/ticket_type" }) }) });
    var topic2976 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/topic" }) }) });
    var priority2977 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 100 });
    var id2978 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified2979 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2980 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref2981 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private2982 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user2983 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/user" }) }) });
    var closed2984 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time2985 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project2986 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/project" }) }) });
    var site2987 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/site" }) }) });
    var summary2988 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description2989 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes2990 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var duplicate_of2991 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/duplicate_of" }) }) });
    var end_user2992 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/end_user" }) }) });
    var state2993 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline2994 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for2995 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/reported_for" }) }) });
    var fixed_for2996 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/fixed_for" }) }) });
    var reporter2997 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/PublicTickets/reporter" }) }) });
    var waiting_for2998 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback2999 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3000 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3001 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3002 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3003 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3004 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3005 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3006 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description2989.refresh();
      reported_for2995.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for2996.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site2987.on('change',Lino.chooser_handler(reported_for2995,'site'));
      site2987.on('change',Lino.chooser_handler(fixed_for2996,'site'));
      Lino.tickets.PublicTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.PublicTickets.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type2975, "filter": { "type": "string" }, "header": "Lipikuliik", "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.ticket_type) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "topic", "editable": true, "editor": topic2976, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.topic) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 3, "dataIndex": "priority", "editable": true, "editor": priority2977, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "sortable": true, "tooltip": "(tickets.PublicTickets.priority) ", "width": Lino.chars2width(4) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id2978, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "ref", "editable": true, "editor": ref2981, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user2983, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time2985, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "project", "editable": true, "editor": project2986, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.project) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "site", "editable": true, "editor": site2987, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "summary", "editable": true, "editor": summary2988, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "description", "editable": true, "editor": description2989, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes2990, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of2991, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "end_user", "editable": true, "editor": end_user2992, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state2993, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline2994, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for2995, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for2996, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter2997, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.PublicTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for2998, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.PublicTickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.PublicTickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.PublicTickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/PublicTickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.PublicTickets.detail;
    this.ls_insert_handler = Lino.tickets.PublicTickets.insert;
    Lino.tickets.PublicTickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.PublicTickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.PublicTickets.insertPanel(p);
});
Lino.tickets.PublicTickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.PublicTickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/PublicTickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.PublicTickets.detail;
    this.ls_insert_handler = Lino.tickets.PublicTickets.insert;
    Lino.tickets.PublicTickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.PublicTickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.PublicTickets.detailPanel(p);
});
Lino.tickets.PublicTickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.PublicTickets.GridPanel(p);
});
Lino.tickets.PublicTickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsToTriage
Lino.tickets.TicketsToTriage.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsToTriage",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsToTriage','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsToTriage','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud sorteerimata",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "topic" }, 'topicHidden', { "name": "project" }, 'projectHidden', { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsToTriage.detail;
    this.ls_insert_handler = Lino.tickets.TicketsToTriage.insert;
    var ww = this.containing_window;
    var overview_disp5025 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var topic5026 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/topic" }) }) });
    var project5027 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/project" }) }) });
    var ticket_type5028 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/ticket_type" }) }) });
    var workflow_buttons_disp5029 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5030 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified5031 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5032 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref5033 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private5034 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user5035 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/user" }) }) });
    var priority5036 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed5037 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time5038 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site5039 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/site" }) }) });
    var summary5040 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description5041 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes5042 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var duplicate_of5043 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/duplicate_of" }) }) });
    var end_user5044 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/end_user" }) }) });
    var state5045 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline5046 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for5047 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/reported_for" }) }) });
    var fixed_for5048 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/fixed_for" }) }) });
    var reporter5049 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTriage/reporter" }) }) });
    var waiting_for5050 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback5051 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby5052 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp5053 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp5054 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5055 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5056 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5057 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5041.refresh();
      reported_for5047.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for5048.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site5039.on('change',Lino.chooser_handler(reported_for5047,'site'));
      site5039.on('change',Lino.chooser_handler(fixed_for5048,'site'));
      Lino.tickets.TicketsToTriage.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.TicketsToTriage.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "topic", "editable": true, "editor": topic5026, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.topic) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "project", "editable": true, "editor": project5027, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.project) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type5028, "filter": { "type": "string" }, "header": "Lipikuliik", "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.ticket_type) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.TicketsToTriage.workflow_buttons) ", "width": Lino.chars2width(41) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5030, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "ref", "editable": true, "editor": ref5033, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "user", "editable": true, "editor": user5035, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 11, "dataIndex": "priority", "editable": true, "editor": priority5036, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 12, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "planned_time", "editable": true, "editor": planned_time5038, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 14, "dataIndex": "site", "editable": true, "editor": site5039, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.site) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "summary", "editable": true, "editor": summary5040, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "description", "editable": true, "editor": description5041, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.description) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes5042, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of5043, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "end_user", "editable": true, "editor": end_user5044, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "state", "editable": true, "editor": state5045, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.state) ", "width": Lino.chars2width(12) }, { "colIndex": 21, "dataIndex": "deadline", "editable": true, "editor": deadline5046, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 22, "dataIndex": "reported_for", "editable": true, "editor": reported_for5047, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for5048, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "reporter", "editable": true, "editor": reporter5049, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTriage.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for5050, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTriage.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 26, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTriage.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.TicketsToTriage.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsToTriage.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsToTriage.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsToTriage",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsToTriage.detail;
    this.ls_insert_handler = Lino.tickets.TicketsToTriage.insert;
    Lino.tickets.TicketsToTriage.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsToTriage.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsToTriage.insertPanel(p);
});
Lino.tickets.TicketsToTriage.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsToTriage.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsToTriage",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsToTriage.detail;
    this.ls_insert_handler = Lino.tickets.TicketsToTriage.insert;
    Lino.tickets.TicketsToTriage.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsToTriage.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsToTriage.detailPanel(p);
});
Lino.tickets.TicketsToTriage.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsToTriage.GridPanel(p);
});
Lino.tickets.TicketsToTriage.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTriage.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTriage", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsToTalk
Lino.tickets.TicketsToTalk.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsToTalk",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsToTalk','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsToTalk','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud arutlusel",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "waiting_for" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsToTalk.detail;
    this.ls_insert_handler = Lino.tickets.TicketsToTalk.insert;
    var ww = this.containing_window;
    var overview_disp5059 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var priority5060 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 100 });
    var waiting_for5061 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp5062 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5063 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified5064 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5065 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref5066 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private5067 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user5068 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/user" }) }) });
    var closed5069 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time5070 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project5071 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/project" }) }) });
    var site5072 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/site" }) }) });
    var topic5073 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/topic" }) }) });
    var summary5074 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description5075 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes5076 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type5077 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/ticket_type" }) }) });
    var duplicate_of5078 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/duplicate_of" }) }) });
    var end_user5079 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/end_user" }) }) });
    var state5080 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline5081 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for5082 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/reported_for" }) }) });
    var fixed_for5083 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/fixed_for" }) }) });
    var reporter5084 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsToTalk/reporter" }) }) });
    var feedback5085 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby5086 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp5087 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp5088 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5089 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5090 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5091 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5075.refresh();
      reported_for5082.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for5083.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site5072.on('change',Lino.chooser_handler(reported_for5082,'site'));
      site5072.on('change',Lino.chooser_handler(fixed_for5083,'site'));
      Lino.tickets.TicketsToTalk.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.TicketsToTalk.overview) ", "width": Lino.chars2width(51) }, { "align": "right", "colIndex": 1, "dataIndex": "priority", "editable": true, "editor": priority5060, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "sortable": true, "tooltip": "(tickets.TicketsToTalk.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for5061, "filter": { "type": "string" }, "header": "Waiting for", "sortable": true, "tooltip": "(tickets.TicketsToTalk.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.TicketsToTalk.workflow_buttons) ", "width": Lino.chars2width(41) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5063, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "ref", "editable": true, "editor": ref5066, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user5068, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time5070, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "project", "editable": true, "editor": project5071, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.project) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "site", "editable": true, "editor": site5072, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.site) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "topic", "editable": true, "editor": topic5073, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "summary", "editable": true, "editor": summary5074, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "description", "editable": true, "editor": description5075, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.description) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes5076, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type5077, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of5078, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "end_user", "editable": true, "editor": end_user5079, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "state", "editable": true, "editor": state5080, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.state) ", "width": Lino.chars2width(12) }, { "colIndex": 22, "dataIndex": "deadline", "editable": true, "editor": deadline5081, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsToTalk.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "reported_for", "editable": true, "editor": reported_for5082, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for5083, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "reporter", "editable": true, "editor": reporter5084, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsToTalk.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsToTalk.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.TicketsToTalk.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsToTalk.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsToTalk.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsToTalk",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsToTalk.detail;
    this.ls_insert_handler = Lino.tickets.TicketsToTalk.insert;
    Lino.tickets.TicketsToTalk.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsToTalk.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsToTalk.insertPanel(p);
});
Lino.tickets.TicketsToTalk.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsToTalk.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsToTalk",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsToTalk.detail;
    this.ls_insert_handler = Lino.tickets.TicketsToTalk.insert;
    Lino.tickets.TicketsToTalk.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsToTalk.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsToTalk.detailPanel(p);
});
Lino.tickets.TicketsToTalk.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsToTalk.GridPanel(p);
});
Lino.tickets.TicketsToTalk.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsToTalk.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsToTalk", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.ActiveTickets
Lino.tickets.ActiveTickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/ActiveTickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ActiveTickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ActiveTickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Active tickets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "topic" }, 'topicHidden', { "name": "user" }, 'userHidden', { "name": "end_user" }, 'end_userHidden', { "name": "project" }, 'projectHidden', { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 12,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ActiveTickets.detail;
    this.ls_insert_handler = Lino.tickets.ActiveTickets.insert;
    var ww = this.containing_window;
    var overview_disp5093 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var topic5094 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/topic" }) }) });
    var user5095 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/user" }) }) });
    var end_user5096 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/end_user" }) }) });
    var project5097 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/project" }) }) });
    var ticket_type5098 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/ticket_type" }) }) });
    var workflow_buttons_disp5099 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5100 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified5101 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5102 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref5103 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private5104 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority5105 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed5106 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time5107 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site5108 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/site" }) }) });
    var summary5109 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description5110 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes5111 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var duplicate_of5112 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/duplicate_of" }) }) });
    var state5113 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline5114 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for5115 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/reported_for" }) }) });
    var fixed_for5116 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/fixed_for" }) }) });
    var reporter5117 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ActiveTickets/reporter" }) }) });
    var waiting_for5118 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback5119 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby5120 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp5121 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp5122 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5123 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5124 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5125 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5110.refresh();
      reported_for5115.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for5116.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site5108.on('change',Lino.chooser_handler(reported_for5115,'site'));
      site5108.on('change',Lino.chooser_handler(fixed_for5116,'site'));
      Lino.tickets.ActiveTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.ActiveTickets.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "topic", "editable": true, "editor": topic5094, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.topic) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5095, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "end_user", "editable": true, "editor": end_user5096, "filter": { "type": "string" }, "header": "End user", "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.end_user) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "project", "editable": true, "editor": project5097, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.project) ", "width": Lino.chars2width(11) }, { "colIndex": 5, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type5098, "filter": { "type": "string" }, "header": "Lipikuliik", "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.ticket_type) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.ActiveTickets.workflow_buttons) ", "width": Lino.chars2width(41) }, { "align": "right", "colIndex": 7, "dataIndex": "id", "editable": true, "editor": id5100, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 9, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 10, "dataIndex": "ref", "editable": true, "editor": ref5103, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 12, "dataIndex": "priority", "editable": true, "editor": priority5105, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "planned_time", "editable": true, "editor": planned_time5107, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 15, "dataIndex": "site", "editable": true, "editor": site5108, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "summary", "editable": true, "editor": summary5109, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "description", "editable": true, "editor": description5110, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes5111, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 19, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of5112, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "state", "editable": true, "editor": state5113, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 21, "dataIndex": "deadline", "editable": true, "editor": deadline5114, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 22, "dataIndex": "reported_for", "editable": true, "editor": reported_for5115, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for5116, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "reporter", "editable": true, "editor": reporter5117, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.ActiveTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for5118, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.ActiveTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 26, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.ActiveTickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.ActiveTickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ActiveTickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ActiveTickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/ActiveTickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ActiveTickets.detail;
    this.ls_insert_handler = Lino.tickets.ActiveTickets.insert;
    Lino.tickets.ActiveTickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ActiveTickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.ActiveTickets.insertPanel(p);
});
Lino.tickets.ActiveTickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ActiveTickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/ActiveTickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ActiveTickets.detail;
    this.ls_insert_handler = Lino.tickets.ActiveTickets.insert;
    Lino.tickets.ActiveTickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ActiveTickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ActiveTickets.detailPanel(p);
});
Lino.tickets.ActiveTickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.ActiveTickets.GridPanel(p);
});
Lino.tickets.ActiveTickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ActiveTickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ActiveTickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.MyTickets
Lino.tickets.MyTickets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/MyTickets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/MyTickets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/MyTickets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Minu Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.MyTickets.detail;
    this.ls_insert_handler = Lino.tickets.MyTickets.insert;
    var ww = this.containing_window;
    var overview_disp5127 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp5128 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5129 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified5130 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5131 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref5132 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private5133 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user5134 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/user" }) }) });
    var priority5135 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed5136 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time5137 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project5138 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/project" }) }) });
    var site5139 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/site" }) }) });
    var topic5140 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/topic" }) }) });
    var summary5141 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description5142 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes5143 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type5144 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/ticket_type" }) }) });
    var duplicate_of5145 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/duplicate_of" }) }) });
    var end_user5146 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/end_user" }) }) });
    var state5147 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline5148 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for5149 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/reported_for" }) }) });
    var fixed_for5150 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/fixed_for" }) }) });
    var reporter5151 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/MyTickets/reporter" }) }) });
    var waiting_for5152 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback5153 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby5154 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp5155 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp5156 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5157 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5158 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5159 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5142.refresh();
      reported_for5149.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for5150.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site5139.on('change',Lino.chooser_handler(reported_for5149,'site'));
      site5139.on('change',Lino.chooser_handler(fixed_for5150,'site'));
      Lino.tickets.MyTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.MyTickets.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.MyTickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id5129, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref5132, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user5134, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 8, "dataIndex": "priority", "editable": true, "editor": priority5135, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time5137, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "project", "editable": true, "editor": project5138, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.project) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "site", "editable": true, "editor": site5139, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.site) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "topic", "editable": true, "editor": topic5140, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "summary", "editable": true, "editor": summary5141, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "description", "editable": true, "editor": description5142, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes5143, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type5144, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of5145, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "end_user", "editable": true, "editor": end_user5146, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "state", "editable": true, "editor": state5147, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 21, "dataIndex": "deadline", "editable": true, "editor": deadline5148, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 22, "dataIndex": "reported_for", "editable": true, "editor": reported_for5149, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for5150, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "reporter", "editable": true, "editor": reporter5151, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.MyTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for5152, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.MyTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 26, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.MyTickets.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.MyTickets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.MyTickets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.MyTickets.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/MyTickets",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.MyTickets.detail;
    this.ls_insert_handler = Lino.tickets.MyTickets.insert;
    Lino.tickets.MyTickets.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.MyTickets.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.MyTickets.insertPanel(p);
});
Lino.tickets.MyTickets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.MyTickets.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/MyTickets",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.MyTickets.detail;
    this.ls_insert_handler = Lino.tickets.MyTickets.insert;
    Lino.tickets.MyTickets.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.MyTickets.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.MyTickets.detailPanel(p);
});
Lino.tickets.MyTickets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.MyTickets.ParamsPanel({});
  return new Lino.tickets.MyTickets.GridPanel(p);
});
Lino.tickets.MyTickets.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.MyTickets.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/MyTickets", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.Users
Lino.users.Users.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/Users",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/Users','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/Users','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Users",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 63,
  ls_store_fields : [ { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "first_name" }, { "name": "last_name" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "middle_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "created" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.Users.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    var ww = this.containing_window;
    var username5161 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile5162 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var first_name5163 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name5164 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5165 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email5166 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language5167 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url5168 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone5169 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm5170 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax5171 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country5172 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/country" }) }) });
    var city5173 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/city" }) }) });
    var zip_code5174 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region5175 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/region" }) }) });
    var addr15176 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix5177 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street5178 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no5179 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box5180 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr25181 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name5182 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks5183 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title5184 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name5185 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender5186 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date5187 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private5188 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified5189 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5190 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password5191 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login5192 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone5193 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/timezone" }) }) });
    var initials5194 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode5195 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code5196 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state5197 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class5198 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type5199 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Users/event_type" }) }) });
    var open_session_on_new_ticket5200 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself5201 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode5202 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox5203 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp5204 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5205 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5206 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5207 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5208 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5209 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp5210 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp5211 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp5212 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city5173.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city5173.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region5175.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks5183.refresh();
      timezone5193.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox5203.refresh();
    };
    this.onRender = function(ct, position) {
      country5172.on('change',Lino.chooser_handler(city5173,'country'));
      region5175.on('change',Lino.chooser_handler(city5173,'region'));
      country5172.on('change',Lino.chooser_handler(region5175,'country'));
      Lino.users.Users.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username5161, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.Users.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile5162, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.Users.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 2, "dataIndex": "first_name", "editable": true, "editor": first_name5163, "filter": { "type": "string" }, "header": "Eesnimi", "sortable": true, "tooltip": "(users.Users.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "last_name", "editable": true, "editor": last_name5164, "filter": { "type": "string" }, "header": "Perenimi", "sortable": true, "tooltip": "(users.Users.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5165, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(users.Users.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "email", "editable": true, "editor": email5166, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(users.Users.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language5167, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(users.Users.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url5168, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.Users.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone5169, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(users.Users.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "gsm", "editable": true, "editor": gsm5170, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(users.Users.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "fax", "editable": true, "editor": fax5171, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.Users.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country5172, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(users.Users.country) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "city", "editable": true, "editor": city5173, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.Users.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code5174, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(users.Users.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 14, "dataIndex": "region", "editable": true, "editor": region5175, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.Users.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr15176, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(users.Users.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix5177, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(users.Users.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "street", "editable": true, "editor": street5178, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(users.Users.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "street_no", "editable": true, "editor": street_no5179, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(users.Users.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "street_box", "editable": true, "editor": street_box5180, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(users.Users.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "addr2", "editable": true, "editor": addr25181, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(users.Users.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "name", "editable": true, "editor": name5182, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(users.Users.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "remarks", "editable": true, "editor": remarks5183, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(users.Users.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "title", "editable": true, "editor": title5184, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(users.Users.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "middle_name", "editable": true, "editor": middle_name5185, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(users.Users.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "gender", "editable": true, "editor": gender5186, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(users.Users.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 26, "dataIndex": "birth_date", "editable": true, "editor": birth_date5187, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(users.Users.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 27, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(users.Users.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.Users.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 29, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(users.Users.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 30, "dataIndex": "password", "editable": true, "editor": password5191, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.Users.password) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "last_login", "editable": true, "editor": last_login5192, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.Users.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 32, "dataIndex": "timezone", "editable": true, "editor": timezone5193, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.Users.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 33, "dataIndex": "initials", "editable": true, "editor": initials5194, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.Users.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(users.Users.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 35, "dataIndex": "verification_code", "editable": true, "editor": verification_code5196, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(users.Users.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 36, "dataIndex": "user_state", "editable": true, "editor": user_state5197, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(users.Users.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 37, "dataIndex": "access_class", "editable": true, "editor": access_class5198, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(users.Users.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 38, "dataIndex": "event_type", "editable": true, "editor": event_type5199, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(users.Users.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 39, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(users.Users.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 40, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(users.Users.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5202, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.Users.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 42, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.Users.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.Users.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 44, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Users.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 45, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Users.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.Users.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.Users.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.Users.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.Users.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.Users.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(users.Users.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.users.Users.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Users.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.Users.insertPanel = Ext.extend(Lino.users.Users.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/users/Users",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.Users.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    Lino.users.Users.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Users.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.Users.insertPanel(p);
});
Lino.users.Users.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.Users.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/Users",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.Users.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    Lino.users.Users.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Users.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.Users.detailPanel(p);
});
Lino.users.Users.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.users.Users.GridPanel(p);
});
Lino.users.Users.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Users.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Users", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.AllUsers
Lino.users.AllUsers.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/AllUsers",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/AllUsers','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/AllUsers','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Users",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 63,
  ls_store_fields : [ { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "first_name" }, { "name": "last_name" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "middle_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "created" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.AllUsers.detail;
    this.ls_insert_handler = Lino.users.AllUsers.insert;
    var ww = this.containing_window;
    var username5214 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile5215 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var first_name5216 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name5217 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5218 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email5219 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language5220 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url5221 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone5222 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm5223 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax5224 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country5225 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AllUsers/country" }) }) });
    var city5226 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AllUsers/city" }) }) });
    var zip_code5227 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region5228 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AllUsers/region" }) }) });
    var addr15229 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix5230 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street5231 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no5232 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box5233 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr25234 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name5235 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks5236 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title5237 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name5238 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender5239 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date5240 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private5241 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified5242 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5243 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password5244 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login5245 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone5246 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AllUsers/timezone" }) }) });
    var initials5247 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode5248 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code5249 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state5250 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class5251 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type5252 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AllUsers/event_type" }) }) });
    var open_session_on_new_ticket5253 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself5254 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode5255 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox5256 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp5257 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5258 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5259 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5260 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5261 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5262 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp5263 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp5264 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp5265 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city5226.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city5226.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region5228.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks5236.refresh();
      timezone5246.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox5256.refresh();
    };
    this.onRender = function(ct, position) {
      country5225.on('change',Lino.chooser_handler(city5226,'country'));
      region5228.on('change',Lino.chooser_handler(city5226,'region'));
      country5225.on('change',Lino.chooser_handler(region5228,'country'));
      Lino.users.AllUsers.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username5214, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.AllUsers.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile5215, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.AllUsers.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 2, "dataIndex": "first_name", "editable": true, "editor": first_name5216, "filter": { "type": "string" }, "header": "Eesnimi", "sortable": true, "tooltip": "(users.AllUsers.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "last_name", "editable": true, "editor": last_name5217, "filter": { "type": "string" }, "header": "Perenimi", "sortable": true, "tooltip": "(users.AllUsers.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5218, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "email", "editable": true, "editor": email5219, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language5220, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url5221, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone5222, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "gsm", "editable": true, "editor": gsm5223, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "fax", "editable": true, "editor": fax5224, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country5225, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(users.AllUsers.country) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "city", "editable": true, "editor": city5226, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.AllUsers.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code5227, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 14, "dataIndex": "region", "editable": true, "editor": region5228, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.AllUsers.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr15229, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix5230, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "street", "editable": true, "editor": street5231, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "street_no", "editable": true, "editor": street_no5232, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "street_box", "editable": true, "editor": street_box5233, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "addr2", "editable": true, "editor": addr25234, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "name", "editable": true, "editor": name5235, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "remarks", "editable": true, "editor": remarks5236, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "title", "editable": true, "editor": title5237, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "middle_name", "editable": true, "editor": middle_name5238, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "gender", "editable": true, "editor": gender5239, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 26, "dataIndex": "birth_date", "editable": true, "editor": birth_date5240, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 27, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 29, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 30, "dataIndex": "password", "editable": true, "editor": password5244, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.password) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "last_login", "editable": true, "editor": last_login5245, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 32, "dataIndex": "timezone", "editable": true, "editor": timezone5246, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 33, "dataIndex": "initials", "editable": true, "editor": initials5247, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 35, "dataIndex": "verification_code", "editable": true, "editor": verification_code5249, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(users.AllUsers.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 36, "dataIndex": "user_state", "editable": true, "editor": user_state5250, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 37, "dataIndex": "access_class", "editable": true, "editor": access_class5251, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 38, "dataIndex": "event_type", "editable": true, "editor": event_type5252, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(users.AllUsers.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 39, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 40, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5255, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 42, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 44, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 45, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(users.AllUsers.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.users.AllUsers.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.AllUsers.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.AllUsers.insertPanel = Ext.extend(Lino.users.Users.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/users/AllUsers",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.AllUsers.detail;
    this.ls_insert_handler = Lino.users.AllUsers.insert;
    Lino.users.AllUsers.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.users.AllUsers.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.AllUsers.insertPanel(p);
});
Lino.users.AllUsers.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.AllUsers.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/AllUsers",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.AllUsers.detail;
    this.ls_insert_handler = Lino.users.AllUsers.insert;
    Lino.users.AllUsers.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.AllUsers.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.AllUsers.detailPanel(p);
});
Lino.users.AllUsers.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.users.AllUsers.GridPanel(p);
});
Lino.users.AllUsers.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AllUsers.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AllUsers", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.UsersOverview
Lino.users.UsersOverview.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/UsersOverview",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/UsersOverview','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/UsersOverview','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Users",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "language" }, 'languageHidden', { "name": "person_ptr" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 10,
  ls_id_property : "person_ptr",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.UsersOverview.detail;
    this.ls_insert_handler = Lino.users.UsersOverview.insert;
    var ww = this.containing_window;
    var username3770 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile3771 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var language3772 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username3770, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.UsersOverview.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile3771, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.UsersOverview.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 2, "dataIndex": "language", "editable": true, "editor": language3772, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(users.UsersOverview.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) } ];
    Lino.users.UsersOverview.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.UsersOverview.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.UsersOverview.insertPanel = Ext.extend(Lino.users.Users.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/users/UsersOverview",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.UsersOverview.detail;
    this.ls_insert_handler = Lino.users.UsersOverview.insert;
    Lino.users.UsersOverview.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.users.UsersOverview.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.UsersOverview.insertPanel(p);
});
Lino.users.UsersOverview.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.UsersOverview.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/UsersOverview",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.UsersOverview.detail;
    this.ls_insert_handler = Lino.users.UsersOverview.insert;
    Lino.users.UsersOverview.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.UsersOverview.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.UsersOverview.detailPanel(p);
});
Lino.users.UsersOverview.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.users.UsersOverview.GridPanel(p);
});
Lino.users.UsersOverview.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UsersOverview.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UsersOverview", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.MySettings
Lino.users.MySettings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/MySettings",
  ls_bbar_actions : [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Users",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 63,
  ls_store_fields : [ { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "first_name" }, { "name": "last_name" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "middle_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "created" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.MySettings.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    var ww = this.containing_window;
    var username5267 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile5268 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var first_name5269 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name5270 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5271 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email5272 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language5273 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url5274 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone5275 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm5276 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax5277 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country5278 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/MySettings/country" }) }) });
    var city5279 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/MySettings/city" }) }) });
    var zip_code5280 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region5281 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/MySettings/region" }) }) });
    var addr15282 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix5283 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street5284 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no5285 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box5286 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr25287 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name5288 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks5289 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title5290 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name5291 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender5292 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date5293 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private5294 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified5295 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5296 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password5297 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login5298 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone5299 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/MySettings/timezone" }) }) });
    var initials5300 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode5301 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code5302 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state5303 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class5304 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type5305 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/MySettings/event_type" }) }) });
    var open_session_on_new_ticket5306 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself5307 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode5308 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox5309 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp5310 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5311 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5312 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5313 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5314 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5315 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp5316 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp5317 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp5318 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city5279.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city5279.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region5281.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks5289.refresh();
      timezone5299.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox5309.refresh();
    };
    this.onRender = function(ct, position) {
      country5278.on('change',Lino.chooser_handler(city5279,'country'));
      region5281.on('change',Lino.chooser_handler(city5279,'region'));
      country5278.on('change',Lino.chooser_handler(region5281,'country'));
      Lino.users.MySettings.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username5267, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.MySettings.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile5268, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.MySettings.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 2, "dataIndex": "first_name", "editable": true, "editor": first_name5269, "filter": { "type": "string" }, "header": "Eesnimi", "sortable": true, "tooltip": "(users.MySettings.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "last_name", "editable": true, "editor": last_name5270, "filter": { "type": "string" }, "header": "Perenimi", "sortable": true, "tooltip": "(users.MySettings.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5271, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "email", "editable": true, "editor": email5272, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language5273, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url5274, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone5275, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "gsm", "editable": true, "editor": gsm5276, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "fax", "editable": true, "editor": fax5277, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country5278, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(users.MySettings.country) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "city", "editable": true, "editor": city5279, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.MySettings.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code5280, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 14, "dataIndex": "region", "editable": true, "editor": region5281, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.MySettings.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr15282, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix5283, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "street", "editable": true, "editor": street5284, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "street_no", "editable": true, "editor": street_no5285, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "street_box", "editable": true, "editor": street_box5286, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "addr2", "editable": true, "editor": addr25287, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "name", "editable": true, "editor": name5288, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "remarks", "editable": true, "editor": remarks5289, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "title", "editable": true, "editor": title5290, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "middle_name", "editable": true, "editor": middle_name5291, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "gender", "editable": true, "editor": gender5292, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 26, "dataIndex": "birth_date", "editable": true, "editor": birth_date5293, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 27, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 29, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 30, "dataIndex": "password", "editable": true, "editor": password5297, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.password) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "last_login", "editable": true, "editor": last_login5298, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 32, "dataIndex": "timezone", "editable": true, "editor": timezone5299, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 33, "dataIndex": "initials", "editable": true, "editor": initials5300, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 35, "dataIndex": "verification_code", "editable": true, "editor": verification_code5302, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(users.MySettings.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 36, "dataIndex": "user_state", "editable": true, "editor": user_state5303, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 37, "dataIndex": "access_class", "editable": true, "editor": access_class5304, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 38, "dataIndex": "event_type", "editable": true, "editor": event_type5305, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(users.MySettings.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 39, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 40, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5308, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 42, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 44, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 45, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(users.MySettings.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.users.MySettings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.MySettings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.MySettings.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Users",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/MySettings",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.MySettings.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    Lino.users.MySettings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.MySettings.detail = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.MySettings.detailPanel(p);
});

Lino.users.MySettings.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Users",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/MySettings",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.MySettings.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    Lino.users.MySettings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.MySettings.detail = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.MySettings.detailPanel(p);
});
Lino.users.MySettings.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.MySettings.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/MySettings", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.Authorities
Lino.users.Authorities.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/Authorities",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/Authorities','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/Authorities','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Authorities",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "authorized" }, 'authorizedHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 11,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5320 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user5321 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Authorities/user" }) }) });
    var authorized5322 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Authorities/authorized" }) }) });
    var mobile_item_disp5323 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5324 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5325 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5326 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      authorized5322.setContextValue('user', record ? record.data['userHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      user5321.on('change',Lino.chooser_handler(authorized5322,'user'));
      Lino.users.Authorities.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5320, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(users.Authorities.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user5321, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(users.Authorities.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "authorized", "editable": true, "editor": authorized5322, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('authorizedHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(users.Authorities.authorized) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Authorities.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Authorities.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.Authorities.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.Authorities.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.users.Authorities.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Authorities.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Authorities", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Authorities.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Authorities", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Authorities.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Authorities", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Authorities.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Authorities", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Authorities.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Authorities", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Authorities.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Authorities", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Authorities.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Authorities.ParamsPanel({});
  return new Lino.users.Authorities.GridPanel(p);
});

// js_render_GridPanel_class faculties.SkillTypes
Lino.faculties.SkillTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/SkillTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/SkillTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/SkillTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Oskuseliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 48,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillTypes.detail;
    this.ls_insert_handler = Lino.faculties.SkillTypes.insert;
    var ww = this.containing_window;
    var id5328 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name5329 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5330 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var mobile_item_disp5331 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5332 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5333 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5334 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5328, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(faculties.SkillTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5329, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(faculties.SkillTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et5330, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(faculties.SkillTypes.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.faculties.SkillTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.SkillTypes.insertPanel = Ext.extend(Lino.faculties.SkillTypes.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/SkillTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillTypes.detail;
    this.ls_insert_handler = Lino.faculties.SkillTypes.insert;
    Lino.faculties.SkillTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillTypes.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.SkillTypes.insertPanel(p);
});
Lino.faculties.SkillTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.SkillTypes.detailPanel = Ext.extend(Lino.faculties.SkillTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/faculties/SkillTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillTypes.detail;
    this.ls_insert_handler = Lino.faculties.SkillTypes.insert;
    Lino.faculties.SkillTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.SkillTypes.detailPanel(p);
});
Lino.faculties.SkillTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.SkillTypes.GridPanel(p);
});
Lino.faculties.SkillTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.Skills
Lino.faculties.Skills.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/Skills",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/Skills','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/Skills','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 17,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "parent" }, 'parentHidden', { "name": "name" }, { "name": "name_et" }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "skill_type" }, 'skill_typeHidden', { "name": "remarks" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 49,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Skills.detail;
    this.ls_insert_handler = Lino.faculties.Skills.insert;
    var ww = this.containing_window;
    var id5336 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno5337 = new Ext.form.NumberField({ "selectOnFocus": true });
    var parent5338 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Skills/parent" }) }) });
    var name5339 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5340 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var affinity5341 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var skill_type5342 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Skills/skill_type" }) }) });
    var remarks5343 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var mobile_item_disp5344 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5345 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5346 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5347 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp5348 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp5349 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      remarks5343.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5336, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(faculties.Skills.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno5337, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(faculties.Skills.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent5338, "filter": { "type": "string" }, "header": "Parent skill", "renderer": Lino.fk_renderer('parentHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.Skills.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "name", "editable": true, "editor": name5339, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(faculties.Skills.name) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "name_et", "editable": true, "editor": name_et5340, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(faculties.Skills.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 5, "dataIndex": "affinity", "editable": true, "editor": affinity5341, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.Skills.affinity) How much workers enjoy to get a new ticket requiring this skill.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "skill_type", "editable": true, "editor": skill_type5342, "filter": { "type": "string" }, "header": "Oskuseliik", "renderer": Lino.fk_renderer('skill_typeHidden','Lino.faculties.SkillTypes.detail'), "sortable": false, "tooltip": "(faculties.Skills.skill_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "remarks", "editable": true, "editor": remarks5343, "filter": { "type": "string" }, "header": "M\u00e4rkused", "sortable": false, "tooltip": "(faculties.Skills.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.Skills.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.Skills.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.Skills.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.Skills.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(faculties.Skills.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.Skills.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.faculties.Skills.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Skills.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.Skills.insertPanel = Ext.extend(Lino.faculties.Skills.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/Skills",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Skills.detail;
    this.ls_insert_handler = Lino.faculties.Skills.insert;
    Lino.faculties.Skills.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Skills.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.Skills.insertPanel(p);
});
Lino.faculties.Skills.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.Skills.detailPanel = Ext.extend(Lino.faculties.Skills.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/Skills",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Skills.detail;
    this.ls_insert_handler = Lino.faculties.Skills.insert;
    Lino.faculties.Skills.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Skills.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.Skills.detailPanel(p);
});
Lino.faculties.Skills.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.Skills.GridPanel(p);
});
Lino.faculties.Skills.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Skills.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Skills", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.AllSkills
Lino.faculties.AllSkills.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/AllSkills",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/AllSkills','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/AllSkills','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskused (k\u00f5ik)",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 17,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "parent" }, 'parentHidden', { "name": "skill_type" }, 'skill_typeHidden', { "name": "remarks" }, { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 49,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.AllSkills.detail;
    this.ls_insert_handler = Lino.faculties.AllSkills.insert;
    var ww = this.containing_window;
    var name5351 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5352 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var parent5353 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AllSkills/parent" }) }) });
    var skill_type5354 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AllSkills/skill_type" }) }) });
    var remarks5355 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var id5356 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno5357 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var affinity5358 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true, "value": 100 });
    var mobile_item_disp5359 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5360 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5361 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5362 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp5363 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp5364 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      remarks5355.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name5351, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(faculties.AllSkills.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et5352, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(faculties.AllSkills.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent5353, "filter": { "type": "string" }, "header": "Parent skill", "renderer": Lino.fk_renderer('parentHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.AllSkills.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "skill_type", "editable": true, "editor": skill_type5354, "filter": { "type": "string" }, "header": "Oskuseliik", "renderer": Lino.fk_renderer('skill_typeHidden','Lino.faculties.SkillTypes.detail'), "sortable": false, "tooltip": "(faculties.AllSkills.skill_type) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "remarks", "editable": true, "editor": remarks5355, "filter": { "type": "string" }, "header": "M\u00e4rkused", "sortable": false, "tooltip": "(faculties.AllSkills.remarks) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5356, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.AllSkills.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 6, "dataIndex": "seqno", "editable": true, "editor": seqno5357, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(faculties.AllSkills.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 7, "dataIndex": "affinity", "editable": true, "editor": affinity5358, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "hidden": true, "sortable": true, "tooltip": "(faculties.AllSkills.affinity) How much workers enjoy to get a new ticket requiring this skill.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.AllSkills.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.AllSkills.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.AllSkills.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.AllSkills.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(faculties.AllSkills.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.AllSkills.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.faculties.AllSkills.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.AllSkills.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.AllSkills.insertPanel = Ext.extend(Lino.faculties.Skills.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/AllSkills",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.AllSkills.detail;
    this.ls_insert_handler = Lino.faculties.AllSkills.insert;
    Lino.faculties.AllSkills.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.AllSkills.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.AllSkills.insertPanel(p);
});
Lino.faculties.AllSkills.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.AllSkills.detailPanel = Ext.extend(Lino.faculties.Skills.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/AllSkills",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.AllSkills.detail;
    this.ls_insert_handler = Lino.faculties.AllSkills.insert;
    Lino.faculties.AllSkills.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.AllSkills.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.AllSkills.detailPanel(p);
});
Lino.faculties.AllSkills.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.AllSkills.GridPanel(p);
});
Lino.faculties.AllSkills.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AllSkills.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AllSkills", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.TopLevelSkills
Lino.faculties.TopLevelSkills.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "cellTpl": Lino.auto_height_cell_template, "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/TopLevelSkills",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/TopLevelSkills','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/TopLevelSkills','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskused (puu)",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 17,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "remarks" }, { "name": "children_summary" }, { "name": "parent" }, 'parentHidden', { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "skill_type" }, 'skill_typeHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 49,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.TopLevelSkills.detail;
    this.ls_insert_handler = Lino.faculties.TopLevelSkills.insert;
    var ww = this.containing_window;
    var name5366 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5367 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var remarks5368 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var children_summary_disp5369 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var parent5370 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/TopLevelSkills/parent" }) }) });
    var id5371 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno5372 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var affinity5373 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true, "value": 100 });
    var skill_type5374 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/TopLevelSkills/skill_type" }) }) });
    var mobile_item_disp5375 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5376 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5377 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5378 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp5379 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      remarks5368.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name5366, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(faculties.TopLevelSkills.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et5367, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(faculties.TopLevelSkills.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "remarks", "editable": true, "editor": remarks5368, "filter": { "type": "string" }, "header": "M\u00e4rkused", "sortable": false, "tooltip": "(faculties.TopLevelSkills.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 3, "dataIndex": "children_summary", "editable": false, "header": "Children", "sortable": false, "tooltip": "(faculties.TopLevelSkills.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "parent", "editable": true, "editor": parent5370, "filter": { "type": "string" }, "header": "Parent skill", "renderer": Lino.fk_renderer('parentHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.TopLevelSkills.parent) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5371, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.TopLevelSkills.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 6, "dataIndex": "seqno", "editable": true, "editor": seqno5372, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(faculties.TopLevelSkills.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 7, "dataIndex": "affinity", "editable": true, "editor": affinity5373, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "hidden": true, "sortable": true, "tooltip": "(faculties.TopLevelSkills.affinity) How much workers enjoy to get a new ticket requiring this skill.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "skill_type", "editable": true, "editor": skill_type5374, "filter": { "type": "string" }, "header": "Oskuseliik", "hidden": true, "renderer": Lino.fk_renderer('skill_typeHidden','Lino.faculties.SkillTypes.detail'), "sortable": false, "tooltip": "(faculties.TopLevelSkills.skill_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.TopLevelSkills.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.TopLevelSkills.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.TopLevelSkills.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.TopLevelSkills.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.TopLevelSkills.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.faculties.TopLevelSkills.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.TopLevelSkills.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.TopLevelSkills.insertPanel = Ext.extend(Lino.faculties.Skills.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/TopLevelSkills",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.TopLevelSkills.detail;
    this.ls_insert_handler = Lino.faculties.TopLevelSkills.insert;
    Lino.faculties.TopLevelSkills.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.TopLevelSkills.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.TopLevelSkills.insertPanel(p);
});
Lino.faculties.TopLevelSkills.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.TopLevelSkills.detailPanel = Ext.extend(Lino.faculties.Skills.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/TopLevelSkills",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.TopLevelSkills.detail;
    this.ls_insert_handler = Lino.faculties.TopLevelSkills.insert;
    Lino.faculties.TopLevelSkills.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.TopLevelSkills.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.TopLevelSkills.detailPanel(p);
});
Lino.faculties.TopLevelSkills.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.TopLevelSkills.GridPanel(p);
});
Lino.faculties.TopLevelSkills.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.TopLevelSkills.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/TopLevelSkills", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.Offers
Lino.faculties.Offers.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/Offers",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/Offers','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/Offers','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskuse pakkumised",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "faculty" }, 'facultyHidden', { "name": "description" }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "end_user" }, 'end_userHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 47,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Offers.detail;
    this.ls_insert_handler = Lino.faculties.Offers.insert;
    var ww = this.containing_window;
    var id5381 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user5382 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/user" }) }) });
    var faculty5383 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/faculty" }) }) });
    var description5384 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var affinity5385 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var seqno5386 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var end_user5387 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Offers/end_user" }) }) });
    var mobile_item_disp5388 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5389 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5390 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5391 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp5392 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5384.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5381, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(faculties.Offers.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user5382, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(faculties.Offers.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "faculty", "editable": true, "editor": faculty5383, "filter": { "type": "string" }, "header": "Oskus", "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.Offers.faculty) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "description", "editable": true, "editor": description5384, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(faculties.Offers.description) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 4, "dataIndex": "affinity", "editable": true, "editor": affinity5385, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.Offers.affinity) How much this user likes to get a new ticket in this faculty.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 5, "dataIndex": "seqno", "editable": true, "editor": seqno5386, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(faculties.Offers.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "end_user", "editable": true, "editor": end_user5387, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(faculties.Offers.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.Offers.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.Offers.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.Offers.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.Offers.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.Offers.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.faculties.Offers.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Offers.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.Offers.insertPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/Offers",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Offers.detail;
    this.ls_insert_handler = Lino.faculties.Offers.insert;
    Lino.faculties.Offers.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Offers.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.Offers.insertPanel(p);
});
Lino.faculties.Offers.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.Offers.detailPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/Offers",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Offers.detail;
    this.ls_insert_handler = Lino.faculties.Offers.insert;
    Lino.faculties.Offers.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Offers.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.Offers.detailPanel(p);
});
Lino.faculties.Offers.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.faculties.Offers.ParamsPanel({});
  return new Lino.faculties.Offers.GridPanel(p);
});
Lino.faculties.Offers.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Offers.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Offers", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.Demands
Lino.faculties.Demands.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/Demands",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/Demands','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/Demands','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Oskuste vajadused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "demander" }, 'demanderHidden', { "name": "skill" }, 'skillHidden', { "name": "importance", "type": "int", "useNull": true }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 46,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Demands.detail;
    this.ls_insert_handler = Lino.faculties.Demands.insert;
    var ww = this.containing_window;
    var id5394 = new Ext.form.NumberField({ "selectOnFocus": true });
    var demander5395 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Demands/demander" }) }) });
    var skill5396 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/Demands/skill" }) }) });
    var importance5397 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var mobile_item_disp5398 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5399 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5400 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5401 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5394, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(faculties.Demands.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "demander", "editable": true, "editor": demander5395, "filter": { "type": "string" }, "header": "Demander", "renderer": Lino.fk_renderer('demanderHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(faculties.Demands.demander) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "skill", "editable": true, "editor": skill5396, "filter": { "type": "string" }, "header": "Oskus", "renderer": Lino.fk_renderer('skillHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.Demands.skill) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "importance", "editable": true, "editor": importance5397, "filter": { "type": "numeric" }, "format": "0", "header": "Importance", "sortable": true, "tooltip": "(faculties.Demands.importance) How important this skill is for this demand. A number between -100 and +100.", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.Demands.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.Demands.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.Demands.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.Demands.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.faculties.Demands.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Demands.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Demands.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Demands.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.Demands.insertPanel = Ext.extend(Lino.faculties.Demands.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/Demands",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Demands.detail;
    this.ls_insert_handler = Lino.faculties.Demands.insert;
    Lino.faculties.Demands.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Demands.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.Demands.insertPanel(p);
});
Lino.faculties.Demands.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Demands.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Demands.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.Demands.detailPanel = Ext.extend(Lino.faculties.Demands.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/faculties/Demands",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.Demands.detail;
    this.ls_insert_handler = Lino.faculties.Demands.insert;
    Lino.faculties.Demands.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.Demands.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.Demands.detailPanel(p);
});
Lino.faculties.Demands.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.Demands.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.Demands.GridPanel(p);
});
Lino.faculties.Demands.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/Demands", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.SessionTypes
Lino.clocking.SessionTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/SessionTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/SessionTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/SessionTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Istungiliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 53,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var name5403 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5404 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5405 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp5406 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5407 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5408 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5409 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name5403, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(clocking.SessionTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et5404, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(clocking.SessionTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id5405, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.SessionTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.SessionTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.SessionTypes.GridPanel(p);
});

// js_render_GridPanel_class clocking.Sessions
Lino.clocking.Sessions.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/Sessions",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/Sessions','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/Sessions','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Istungid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 25,
  ls_store_fields : [ { "name": "ticket" }, 'ticketHidden', { "name": "user" }, 'userHidden', { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "break_time" }, { "name": "summary" }, { "name": "duration" }, { "name": "ticket_no" }, { "name": "id", "type": "int" }, { "name": "session_type" }, 'session_typeHidden', { "name": "description" }, { "name": "faculty" }, 'facultyHidden', { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 12,
  ls_grid_configs : [  ],
  content_type : 52,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.Sessions.detail;
    this.ls_insert_handler = Lino.clocking.Sessions.insert;
    var ww = this.containing_window;
    var ticket5411 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/ticket" }) }) });
    var user5412 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/user" }) }) });
    var start_date5413 = new Lino.DateField({ "selectOnFocus": true });
    var start_time5414 = new Lino.TimeField({ "selectOnFocus": true });
    var end_date5415 = new Lino.DateField({ "selectOnFocus": true });
    var end_time5416 = new Lino.TimeField({ "selectOnFocus": true });
    var break_time5417 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "maxLength": 6, "selectOnFocus": true });
    var summary5418 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var duration5419 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var ticket_no_disp5420 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5421 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var session_type5422 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Istungiliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/session_type" }) }) });
    var description5423 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var faculty5424 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/Sessions/faculty" }) }) });
    var reporting_type5425 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var mobile_item_disp5426 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5427 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5428 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5429 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5423.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ticket", "editable": true, "editor": ticket5411, "filter": { "type": "string" }, "header": "Lipik", "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(clocking.Sessions.ticket) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user5412, "filter": { "type": "string" }, "header": "T\u00f6\u00f6taja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(clocking.Sessions.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "start_date", "editable": true, "editor": start_date5413, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.Sessions.start_date) The date when you started to work.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 3, "dataIndex": "start_time", "editable": true, "editor": start_time5414, "header": "Start time", "sortable": true, "tooltip": "(clocking.Sessions.start_time) The time (in hh:mm) when you started working on this\nsession.", "width": Lino.chars2width(9) }, { "colIndex": 4, "dataIndex": "end_date", "editable": true, "editor": end_date5415, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "sortable": true, "tooltip": "(clocking.Sessions.end_date) Leave this field blank if it is the same date as start_date.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "end_time", "editable": true, "editor": end_time5416, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(clocking.Sessions.end_time) The time (in hh:mm) when you stopped to work. This is empty\nas long as you are busy with this session.", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 6, "dataIndex": "break_time", "editable": true, "editor": break_time5417, "filter": { "type": "string" }, "format": "", "header": "Paus", "sortable": true, "tooltip": "(clocking.Sessions.break_time) The time (in hh:mm) to remove from the duration resulting\nfrom the difference between start_time and\nend_time.", "width": Lino.chars2width(8) }, { "colIndex": 7, "dataIndex": "summary", "editable": true, "editor": summary5418, "filter": { "type": "string" }, "header": "Kokkuv\u00f5te", "sortable": true, "tooltip": "(clocking.Sessions.summary) Summary of the session.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 8, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "sortable": false, "tooltip": "(clocking.Sessions.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 9, "dataIndex": "ticket_no", "editable": false, "header": "Ticket #", "sortable": false, "tooltip": "(clocking.Sessions.ticket_no) ", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 10, "dataIndex": "id", "editable": true, "editor": id5421, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.Sessions.id) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "session_type", "editable": true, "editor": session_type5422, "filter": { "type": "string" }, "header": "Istungiliik", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.session_type) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "description", "editable": true, "editor": description5423, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "faculty", "editable": true, "editor": faculty5424, "filter": { "type": "string" }, "header": "Oskus", "hidden": true, "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(clocking.Sessions.faculty) The faculty that has been used during this session. On a new\nsession this defaults to the needed faculty currently specified\non the ticket.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type5425, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 15, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(clocking.Sessions.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.Sessions.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.Sessions.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.Sessions.insertPanel = Ext.extend(Lino.clocking.Sessions.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/Sessions",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.Sessions.detail;
    this.ls_insert_handler = Lino.clocking.Sessions.insert;
    Lino.clocking.Sessions.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.Sessions.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.Sessions.insertPanel(p);
});
Lino.clocking.Sessions.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.Sessions.detailPanel = Ext.extend(Lino.clocking.Sessions.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/Sessions",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.Sessions.detail;
    this.ls_insert_handler = Lino.clocking.Sessions.insert;
    Lino.clocking.Sessions.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.Sessions.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.Sessions.detailPanel(p);
});
Lino.clocking.Sessions.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.Sessions.ParamsPanel({});
  return new Lino.clocking.Sessions.GridPanel(p);
});
Lino.clocking.Sessions.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.Sessions.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/Sessions", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.MySessions
Lino.clocking.MySessions.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/MySessions",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/MySessions','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/MySessions','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Istungid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 25,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "name": "end_time" }, { "name": "break_time" }, { "name": "duration" }, { "name": "ticket_no" }, { "name": "summary" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "ticket" }, 'ticketHidden', { "name": "session_type" }, 'session_typeHidden', { "name": "description" }, { "name": "faculty" }, 'facultyHidden', { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 52,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.MySessions.detail;
    this.ls_insert_handler = Lino.clocking.MySessions.insert;
    var ww = this.containing_window;
    var start_date5431 = new Lino.DateField({ "selectOnFocus": true });
    var start_time5432 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time5433 = new Lino.TimeField({ "selectOnFocus": true });
    var break_time5434 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "maxLength": 6, "selectOnFocus": true });
    var duration5435 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var ticket_no_disp5436 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var summary5437 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5438 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var end_date5439 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var user5440 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessions/user" }) }) });
    var ticket5441 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessions/ticket" }) }) });
    var session_type5442 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Istungiliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessions/session_type" }) }) });
    var description5443 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var faculty5444 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessions/faculty" }) }) });
    var reporting_type5445 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var mobile_item_disp5446 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5447 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5448 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5449 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5443.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date5431, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.MySessions.start_date) The date when you started to work.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "start_time", "editable": true, "editor": start_time5432, "header": "Start time", "sortable": true, "tooltip": "(clocking.MySessions.start_time) The time (in hh:mm) when you started working on this\nsession.", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "end_time", "editable": true, "editor": end_time5433, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(clocking.MySessions.end_time) The time (in hh:mm) when you stopped to work. This is empty\nas long as you are busy with this session.", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 3, "dataIndex": "break_time", "editable": true, "editor": break_time5434, "filter": { "type": "string" }, "format": "", "header": "Paus", "sortable": true, "tooltip": "(clocking.MySessions.break_time) The time (in hh:mm) to remove from the duration resulting\nfrom the difference between start_time and\nend_time.", "width": Lino.chars2width(8) }, { "align": "right", "colIndex": 4, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "sortable": false, "tooltip": "(clocking.MySessions.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 5, "dataIndex": "ticket_no", "editable": false, "header": "Ticket #", "sortable": false, "tooltip": "(clocking.MySessions.ticket_no) ", "width": Lino.chars2width(9) }, { "colIndex": 6, "dataIndex": "summary", "editable": true, "editor": summary5437, "filter": { "type": "string" }, "header": "Kokkuv\u00f5te", "sortable": true, "tooltip": "(clocking.MySessions.summary) Summary of the session.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 7, "dataIndex": "id", "editable": true, "editor": id5438, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.MySessions.id) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date5439, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(clocking.MySessions.end_date) Leave this field blank if it is the same date as start_date.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user5440, "filter": { "type": "string" }, "header": "T\u00f6\u00f6taja", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(clocking.MySessions.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "ticket", "editable": true, "editor": ticket5441, "filter": { "type": "string" }, "header": "Lipik", "hidden": true, "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(clocking.MySessions.ticket) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "session_type", "editable": true, "editor": session_type5442, "filter": { "type": "string" }, "header": "Istungiliik", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.session_type) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "description", "editable": true, "editor": description5443, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "faculty", "editable": true, "editor": faculty5444, "filter": { "type": "string" }, "header": "Oskus", "hidden": true, "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(clocking.MySessions.faculty) The faculty that has been used during this session. On a new\nsession this defaults to the needed faculty currently specified\non the ticket.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type5445, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 15, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessions.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.MySessions.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.MySessions.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.MySessions.insertPanel = Ext.extend(Lino.clocking.Sessions.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/MySessions",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.MySessions.detail;
    this.ls_insert_handler = Lino.clocking.MySessions.insert;
    Lino.clocking.MySessions.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.MySessions.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.MySessions.insertPanel(p);
});
Lino.clocking.MySessions.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.MySessions.detailPanel = Ext.extend(Lino.clocking.Sessions.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/MySessions",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.MySessions.detail;
    this.ls_insert_handler = Lino.clocking.MySessions.insert;
    Lino.clocking.MySessions.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.MySessions.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.MySessions.detailPanel(p);
});
Lino.clocking.MySessions.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.Sessions.ParamsPanel({});
  return new Lino.clocking.MySessions.GridPanel(p);
});
Lino.clocking.MySessions.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessions.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessions", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.MySessionsByDate
Lino.clocking.MySessionsByDate.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/MySessionsByDate",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/MySessionsByDate','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/MySessionsByDate','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "My sessions by date",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 27,
  ls_store_fields : [ { "name": "start_time" }, { "name": "end_time" }, { "name": "break_time" }, { "name": "duration" }, { "name": "summary" }, { "name": "ticket" }, 'ticketHidden', { "name": "ticket__project" }, 'ticket__projectHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "session_type" }, 'session_typeHidden', { "name": "description" }, { "name": "faculty" }, 'facultyHidden', { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "ticket_no" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 10,
  ls_grid_configs : [  ],
  content_type : 52,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.MySessionsByDate.detail;
    this.ls_insert_handler = Lino.clocking.MySessionsByDate.insert;
    var ww = this.containing_window;
    var start_time5451 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time5452 = new Lino.TimeField({ "selectOnFocus": true });
    var break_time5453 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "maxLength": 6, "selectOnFocus": true });
    var duration5454 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var summary5455 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var ticket5456 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessionsByDate/ticket" }) }) });
    var ticket__project5457 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "sortable": false, "store": new Lino.ComplexRemoteComboStore({  }) });
    var workflow_buttons_disp5458 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5459 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date5460 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date5461 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var user5462 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessionsByDate/user" }) }) });
    var session_type5463 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Istungiliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessionsByDate/session_type" }) }) });
    var description5464 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var faculty5465 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/MySessionsByDate/faculty" }) }) });
    var reporting_type5466 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var ticket_no_disp5467 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5468 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5469 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5470 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description5464.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_time", "editable": true, "editor": start_time5451, "header": "Start time", "sortable": true, "tooltip": "(clocking.MySessionsByDate.start_time) The time (in hh:mm) when you started working on this\nsession.", "width": Lino.chars2width(9) }, { "colIndex": 1, "dataIndex": "end_time", "editable": true, "editor": end_time5452, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(clocking.MySessionsByDate.end_time) The time (in hh:mm) when you stopped to work. This is empty\nas long as you are busy with this session.", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 2, "dataIndex": "break_time", "editable": true, "editor": break_time5453, "filter": { "type": "string" }, "format": "", "header": "Paus", "sortable": true, "tooltip": "(clocking.MySessionsByDate.break_time) The time (in hh:mm) to remove from the duration resulting\nfrom the difference between start_time and\nend_time.", "width": Lino.chars2width(8) }, { "align": "right", "colIndex": 3, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "sortable": false, "tooltip": "(clocking.MySessionsByDate.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 4, "dataIndex": "summary", "editable": true, "editor": summary5455, "filter": { "type": "string" }, "header": "Kokkuv\u00f5te", "sortable": true, "tooltip": "(clocking.MySessionsByDate.summary) Summary of the session.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "ticket", "editable": true, "editor": ticket5456, "filter": { "type": "string" }, "header": "Lipik", "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(clocking.MySessionsByDate.ticket) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "ticket__project", "editable": false, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "sortable": false, "tooltip": "(clocking.MySessionsByDate.ticket__project) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(clocking.MySessionsByDate.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 8, "dataIndex": "id", "editable": true, "editor": id5459, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.MySessionsByDate.id) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "start_date", "editable": true, "editor": start_date5460, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(clocking.MySessionsByDate.start_date) The date when you started to work.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_date", "editable": true, "editor": end_date5461, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(clocking.MySessionsByDate.end_date) Leave this field blank if it is the same date as start_date.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 11, "dataIndex": "user", "editable": true, "editor": user5462, "filter": { "type": "string" }, "header": "T\u00f6\u00f6taja", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(clocking.MySessionsByDate.user) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "session_type", "editable": true, "editor": session_type5463, "filter": { "type": "string" }, "header": "Istungiliik", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.session_type) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description5464, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "faculty", "editable": true, "editor": faculty5465, "filter": { "type": "string" }, "header": "Oskus", "hidden": true, "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(clocking.MySessionsByDate.faculty) The faculty that has been used during this session. On a new\nsession this defaults to the needed faculty currently specified\non the ticket.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type5466, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 16, "dataIndex": "ticket_no", "editable": false, "header": "Ticket #", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.ticket_no) ", "width": Lino.chars2width(9) }, { "colIndex": 17, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.MySessionsByDate.overview) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.MySessionsByDate.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.MySessionsByDate.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.MySessionsByDate.insertPanel = Ext.extend(Lino.clocking.Sessions.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/MySessionsByDate",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.MySessionsByDate.detail;
    this.ls_insert_handler = Lino.clocking.MySessionsByDate.insert;
    Lino.clocking.MySessionsByDate.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.MySessionsByDate.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.MySessionsByDate.insertPanel(p);
});
Lino.clocking.MySessionsByDate.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.MySessionsByDate.detailPanel = Ext.extend(Lino.clocking.Sessions.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/MySessionsByDate",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.MySessionsByDate.detail;
    this.ls_insert_handler = Lino.clocking.MySessionsByDate.insert;
    Lino.clocking.MySessionsByDate.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.MySessionsByDate.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.MySessionsByDate.detailPanel(p);
});
Lino.clocking.MySessionsByDate.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.Sessions.ParamsPanel({});
  return new Lino.clocking.MySessionsByDate.GridPanel(p);
});
Lino.clocking.MySessionsByDate.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.MySessionsByDate.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/MySessionsByDate", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.ServiceReports
Lino.clocking.ServiceReports.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/ServiceReports",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/ServiceReports','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/ServiceReports','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Service Report", "overflowText": "Service Report", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Service Reports",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 23,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "interesting_for" }, 'interesting_forHidden', { "name": "ticket_state" }, 'ticket_stateHidden', { "name": "printed" }, { "name": "id", "type": "int" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "printed_by" }, 'printed_byHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 51,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ServiceReports.detail;
    this.ls_insert_handler = Lino.clocking.ServiceReports.insert;
    var ww = this.containing_window;
    var start_date5472 = new Lino.DateField({ "selectOnFocus": true });
    var end_date5473 = new Lino.DateField({ "selectOnFocus": true });
    var user5474 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/user" }) }) });
    var interesting_for5475 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/interesting_for" }) }) });
    var ticket_state5476 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var printed_disp5477 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5478 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var company5479 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/company" }) }) });
    var contact_person5480 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/contact_person" }) }) });
    var contact_role5481 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ServiceReports/contact_role" }) }) });
    var printed_by5482 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var mobile_item_disp5483 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5484 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5485 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5486 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person5480.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company5479.on('change',Lino.chooser_handler(contact_person5480,'company'));
      Lino.clocking.ServiceReports.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date5472, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.ServiceReports.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "end_date", "editable": true, "editor": end_date5473, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.ServiceReports.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5474, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(clocking.ServiceReports.user) This can be empty and will then show the working time of all\nusers.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "interesting_for", "editable": true, "editor": interesting_for5475, "filter": { "type": "string" }, "header": "Interesting for", "renderer": Lino.fk_renderer('interesting_forHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(clocking.ServiceReports.interesting_for) Only tickets interesting for this partner.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "ticket_state", "editable": true, "editor": ticket_state5476, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(clocking.ServiceReports.ticket_state) Only tickets in this state.", "width": Lino.chars2width(12) }, { "colIndex": 5, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "sortable": false, "tooltip": "(clocking.ServiceReports.printed) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id5478, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.ServiceReports.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "company", "editable": true, "editor": company5479, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(clocking.ServiceReports.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_person", "editable": true, "editor": contact_person5480, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(clocking.ServiceReports.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "contact_role", "editable": true, "editor": contact_role5481, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(clocking.ServiceReports.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(clocking.ServiceReports.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.ServiceReports.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.ServiceReports.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.ServiceReports.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(clocking.ServiceReports.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.ServiceReports.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ServiceReports.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.ServiceReports.insertPanel = Ext.extend(Lino.clocking.ServiceReports.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/ServiceReports",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ServiceReports.detail;
    this.ls_insert_handler = Lino.clocking.ServiceReports.insert;
    Lino.clocking.ServiceReports.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ServiceReports.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.ServiceReports.insertPanel(p);
});
Lino.clocking.ServiceReports.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.ServiceReports.detailPanel = Ext.extend(Lino.clocking.ServiceReports.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Service Report", "overflowText": "Service Report", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/clocking/ServiceReports",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ServiceReports.detail;
    this.ls_insert_handler = Lino.clocking.ServiceReports.insert;
    Lino.clocking.ServiceReports.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ServiceReports.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.ServiceReports.detailPanel(p);
});
Lino.clocking.ServiceReports.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ServiceReports.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.ServiceReports.ParamsPanel({});
  return new Lino.clocking.ServiceReports.GridPanel(p);
});
Lino.clocking.ServiceReports.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ServiceReports", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class lists.ListTypes
Lino.lists.ListTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/lists/ListTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/lists/ListTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/lists/ListTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Listiliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 54,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var name5488 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5489 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5490 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp5491 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5492 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5493 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5494 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name5488, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(lists.ListTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et5489, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(lists.ListTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id5490, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(lists.ListTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.ListTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.ListTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(lists.ListTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(lists.ListTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.lists.ListTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.ListTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/ListTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.ListTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/ListTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.ListTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/ListTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.ListTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/ListTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.ListTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/ListTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.ListTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/ListTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.ListTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.ListTypes.GridPanel(p);
});

// js_render_GridPanel_class lists.Lists
Lino.lists.Lists.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/lists/Lists",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/lists/Lists','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_white_acrobat", "itemId": "print_labels", "menu_item_text": "Labels", "overflowText": "Labels", "panel_btn_handler": Lino.list_action_handler('/lists/Lists','print_labels','GET',Lino.get_current_grid_config), "tooltip": "Generate mailing labels for these recipients" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/lists/Lists','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Partnerite nimekirjad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 12,
  ls_store_fields : [ { "name": "ref" }, { "name": "overview" }, { "name": "list_type" }, 'list_typeHidden', { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "remarks" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 56,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.lists.Lists.detail;
    this.ls_insert_handler = Lino.lists.Lists.insert;
    var ww = this.containing_window;
    var ref5496 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var overview_disp5497 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var list_type5498 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Listiliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/Lists/list_type" }) }) });
    var id5499 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name5500 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name_et5501 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks5502 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var mobile_item_disp5503 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5504 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5505 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      remarks5502.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref5496, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(lists.Lists.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(lists.Lists.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "list_type", "editable": true, "editor": list_type5498, "filter": { "type": "string" }, "header": "Listiliik", "sortable": false, "tooltip": "(lists.Lists.list_type) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id5499, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(lists.Lists.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "name", "editable": true, "editor": name5500, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(lists.Lists.name) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "name_et", "editable": true, "editor": name_et5501, "filter": { "type": "string" }, "header": "Nimetus (et)", "hidden": true, "sortable": true, "tooltip": "(lists.Lists.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "remarks", "editable": true, "editor": remarks5502, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(lists.Lists.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.Lists.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.Lists.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(lists.Lists.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.lists.Lists.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.Lists.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Lists.print_labels = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "print_labels", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Lists.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Lists.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.lists.Lists.insertPanel = Ext.extend(Lino.lists.Lists.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/lists/Lists",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.lists.Lists.detail;
    this.ls_insert_handler = Lino.lists.Lists.insert;
    Lino.lists.Lists.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.Lists.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(12), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.lists.Lists.insertPanel(p);
});
Lino.lists.Lists.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Lists.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Lists.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.lists.Lists.detailPanel = Ext.extend(Lino.lists.Lists.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/lists/Lists",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.lists.Lists.detail;
    this.ls_insert_handler = Lino.lists.Lists.insert;
    Lino.lists.Lists.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.Lists.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.Lists.detailPanel(p);
});
Lino.lists.Lists.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Lists.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.Lists.GridPanel(p);
});
Lino.lists.Lists.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Lists", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class lists.Members
Lino.lists.Members.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/lists/Members",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/lists/Members','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/lists/Members','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Listi tellimused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "list" }, 'listHidden', { "name": "partner" }, 'partnerHidden', { "name": "remark" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 55,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5507 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno5508 = new Ext.form.NumberField({ "selectOnFocus": true });
    var list5509 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/Members/list" }) }) });
    var partner5510 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/Members/partner" }) }) });
    var remark5511 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var move_buttons_disp5512 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5513 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5514 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5515 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5516 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5507, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(lists.Members.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno5508, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(lists.Members.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "list", "editable": true, "editor": list5509, "filter": { "type": "string" }, "header": "Partnerite nimekiri", "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(lists.Members.list) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "partner", "editable": true, "editor": partner5510, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(lists.Members.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "remark", "editable": true, "editor": remark5511, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(lists.Members.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(lists.Members.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.Members.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.Members.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(lists.Members.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(lists.Members.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.lists.Members.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.Members.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.Members.GridPanel(p);
});
Lino.lists.Members.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.Members.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/Members", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class lists.AllMembers
Lino.lists.AllMembers.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/lists/AllMembers",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/lists/AllMembers','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/lists/AllMembers','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Listi tellimused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "list" }, 'listHidden', { "name": "partner" }, 'partnerHidden', { "name": "remark" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 55,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5518 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno5519 = new Ext.form.NumberField({ "selectOnFocus": true });
    var list5520 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/AllMembers/list" }) }) });
    var partner5521 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/AllMembers/partner" }) }) });
    var remark5522 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var move_buttons_disp5523 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5524 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5525 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5526 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5527 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5518, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(lists.AllMembers.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno5519, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(lists.AllMembers.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "list", "editable": true, "editor": list5520, "filter": { "type": "string" }, "header": "Partnerite nimekiri", "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(lists.AllMembers.list) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "partner", "editable": true, "editor": partner5521, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(lists.AllMembers.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "remark", "editable": true, "editor": remark5522, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(lists.AllMembers.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(lists.AllMembers.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.AllMembers.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.AllMembers.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(lists.AllMembers.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(lists.AllMembers.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.lists.AllMembers.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.AllMembers.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.AllMembers.GridPanel(p);
});
Lino.lists.AllMembers.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.AllMembers.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/AllMembers", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.EntryTypes
Lino.blogs.EntryTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/EntryTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/EntryTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/EntryTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Blog Entry Types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "important", "type": "boolean" }, { "name": "remark" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 58,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntryTypes.detail;
    this.ls_insert_handler = Lino.blogs.EntryTypes.insert;
    var ww = this.containing_window;
    var id5529 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name5530 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5531 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var important5532 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var remark5533 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var mobile_item_disp5534 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5535 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5536 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5537 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      remark5533.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5529, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(blogs.EntryTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5530, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(blogs.EntryTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et5531, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(blogs.EntryTypes.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "important", "editable": true, "filter": { "type": "boolean" }, "header": "important", "sortable": false, "tooltip": "(blogs.EntryTypes.important) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 4, "dataIndex": "remark", "editable": true, "editor": remark5533, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": false, "tooltip": "(blogs.EntryTypes.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntryTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntryTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.EntryTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.EntryTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.blogs.EntryTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntryTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntryTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntryTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.EntryTypes.insertPanel = Ext.extend(Lino.blogs.EntryTypes.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/EntryTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntryTypes.detail;
    this.ls_insert_handler = Lino.blogs.EntryTypes.insert;
    Lino.blogs.EntryTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntryTypes.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.EntryTypes.insertPanel(p);
});
Lino.blogs.EntryTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntryTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntryTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.EntryTypes.detailPanel = Ext.extend(Lino.blogs.EntryTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/EntryTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntryTypes.detail;
    this.ls_insert_handler = Lino.blogs.EntryTypes.insert;
    Lino.blogs.EntryTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntryTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.EntryTypes.detailPanel(p);
});
Lino.blogs.EntryTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntryTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.EntryTypes.GridPanel(p);
});
Lino.blogs.EntryTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntryTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.Entries
Lino.blogs.Entries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/Entries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/Entries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/Entries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "pub_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "entry_type" }, 'entry_typeHidden', { "name": "title" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "pub_time" }, { "name": "language" }, 'languageHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "body" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 57,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.Entries.detail;
    this.ls_insert_handler = Lino.blogs.Entries.insert;
    var ww = this.containing_window;
    var id3008 = new Ext.form.NumberField({ "selectOnFocus": true });
    var pub_date3009 = new Lino.DateField({ "selectOnFocus": true });
    var user3010 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/user" }) }) });
    var entry_type3011 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Blog Entry Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/entry_type" }) }) });
    var title3012 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var owner_type3013 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/owner_type" }) }) });
    var owner_id3014 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Entries/owner_id" }) }) });
    var pub_time3015 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var language3016 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp3017 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp3018 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3019 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3020 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3021 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var body3022 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Body" });
    this.before_row_edit = function(record) {
      owner_id3014.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body3022.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type3013.on('change',Lino.chooser_handler(owner_id3014,'owner_type'));
      Lino.blogs.Entries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3008, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(blogs.Entries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "pub_date", "editable": true, "editor": pub_date3009, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Publication date", "sortable": true, "tooltip": "(blogs.Entries.pub_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3010, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(blogs.Entries.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "entry_type", "editable": true, "editor": entry_type3011, "filter": { "type": "string" }, "header": "Blog Entry Type", "renderer": Lino.fk_renderer('entry_typeHidden','Lino.blogs.EntryTypes.detail'), "sortable": false, "tooltip": "(blogs.Entries.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "title", "editable": true, "editor": title3012, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.Entries.title) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type3013, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(blogs.Entries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id3014, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "pub_time", "editable": true, "editor": pub_time3015, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.Entries.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "language", "editable": true, "editor": language3016, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.language) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "body", "editable": true, "editor": body3022, "filter": { "type": "string" }, "header": "Body", "sortable": false, "tooltip": "(blogs.Entries.body) ", "width": Lino.chars2width(61) } ];
    Lino.blogs.Entries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.Entries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Entries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Entries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.Entries.insertPanel = Ext.extend(Lino.blogs.Entries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/Entries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.Entries.detail;
    this.ls_insert_handler = Lino.blogs.Entries.insert;
    Lino.blogs.Entries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.Entries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.Entries.insertPanel(p);
});
Lino.blogs.Entries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Entries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Entries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.Entries.detailPanel = Ext.extend(Lino.blogs.Entries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/Entries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.Entries.detail;
    this.ls_insert_handler = Lino.blogs.Entries.insert;
    Lino.blogs.Entries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.Entries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.Entries.detailPanel(p);
});
Lino.blogs.Entries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Entries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.blogs.Entries.ParamsPanel({});
  return new Lino.blogs.Entries.GridPanel(p);
});
Lino.blogs.Entries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.MyEntries
Lino.blogs.MyEntries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/MyEntries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/MyEntries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/MyEntries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Minu Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "pub_date", "type": "date" }, { "name": "entry_type" }, 'entry_typeHidden', { "name": "title" }, { "name": "body" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "pub_time" }, { "name": "language" }, 'languageHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 57,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.MyEntries.detail;
    this.ls_insert_handler = Lino.blogs.MyEntries.insert;
    var ww = this.containing_window;
    var id5539 = new Ext.form.NumberField({ "selectOnFocus": true });
    var pub_date5540 = new Lino.DateField({ "selectOnFocus": true });
    var entry_type5541 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Blog Entry Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/MyEntries/entry_type" }) }) });
    var title5542 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var body5543 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Body" });
    var user5544 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/MyEntries/user" }) }) });
    var owner_type5545 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/MyEntries/owner_type" }) }) });
    var owner_id5546 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/MyEntries/owner_id" }) }) });
    var pub_time5547 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var language5548 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp5549 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp5550 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5551 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5552 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5553 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      body5543.refresh();
      owner_id5546.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type5545.on('change',Lino.chooser_handler(owner_id5546,'owner_type'));
      Lino.blogs.MyEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5539, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(blogs.MyEntries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "pub_date", "editable": true, "editor": pub_date5540, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Publication date", "sortable": true, "tooltip": "(blogs.MyEntries.pub_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "entry_type", "editable": true, "editor": entry_type5541, "filter": { "type": "string" }, "header": "Blog Entry Type", "renderer": Lino.fk_renderer('entry_typeHidden','Lino.blogs.EntryTypes.detail'), "sortable": false, "tooltip": "(blogs.MyEntries.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "title", "editable": true, "editor": title5542, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.MyEntries.title) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "body", "editable": true, "editor": body5543, "filter": { "type": "string" }, "header": "Body", "sortable": false, "tooltip": "(blogs.MyEntries.body) ", "width": Lino.chars2width(61) }, { "colIndex": 5, "dataIndex": "user", "editable": true, "editor": user5544, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(blogs.MyEntries.user) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type5545, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(blogs.MyEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id5546, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "pub_time", "editable": true, "editor": pub_time5547, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.MyEntries.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "language", "editable": true, "editor": language5548, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.language) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.MyEntries.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.blogs.MyEntries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.MyEntries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.MyEntries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.MyEntries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.MyEntries.insertPanel = Ext.extend(Lino.blogs.Entries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/MyEntries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.MyEntries.detail;
    this.ls_insert_handler = Lino.blogs.MyEntries.insert;
    Lino.blogs.MyEntries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.MyEntries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.MyEntries.insertPanel(p);
});
Lino.blogs.MyEntries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.MyEntries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.MyEntries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.MyEntries.detailPanel = Ext.extend(Lino.blogs.Entries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/MyEntries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.MyEntries.detail;
    this.ls_insert_handler = Lino.blogs.MyEntries.insert;
    Lino.blogs.MyEntries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.MyEntries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.MyEntries.detailPanel(p);
});
Lino.blogs.MyEntries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.MyEntries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.blogs.Entries.ParamsPanel({});
  return new Lino.blogs.MyEntries.GridPanel(p);
});
Lino.blogs.MyEntries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/MyEntries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.AllEntries
Lino.blogs.AllEntries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/AllEntries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/AllEntries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/AllEntries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "pub_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "entry_type" }, 'entry_typeHidden', { "name": "title" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "pub_time" }, { "name": "language" }, 'languageHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "body" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 57,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.AllEntries.detail;
    this.ls_insert_handler = Lino.blogs.AllEntries.insert;
    var ww = this.containing_window;
    var id5555 = new Ext.form.NumberField({ "selectOnFocus": true });
    var pub_date5556 = new Lino.DateField({ "selectOnFocus": true });
    var user5557 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/AllEntries/user" }) }) });
    var entry_type5558 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Blog Entry Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/AllEntries/entry_type" }) }) });
    var title5559 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var owner_type5560 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/AllEntries/owner_type" }) }) });
    var owner_id5561 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/AllEntries/owner_id" }) }) });
    var pub_time5562 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var language5563 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp5564 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp5565 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5566 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5567 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5568 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var body5569 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Body" });
    this.before_row_edit = function(record) {
      owner_id5561.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body5569.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type5560.on('change',Lino.chooser_handler(owner_id5561,'owner_type'));
      Lino.blogs.AllEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5555, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(blogs.AllEntries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "pub_date", "editable": true, "editor": pub_date5556, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Publication date", "sortable": true, "tooltip": "(blogs.AllEntries.pub_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5557, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(blogs.AllEntries.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "entry_type", "editable": true, "editor": entry_type5558, "filter": { "type": "string" }, "header": "Blog Entry Type", "renderer": Lino.fk_renderer('entry_typeHidden','Lino.blogs.EntryTypes.detail'), "sortable": false, "tooltip": "(blogs.AllEntries.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "title", "editable": true, "editor": title5559, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.AllEntries.title) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type5560, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(blogs.AllEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id5561, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "pub_time", "editable": true, "editor": pub_time5562, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.AllEntries.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "language", "editable": true, "editor": language5563, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.language) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.AllEntries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "body", "editable": true, "editor": body5569, "filter": { "type": "string" }, "header": "Body", "sortable": false, "tooltip": "(blogs.AllEntries.body) ", "width": Lino.chars2width(61) } ];
    Lino.blogs.AllEntries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.AllEntries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllEntries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllEntries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.AllEntries.insertPanel = Ext.extend(Lino.blogs.Entries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/AllEntries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.AllEntries.detail;
    this.ls_insert_handler = Lino.blogs.AllEntries.insert;
    Lino.blogs.AllEntries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.AllEntries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.AllEntries.insertPanel(p);
});
Lino.blogs.AllEntries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllEntries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllEntries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.AllEntries.detailPanel = Ext.extend(Lino.blogs.Entries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/AllEntries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.AllEntries.detail;
    this.ls_insert_handler = Lino.blogs.AllEntries.insert;
    Lino.blogs.AllEntries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.AllEntries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.AllEntries.detailPanel(p);
});
Lino.blogs.AllEntries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllEntries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.blogs.Entries.ParamsPanel({});
  return new Lino.blogs.AllEntries.GridPanel(p);
});
Lino.blogs.AllEntries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllEntries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.LatestEntries
Lino.blogs.LatestEntries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/LatestEntries",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/LatestEntries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/LatestEntries','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Latest blog entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "pub_date", "type": "date" }, { "name": "title" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "body" }, { "name": "pub_time" }, { "name": "entry_type" }, 'entry_typeHidden', { "name": "language" }, 'languageHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 57,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.LatestEntries.detail;
    this.ls_insert_handler = Lino.blogs.LatestEntries.insert;
    var ww = this.containing_window;
    var pub_date3024 = new Lino.DateField({ "selectOnFocus": true });
    var title3025 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3026 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/LatestEntries/user" }) }) });
    var id3027 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type3028 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/LatestEntries/owner_type" }) }) });
    var owner_id3029 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/LatestEntries/owner_id" }) }) });
    var body3030 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var pub_time3031 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var entry_type3032 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Blog Entry Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/LatestEntries/entry_type" }) }) });
    var language3033 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp3034 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp3035 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3036 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3037 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3038 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id3029.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body3030.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type3028.on('change',Lino.chooser_handler(owner_id3029,'owner_type'));
      Lino.blogs.LatestEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "pub_date", "editable": true, "editor": pub_date3024, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Publication date", "sortable": true, "tooltip": "(blogs.LatestEntries.pub_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "title", "editable": true, "editor": title3025, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.LatestEntries.title) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3026, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(blogs.LatestEntries.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id3027, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(blogs.LatestEntries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type3028, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(blogs.LatestEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id3029, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "body", "editable": true, "editor": body3030, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.body) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "pub_time", "editable": true, "editor": pub_time3031, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.LatestEntries.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "entry_type", "editable": true, "editor": entry_type3032, "filter": { "type": "string" }, "header": "Blog Entry Type", "hidden": true, "renderer": Lino.fk_renderer('entry_typeHidden','Lino.blogs.EntryTypes.detail'), "sortable": false, "tooltip": "(blogs.LatestEntries.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "language", "editable": true, "editor": language3033, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.language) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.blogs.LatestEntries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.LatestEntries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.LatestEntries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.LatestEntries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.LatestEntries.insertPanel = Ext.extend(Lino.blogs.Entries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/LatestEntries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.LatestEntries.detail;
    this.ls_insert_handler = Lino.blogs.LatestEntries.insert;
    Lino.blogs.LatestEntries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.LatestEntries.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.LatestEntries.insertPanel(p);
});
Lino.blogs.LatestEntries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.LatestEntries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.LatestEntries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.LatestEntries.detailPanel = Ext.extend(Lino.blogs.Entries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/LatestEntries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.LatestEntries.detail;
    this.ls_insert_handler = Lino.blogs.LatestEntries.insert;
    Lino.blogs.LatestEntries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.LatestEntries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.LatestEntries.detailPanel(p);
});
Lino.blogs.LatestEntries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.LatestEntries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.blogs.Entries.ParamsPanel({});
  return new Lino.blogs.LatestEntries.GridPanel(p);
});
Lino.blogs.LatestEntries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.Taggings
Lino.blogs.Taggings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/Taggings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/Taggings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/Taggings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Taggings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "topic" }, 'topicHidden', { "name": "entry" }, 'entryHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 59,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5571 = new Ext.form.NumberField({ "selectOnFocus": true });
    var topic5572 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Taggings/topic" }) }) });
    var entry5573 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Blog Entry...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/Taggings/entry" }) }) });
    var mobile_item_disp5574 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5575 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5576 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5577 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5571, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(blogs.Taggings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "topic", "editable": true, "editor": topic5572, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(blogs.Taggings.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "entry", "editable": true, "editor": entry5573, "filter": { "type": "string" }, "header": "Blog Entry", "renderer": Lino.fk_renderer('entryHidden','Lino.blogs.Entries.detail'), "sortable": false, "tooltip": "(blogs.Taggings.entry) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.Taggings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.Taggings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.Taggings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.Taggings.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.blogs.Taggings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.Taggings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Taggings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Taggings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Taggings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Taggings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Taggings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Taggings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Taggings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Taggings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Taggings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Taggings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Taggings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Taggings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.Taggings.GridPanel(p);
});

// js_render_GridPanel_class blogs.AllTaggings
Lino.blogs.AllTaggings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/AllTaggings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/AllTaggings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/AllTaggings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Taggings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "topic" }, 'topicHidden', { "name": "entry" }, 'entryHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 59,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5579 = new Ext.form.NumberField({ "selectOnFocus": true });
    var topic5580 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/AllTaggings/topic" }) }) });
    var entry5581 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Blog Entry...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/AllTaggings/entry" }) }) });
    var mobile_item_disp5582 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5583 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5584 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5585 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5579, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(blogs.AllTaggings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "topic", "editable": true, "editor": topic5580, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(blogs.AllTaggings.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "entry", "editable": true, "editor": entry5581, "filter": { "type": "string" }, "header": "Blog Entry", "renderer": Lino.fk_renderer('entryHidden','Lino.blogs.Entries.detail'), "sortable": false, "tooltip": "(blogs.AllTaggings.entry) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.AllTaggings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.AllTaggings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.AllTaggings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.AllTaggings.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.blogs.AllTaggings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.AllTaggings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllTaggings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllTaggings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllTaggings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllTaggings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllTaggings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllTaggings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllTaggings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllTaggings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllTaggings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllTaggings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/AllTaggings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.AllTaggings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.AllTaggings.GridPanel(p);
});

// js_render_GridPanel_class notify.Messages
Lino.notify.Messages.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/notify/Messages",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/notify/Messages','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/notify/Messages','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "mark_all_seen", "menu_item_text": "Mark all as seen", "overflowText": "Mark all as seen", "panel_btn_handler": Lino.list_action_handler('/notify/Messages','mark_all_seen','POST',null), "text": "Mark all as seen" } ],
  cell_edit : true,
  title : "Teaded",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 23,
  ls_store_fields : [ { "name": "created" }, { "name": "subject" }, { "name": "user" }, 'userHidden', { "name": "seen" }, { "name": "sent" }, { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "message_type" }, 'message_typeHidden', { "name": "body" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 60,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var created5587 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var subject5588 = new Ext.form.TextField({ "disabled": true, "maxLength": 250 });
    var user5589 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var seen5590 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var sent5591 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var id5592 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type5593 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/Messages/owner_type" }) }) });
    var owner_id5594 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/Messages/owner_id" }) }) });
    var message_type5595 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MessageTypes });
    var body5596 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body" });
    var mail_mode5597 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var owner_disp5598 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp5599 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5600 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5601 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5602 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5603 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id5594.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body5596.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type5593.on('change',Lino.chooser_handler(owner_id5594,'owner_type'));
      Lino.notify.Messages.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(notify.Messages.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "subject", "editable": false, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(notify.Messages.subject) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Recipient", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(notify.Messages.user) The recipient.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "seen", "editable": false, "header": "seen", "sortable": true, "tooltip": "(notify.Messages.seen) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(notify.Messages.sent) ", "width": Lino.chars2width(17) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5592, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(notify.Messages.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type5593, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(notify.Messages.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id5594, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "message_type", "editable": true, "editor": message_type5595, "filter": { "type": "string" }, "header": "Message Type", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.message_type) ", "width": Lino.chars2width(16) }, { "colIndex": 9, "dataIndex": "body", "editable": false, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.body) ", "width": Lino.chars2width(61) }, { "colIndex": 10, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5597, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 11, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.owner) The database object which controls this message.", "width": Lino.chars2width(11) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(notify.Messages.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.notify.Messages.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.notify.Messages.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.notify.Messages.ParamsPanel({});
  return new Lino.notify.Messages.GridPanel(p);
});
Lino.notify.Messages.mark_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "mark_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.clear_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "GET", pk, "clear_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.Messages.mark_all_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/Messages", "POST", pk, "mark_all_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class notify.AllMessages
Lino.notify.AllMessages.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/notify/AllMessages",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/notify/AllMessages','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/notify/AllMessages','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "mark_all_seen", "menu_item_text": "Mark all as seen", "overflowText": "Mark all as seen", "panel_btn_handler": Lino.list_action_handler('/notify/AllMessages','mark_all_seen','POST',null), "text": "Mark all as seen" } ],
  cell_edit : true,
  title : "Teaded",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 23,
  ls_store_fields : [ { "name": "created" }, { "name": "subject" }, { "name": "user" }, 'userHidden', { "name": "seen" }, { "name": "sent" }, { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "message_type" }, 'message_typeHidden', { "name": "body" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 60,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var created5605 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var subject5606 = new Ext.form.TextField({ "disabled": true, "maxLength": 250 });
    var user5607 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var seen5608 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var sent5609 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var id5610 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type5611 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/AllMessages/owner_type" }) }) });
    var owner_id5612 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/AllMessages/owner_id" }) }) });
    var message_type5613 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MessageTypes });
    var body5614 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body" });
    var mail_mode5615 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var owner_disp5616 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp5617 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5618 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5619 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5620 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5621 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id5612.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body5614.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type5611.on('change',Lino.chooser_handler(owner_id5612,'owner_type'));
      Lino.notify.AllMessages.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(notify.AllMessages.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "subject", "editable": false, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(notify.AllMessages.subject) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Recipient", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(notify.AllMessages.user) The recipient.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "seen", "editable": false, "header": "seen", "sortable": true, "tooltip": "(notify.AllMessages.seen) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(notify.AllMessages.sent) ", "width": Lino.chars2width(17) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5610, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(notify.AllMessages.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type5611, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(notify.AllMessages.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id5612, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "message_type", "editable": true, "editor": message_type5613, "filter": { "type": "string" }, "header": "Message Type", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.message_type) ", "width": Lino.chars2width(16) }, { "colIndex": 9, "dataIndex": "body", "editable": false, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.body) ", "width": Lino.chars2width(61) }, { "colIndex": 10, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5615, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 11, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.owner) The database object which controls this message.", "width": Lino.chars2width(11) }, { "colIndex": 12, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(notify.AllMessages.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.notify.AllMessages.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.notify.AllMessages.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.notify.Messages.ParamsPanel({});
  return new Lino.notify.AllMessages.GridPanel(p);
});
Lino.notify.AllMessages.mark_all_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "POST", pk, "mark_all_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.mark_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "mark_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.AllMessages.clear_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/AllMessages", "GET", pk, "clear_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class notify.MyMessages
Lino.notify.MyMessages.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/notify/MyMessages",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/notify/MyMessages','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/notify/MyMessages','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "mark_all_seen", "menu_item_text": "Mark all as seen", "overflowText": "Mark all as seen", "panel_btn_handler": Lino.list_action_handler('/notify/MyMessages','mark_all_seen','POST',null), "text": "Mark all as seen" } ],
  cell_edit : true,
  title : "Minu Teaded",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 23,
  ls_store_fields : [ { "name": "created" }, { "name": "subject" }, { "name": "message_type" }, 'message_typeHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "seen" }, { "name": "sent" }, { "name": "body" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 60,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var created5623 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var subject5624 = new Ext.form.TextField({ "disabled": true, "maxLength": 250 });
    var message_type5625 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.notify.MessageTypes });
    var workflow_buttons_disp5626 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5627 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var user5628 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var owner_type5629 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/MyMessages/owner_type" }) }) });
    var owner_id5630 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/notify/MyMessages/owner_id" }) }) });
    var seen5631 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var sent5632 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var body5633 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body" });
    var mail_mode5634 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var owner_disp5635 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp5636 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5637 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5638 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5639 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id5630.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body5633.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type5629.on('change',Lino.chooser_handler(owner_id5630,'owner_type'));
      Lino.notify.MyMessages.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(notify.MyMessages.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "subject", "editable": false, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(notify.MyMessages.subject) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "message_type", "editable": true, "editor": message_type5625, "filter": { "type": "string" }, "header": "Message Type", "sortable": false, "tooltip": "(notify.MyMessages.message_type) ", "width": Lino.chars2width(16) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(notify.MyMessages.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5627, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(notify.MyMessages.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Recipient", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(notify.MyMessages.user) The recipient.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type5629, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(notify.MyMessages.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id5630, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "seen", "editable": false, "header": "seen", "hidden": true, "sortable": true, "tooltip": "(notify.MyMessages.seen) ", "width": Lino.chars2width(17) }, { "colIndex": 9, "dataIndex": "sent", "editable": false, "header": "sent", "hidden": true, "sortable": true, "tooltip": "(notify.MyMessages.sent) ", "width": Lino.chars2width(17) }, { "colIndex": 10, "dataIndex": "body", "editable": false, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.body) ", "width": Lino.chars2width(61) }, { "colIndex": 11, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5634, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 12, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.owner) The database object which controls this message.", "width": Lino.chars2width(11) }, { "colIndex": 13, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(notify.MyMessages.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.notify.MyMessages.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.notify.MyMessages.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.notify.Messages.ParamsPanel({});
  return new Lino.notify.MyMessages.GridPanel(p);
});
Lino.notify.MyMessages.mark_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "mark_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.mark_all_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "POST", pk, "mark_all_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MyMessages.clear_seen = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MyMessages", "GET", pk, "clear_seen", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class uploads.UploadTypes
Lino.uploads.UploadTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/UploadTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Upload Types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "upload_area" }, 'upload_areaHidden', { "name": "name" }, { "name": "name_et" }, { "name": "max_number", "type": "int", "useNull": true }, { "name": "wanted", "type": "boolean" }, { "name": "shortcut" }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 61,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadTypes.detail;
    this.ls_insert_handler = Lino.uploads.UploadTypes.insert;
    var ww = this.containing_window;
    var upload_area5641 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var name5642 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5643 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var max_number5644 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": -1 });
    var wanted5645 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var shortcut5646 = new Ext.form.TextField({ "maxLength": 50, "selectOnFocus": true });
    var id5647 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp5648 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5649 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5650 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5651 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "upload_area", "editable": true, "editor": upload_area5641, "filter": { "type": "string" }, "header": "Upload Area", "sortable": false, "tooltip": "(uploads.UploadTypes.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5642, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(uploads.UploadTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et5643, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(uploads.UploadTypes.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 3, "dataIndex": "max_number", "editable": true, "editor": max_number5644, "filter": { "type": "numeric" }, "format": "0", "header": "Max. number", "sortable": true, "tooltip": "(uploads.UploadTypes.max_number) No need to upload more uploads than N of this type.\n-1 means no limit.", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "wanted", "editable": true, "filter": { "type": "boolean" }, "header": "Wanted", "sortable": false, "tooltip": "(uploads.UploadTypes.wanted) Add a (+) button when there is no upload of this type.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 5, "dataIndex": "shortcut", "editable": true, "editor": shortcut5646, "filter": { "type": "string" }, "header": "Upload shortcut", "sortable": true, "tooltip": "(uploads.UploadTypes.shortcut) Optional pointer to a virtual upload shortcut field.  If\nthis is not empty, then the given shortcut field will manage\nuploads of this type.  See also Shortcuts.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id5647, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.UploadTypes.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadTypes.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadTypes.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadTypes.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadTypes.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.UploadTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadTypes.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.UploadTypes.insertPanel = Ext.extend(Lino.uploads.UploadTypes.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/UploadTypes",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadTypes.detail;
    this.ls_insert_handler = Lino.uploads.UploadTypes.insert;
    Lino.uploads.UploadTypes.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadTypes.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.UploadTypes.insertPanel(p);
});
Lino.uploads.UploadTypes.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadTypes.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadTypes.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.UploadTypes.detailPanel = Ext.extend(Lino.uploads.UploadTypes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/UploadTypes",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadTypes.detail;
    this.ls_insert_handler = Lino.uploads.UploadTypes.insert;
    Lino.uploads.UploadTypes.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadTypes.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.UploadTypes.detailPanel(p);
});
Lino.uploads.UploadTypes.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.UploadTypes.GridPanel(p);
});
Lino.uploads.UploadTypes.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadTypes", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class uploads.Uploads
Lino.uploads.Uploads.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/Uploads",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/Uploads','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/Uploads','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Uploads",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "file" }, { "name": "type" }, 'typeHidden', { "name": "user" }, 'userHidden', { "name": "owner" }, { "name": "description" }, { "name": "id", "type": "int" }, { "name": "mimetype" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "upload_area" }, 'upload_areaHidden', { "name": "description_link" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 62,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.Uploads.detail;
    this.ls_insert_handler = Lino.uploads.Uploads.insert;
    var ww = this.containing_window;
    var file5653 = Lino.file_field_handler(this,{ "maxLength": 100, "selectOnFocus": true });
    var type5654 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Upload Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/type" }) }) });
    var user5655 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/user" }) }) });
    var owner_disp5656 = new Ext.form.DisplayField({ "disabled": true });
    var description5657 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5658 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mimetype5659 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": 255 });
    var owner_type5660 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/owner_type" }) }) });
    var owner_id5661 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/Uploads/owner_id" }) }) });
    var upload_area5662 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var description_link_disp5663 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5664 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5665 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5666 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5667 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      type5654.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
      owner_id5661.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      upload_area5662.on('change',Lino.chooser_handler(type5654,'upload_area'));
      owner_type5660.on('change',Lino.chooser_handler(owner_id5661,'owner_type'));
      Lino.uploads.Uploads.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "file", "editable": true, "editor": file5653, "filter": { "type": "string" }, "header": "Fail", "sortable": true, "tooltip": "(uploads.Uploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type5654, "filter": { "type": "string" }, "header": "Upload Type", "renderer": Lino.fk_renderer('typeHidden','Lino.uploads.UploadTypes.detail'), "sortable": false, "tooltip": "(uploads.Uploads.type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5655, "filter": { "type": "string" }, "header": "Uploaded by", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(uploads.Uploads.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(uploads.Uploads.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "description", "editable": true, "editor": description5657, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": true, "tooltip": "(uploads.Uploads.description) A short description entered manually by the user.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5658, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.Uploads.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mimetype", "editable": false, "filter": { "type": "string" }, "header": "MIME type", "hidden": true, "sortable": true, "tooltip": "(uploads.Uploads.mimetype) The Media type\nof the file.  See also this thread\nabout length of MIME type field.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "owner_type", "editable": true, "editor": owner_type5660, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(uploads.Uploads.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_id", "editable": true, "editor": owner_id5661, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "upload_area", "editable": true, "editor": upload_area5662, "filter": { "type": "string" }, "header": "Upload Area", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "description_link", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.description_link) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.Uploads.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.Uploads.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.Uploads.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Uploads.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Uploads.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.Uploads.insertPanel = Ext.extend(Lino.uploads.Uploads.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/Uploads",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.Uploads.detail;
    this.ls_insert_handler = Lino.uploads.Uploads.insert;
    Lino.uploads.Uploads.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.Uploads.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.Uploads.insertPanel(p);
});
Lino.uploads.Uploads.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Uploads.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Uploads.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.Uploads.detailPanel = Ext.extend(Lino.uploads.Uploads.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/Uploads",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.Uploads.detail;
    this.ls_insert_handler = Lino.uploads.Uploads.insert;
    Lino.uploads.Uploads.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.Uploads.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.Uploads.detailPanel(p);
});
Lino.uploads.Uploads.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Uploads.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.uploads.Uploads.ParamsPanel({});
  return new Lino.uploads.Uploads.GridPanel(p);
});
Lino.uploads.Uploads.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Uploads", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class uploads.AllUploads
Lino.uploads.AllUploads.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/AllUploads",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/AllUploads','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/AllUploads','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Uploads",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "file" }, { "name": "type" }, 'typeHidden', { "name": "user" }, 'userHidden', { "name": "owner" }, { "name": "description" }, { "name": "id", "type": "int" }, { "name": "mimetype" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "upload_area" }, 'upload_areaHidden', { "name": "description_link" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 62,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.AllUploads.detail;
    this.ls_insert_handler = Lino.uploads.AllUploads.insert;
    var ww = this.containing_window;
    var file5669 = Lino.file_field_handler(this,{ "maxLength": 100, "selectOnFocus": true });
    var type5670 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Upload Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AllUploads/type" }) }) });
    var user5671 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AllUploads/user" }) }) });
    var owner_disp5672 = new Ext.form.DisplayField({ "disabled": true });
    var description5673 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5674 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mimetype5675 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": 255 });
    var owner_type5676 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AllUploads/owner_type" }) }) });
    var owner_id5677 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AllUploads/owner_id" }) }) });
    var upload_area5678 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var description_link_disp5679 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5680 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5681 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5682 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5683 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      type5670.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
      owner_id5677.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      upload_area5678.on('change',Lino.chooser_handler(type5670,'upload_area'));
      owner_type5676.on('change',Lino.chooser_handler(owner_id5677,'owner_type'));
      Lino.uploads.AllUploads.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "file", "editable": true, "editor": file5669, "filter": { "type": "string" }, "header": "Fail", "sortable": true, "tooltip": "(uploads.AllUploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type5670, "filter": { "type": "string" }, "header": "Upload Type", "renderer": Lino.fk_renderer('typeHidden','Lino.uploads.UploadTypes.detail'), "sortable": false, "tooltip": "(uploads.AllUploads.type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5671, "filter": { "type": "string" }, "header": "Uploaded by", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(uploads.AllUploads.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(uploads.AllUploads.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "description", "editable": true, "editor": description5673, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": true, "tooltip": "(uploads.AllUploads.description) A short description entered manually by the user.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5674, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.AllUploads.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mimetype", "editable": false, "filter": { "type": "string" }, "header": "MIME type", "hidden": true, "sortable": true, "tooltip": "(uploads.AllUploads.mimetype) The Media type\nof the file.  See also this thread\nabout length of MIME type field.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "owner_type", "editable": true, "editor": owner_type5676, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(uploads.AllUploads.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_id", "editable": true, "editor": owner_id5677, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "upload_area", "editable": true, "editor": upload_area5678, "filter": { "type": "string" }, "header": "Upload Area", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "description_link", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.description_link) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.AllUploads.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.AllUploads.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.AllUploads.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AllUploads.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AllUploads.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.AllUploads.insertPanel = Ext.extend(Lino.uploads.Uploads.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/AllUploads",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.AllUploads.detail;
    this.ls_insert_handler = Lino.uploads.AllUploads.insert;
    Lino.uploads.AllUploads.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.AllUploads.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.AllUploads.insertPanel(p);
});
Lino.uploads.AllUploads.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AllUploads.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AllUploads.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.AllUploads.detailPanel = Ext.extend(Lino.uploads.Uploads.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/AllUploads",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.AllUploads.detail;
    this.ls_insert_handler = Lino.uploads.AllUploads.insert;
    Lino.uploads.AllUploads.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.AllUploads.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.AllUploads.detailPanel(p);
});
Lino.uploads.AllUploads.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AllUploads.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.uploads.Uploads.ParamsPanel({});
  return new Lino.uploads.AllUploads.GridPanel(p);
});
Lino.uploads.AllUploads.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AllUploads", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class uploads.MyUploads
Lino.uploads.MyUploads.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/MyUploads",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/MyUploads','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/MyUploads','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Minu Uploads",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "file" }, { "name": "description" }, { "name": "user" }, 'userHidden', { "name": "owner" }, { "name": "id", "type": "int" }, { "name": "mimetype" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "upload_area" }, 'upload_areaHidden', { "name": "type" }, 'typeHidden', { "name": "description_link" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 62,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.MyUploads.detail;
    this.ls_insert_handler = Lino.uploads.MyUploads.insert;
    var ww = this.containing_window;
    var file5685 = Lino.file_field_handler(this,{ "maxLength": 100, "selectOnFocus": true });
    var description5686 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user5687 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/MyUploads/user" }) }) });
    var owner_disp5688 = new Ext.form.DisplayField({ "disabled": true });
    var id5689 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mimetype5690 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": 255 });
    var owner_type5691 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/MyUploads/owner_type" }) }) });
    var owner_id5692 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/MyUploads/owner_id" }) }) });
    var upload_area5693 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var type5694 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Upload Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/MyUploads/type" }) }) });
    var description_link_disp5695 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5696 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5697 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5698 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5699 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id5692.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      type5694.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type5691.on('change',Lino.chooser_handler(owner_id5692,'owner_type'));
      upload_area5693.on('change',Lino.chooser_handler(type5694,'upload_area'));
      Lino.uploads.MyUploads.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "file", "editable": true, "editor": file5685, "filter": { "type": "string" }, "header": "Fail", "sortable": true, "tooltip": "(uploads.MyUploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "description", "editable": true, "editor": description5686, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": true, "tooltip": "(uploads.MyUploads.description) A short description entered manually by the user.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5687, "filter": { "type": "string" }, "header": "Uploaded by", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(uploads.MyUploads.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(uploads.MyUploads.owner) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5689, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.MyUploads.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "mimetype", "editable": false, "filter": { "type": "string" }, "header": "MIME type", "hidden": true, "sortable": true, "tooltip": "(uploads.MyUploads.mimetype) The Media type\nof the file.  See also this thread\nabout length of MIME type field.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type5691, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(uploads.MyUploads.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id5692, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "upload_area", "editable": true, "editor": upload_area5693, "filter": { "type": "string" }, "header": "Upload Area", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "type", "editable": true, "editor": type5694, "filter": { "type": "string" }, "header": "Upload Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.uploads.UploadTypes.detail'), "sortable": false, "tooltip": "(uploads.MyUploads.type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "description_link", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.description_link) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.MyUploads.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.MyUploads.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.MyUploads.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.MyUploads.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.MyUploads.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.MyUploads.insertPanel = Ext.extend(Lino.uploads.Uploads.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/MyUploads",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.MyUploads.detail;
    this.ls_insert_handler = Lino.uploads.MyUploads.insert;
    Lino.uploads.MyUploads.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.MyUploads.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.MyUploads.insertPanel(p);
});
Lino.uploads.MyUploads.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.MyUploads.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.MyUploads.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.MyUploads.detailPanel = Ext.extend(Lino.uploads.Uploads.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/MyUploads",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.MyUploads.detail;
    this.ls_insert_handler = Lino.uploads.MyUploads.insert;
    Lino.uploads.MyUploads.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.MyUploads.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.MyUploads.detailPanel(p);
});
Lino.uploads.MyUploads.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.MyUploads.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.uploads.Uploads.ParamsPanel({});
  return new Lino.uploads.MyUploads.GridPanel(p);
});
Lino.uploads.MyUploads.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/MyUploads", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class uploads.AreaUploads
Lino.uploads.AreaUploads.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/AreaUploads",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/AreaUploads','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/AreaUploads','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Uploads",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "file" }, { "name": "type" }, 'typeHidden', { "name": "user" }, 'userHidden', { "name": "owner" }, { "name": "description" }, { "name": "id", "type": "int" }, { "name": "mimetype" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "upload_area" }, 'upload_areaHidden', { "name": "description_link" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 62,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.AreaUploads.detail;
    this.ls_insert_handler = Lino.uploads.AreaUploads.insert;
    var ww = this.containing_window;
    var file5701 = Lino.file_field_handler(this,{ "maxLength": 100, "selectOnFocus": true });
    var type5702 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Upload Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AreaUploads/type" }) }) });
    var user5703 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AreaUploads/user" }) }) });
    var owner_disp5704 = new Ext.form.DisplayField({ "disabled": true });
    var description5705 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5706 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mimetype5707 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": 255 });
    var owner_type5708 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AreaUploads/owner_type" }) }) });
    var owner_id5709 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/AreaUploads/owner_id" }) }) });
    var upload_area5710 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var description_link_disp5711 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5712 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5713 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5714 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5715 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      type5702.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
      owner_id5709.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      upload_area5710.on('change',Lino.chooser_handler(type5702,'upload_area'));
      owner_type5708.on('change',Lino.chooser_handler(owner_id5709,'owner_type'));
      Lino.uploads.AreaUploads.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "file", "editable": true, "editor": file5701, "filter": { "type": "string" }, "header": "Fail", "sortable": true, "tooltip": "(uploads.AreaUploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type5702, "filter": { "type": "string" }, "header": "Upload Type", "renderer": Lino.fk_renderer('typeHidden','Lino.uploads.UploadTypes.detail'), "sortable": false, "tooltip": "(uploads.AreaUploads.type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5703, "filter": { "type": "string" }, "header": "Uploaded by", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(uploads.AreaUploads.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(uploads.AreaUploads.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "description", "editable": true, "editor": description5705, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": true, "tooltip": "(uploads.AreaUploads.description) A short description entered manually by the user.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id5706, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.AreaUploads.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mimetype", "editable": false, "filter": { "type": "string" }, "header": "MIME type", "hidden": true, "sortable": true, "tooltip": "(uploads.AreaUploads.mimetype) The Media type\nof the file.  See also this thread\nabout length of MIME type field.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "owner_type", "editable": true, "editor": owner_type5708, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(uploads.AreaUploads.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_id", "editable": true, "editor": owner_id5709, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "upload_area", "editable": true, "editor": upload_area5710, "filter": { "type": "string" }, "header": "Upload Area", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "description_link", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.description_link) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.AreaUploads.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.AreaUploads.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.AreaUploads.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AreaUploads.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AreaUploads.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.AreaUploads.insertPanel = Ext.extend(Lino.uploads.Uploads.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/AreaUploads",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.AreaUploads.detail;
    this.ls_insert_handler = Lino.uploads.AreaUploads.insert;
    Lino.uploads.AreaUploads.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.AreaUploads.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.AreaUploads.insertPanel(p);
});
Lino.uploads.AreaUploads.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AreaUploads.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AreaUploads.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.AreaUploads.detailPanel = Ext.extend(Lino.uploads.Uploads.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/AreaUploads",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.AreaUploads.detail;
    this.ls_insert_handler = Lino.uploads.AreaUploads.insert;
    Lino.uploads.AreaUploads.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.AreaUploads.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.AreaUploads.detailPanel(p);
});
Lino.uploads.AreaUploads.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.AreaUploads.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.uploads.Uploads.ParamsPanel({});
  return new Lino.uploads.AreaUploads.GridPanel(p);
});
Lino.uploads.AreaUploads.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/AreaUploads", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.Recipients
Lino.outbox.Recipients.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/Recipients",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/Recipients','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/Recipients','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Recipients",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 14,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "mail" }, 'mailHidden', { "name": "partner" }, 'partnerHidden', { "name": "type" }, 'typeHidden', { "name": "address" }, { "name": "name" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 64,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5717 = new Ext.form.NumberField({ "selectOnFocus": true });
    var mail5718 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Outgoing Mail...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Recipients/mail" }) }) });
    var partner5719 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Recipients/partner" }) }) });
    var type5720 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.outbox.RecipientTypes });
    var address5721 = new Ext.form.TextField({ "maxLength": 254, "selectOnFocus": true });
    var name5722 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var mobile_item_disp5723 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5724 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5725 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5726 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5717, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(outbox.Recipients.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "mail", "editable": true, "editor": mail5718, "filter": { "type": "string" }, "header": "Outgoing Mail", "renderer": Lino.fk_renderer('mailHidden','Lino.outbox.Mails.detail'), "sortable": false, "tooltip": "(outbox.Recipients.mail) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "partner", "editable": true, "editor": partner5719, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(outbox.Recipients.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "type", "editable": true, "editor": type5720, "filter": { "type": "string" }, "header": "Recipient Type", "sortable": false, "tooltip": "(outbox.Recipients.type) ", "width": Lino.chars2width(8) }, { "colIndex": 4, "dataIndex": "address", "editable": true, "editor": address5721, "filter": { "type": "string" }, "header": "Aadres", "sortable": true, "tooltip": "(outbox.Recipients.address) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "name", "editable": true, "editor": name5722, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(outbox.Recipients.name) ", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.Recipients.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.Recipients.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.Recipients.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.Recipients.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.outbox.Recipients.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.Recipients.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Recipients", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Recipients.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Recipients", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Recipients.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Recipients", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Recipients.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Recipients", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Recipients.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Recipients", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Recipients.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Recipients", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Recipients.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.Recipients.GridPanel(p);
});

// js_render_GridPanel_class outbox.Mails
Lino.outbox.Mails.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/Mails",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/Mails','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/Mails','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  cell_edit : true,
  title : "Outgoing Mails",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 18,
  ls_store_fields : [ { "name": "sent" }, { "name": "recipients" }, { "name": "subject" }, { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "dateFormat": "d.m.Y", "name": "date", "type": "date" }, { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "body" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 63,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.Mails.detail;
    this.ls_insert_handler = Lino.outbox.Mails.insert;
    var ww = this.containing_window;
    var sent5728 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var recipients_htmlbox5729 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "recipients", "title": "Recipients", "value": "<br/>" });
    var subject5730 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5731 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var user5732 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Mails/user" }) }) });
    var owner_type5733 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Mails/owner_type" }) }) });
    var owner_id5734 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Mails/owner_id" }) }) });
    var date5735 = new Lino.DateField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var owner_disp5736 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp5737 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5738 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5739 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5740 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var body5741 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    this.before_row_edit = function(record) {
      recipients_htmlbox5729.refresh();
      owner_id5734.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body5741.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type5733.on('change',Lino.chooser_handler(owner_id5734,'owner_type'));
      Lino.outbox.Mails.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(outbox.Mails.sent) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "recipients", "editable": false, "header": "Recipients", "sortable": false, "tooltip": "(outbox.Mails.recipients) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "subject", "editable": true, "editor": subject5730, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(outbox.Mails.subject) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id5731, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(outbox.Mails.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "user", "editable": true, "editor": user5732, "filter": { "type": "string" }, "header": "Sender", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(outbox.Mails.user) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type5733, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(outbox.Mails.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id5734, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "date", "editable": true, "editor": date5735, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Kuup\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(outbox.Mails.date) \n        The official date to be printed on the document.\n        ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "body", "editable": true, "editor": body5741, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(outbox.Mails.body) ", "width": Lino.chars2width(61) } ];
    Lino.outbox.Mails.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.Mails.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.Mails.insertPanel = Ext.extend(Lino.outbox.Mails.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/outbox/Mails",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.Mails.detail;
    this.ls_insert_handler = Lino.outbox.Mails.insert;
    Lino.outbox.Mails.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.Mails.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.outbox.Mails.insertPanel(p);
});
Lino.outbox.Mails.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.Mails.detailPanel = Ext.extend(Lino.outbox.Mails.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  ls_url: "/outbox/Mails",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.Mails.detail;
    this.ls_insert_handler = Lino.outbox.Mails.insert;
    Lino.outbox.Mails.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.Mails.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.Mails.detailPanel(p);
});
Lino.outbox.Mails.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.outbox.Mails.ParamsPanel({});
  return new Lino.outbox.Mails.GridPanel(p);
});
Lino.outbox.Mails.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Mails.send_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Mails", "GET", pk, "send_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.Attachments
Lino.outbox.Attachments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/Attachments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/Attachments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/Attachments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Attachments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "mail" }, 'mailHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 65,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5743 = new Ext.form.NumberField({ "selectOnFocus": true });
    var owner_type5744 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Attachments/owner_type" }) }) });
    var owner_id5745 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Attachments/owner_id" }) }) });
    var mail5746 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Outgoing Mail...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/Attachments/mail" }) }) });
    var owner_disp5747 = new Ext.form.DisplayField({ "disabled": true });
    var mobile_item_disp5748 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5749 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5750 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5751 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id5745.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type5744.on('change',Lino.chooser_handler(owner_id5745,'owner_type'));
      Lino.outbox.Attachments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5743, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(outbox.Attachments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "owner_type", "editable": true, "editor": owner_type5744, "filter": { "type": "string" }, "header": "Controlled by (type)", "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(outbox.Attachments.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "owner_id", "editable": true, "editor": owner_id5745, "filter": { "type": "string" }, "header": "Controlled by (object)", "sortable": false, "tooltip": "(outbox.Attachments.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "mail", "editable": true, "editor": mail5746, "filter": { "type": "string" }, "header": "Outgoing Mail", "renderer": Lino.fk_renderer('mailHidden','Lino.outbox.Mails.detail'), "sortable": false, "tooltip": "(outbox.Attachments.mail) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(outbox.Attachments.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.Attachments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.Attachments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.Attachments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.Attachments.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.outbox.Attachments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.Attachments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Attachments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Attachments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Attachments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Attachments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Attachments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Attachments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Attachments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Attachments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Attachments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Attachments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/Attachments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.Attachments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.Attachments.GridPanel(p);
});

// js_render_GridPanel_class tinymce.TextFieldTemplates
Lino.tinymce.TextFieldTemplates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tinymce/TextFieldTemplates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tinymce/TextFieldTemplates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tinymce/TextFieldTemplates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Text Field Templates",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "name" }, { "name": "description" }, { "name": "text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 66,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tinymce.TextFieldTemplates.detail;
    this.ls_insert_handler = Lino.tinymce.TextFieldTemplates.insert;
    var ww = this.containing_window;
    var id5753 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user5754 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tinymce/TextFieldTemplates/user" }) }) });
    var name5755 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var description5756 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var text5757 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Template Text" });
    var mobile_item_disp5758 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5759 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5760 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5761 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      text5757.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5753, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tinymce.TextFieldTemplates.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user5754, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "name", "editable": true, "editor": name5755, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(tinymce.TextFieldTemplates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "description", "editable": true, "editor": description5756, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.description) ", "width": Lino.chars2width(61) }, { "colIndex": 4, "dataIndex": "text", "editable": true, "editor": text5757, "filter": { "type": "string" }, "header": "Template Text", "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.text) ", "width": Lino.chars2width(61) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tinymce.TextFieldTemplates.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.tinymce.TextFieldTemplates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tinymce.TextFieldTemplates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.TextFieldTemplates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.TextFieldTemplates.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tinymce.TextFieldTemplates.insertPanel = Ext.extend(Lino.tinymce.TextFieldTemplates.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tinymce/TextFieldTemplates",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tinymce.TextFieldTemplates.detail;
    this.ls_insert_handler = Lino.tinymce.TextFieldTemplates.insert;
    Lino.tinymce.TextFieldTemplates.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tinymce.TextFieldTemplates.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tinymce.TextFieldTemplates.insertPanel(p);
});
Lino.tinymce.TextFieldTemplates.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.TextFieldTemplates.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.TextFieldTemplates.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tinymce.TextFieldTemplates.detailPanel = Ext.extend(Lino.tinymce.TextFieldTemplates.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tinymce/TextFieldTemplates",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tinymce.TextFieldTemplates.detail;
    this.ls_insert_handler = Lino.tinymce.TextFieldTemplates.insert;
    Lino.tinymce.TextFieldTemplates.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tinymce.TextFieldTemplates.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tinymce.TextFieldTemplates.detailPanel(p);
});
Lino.tinymce.TextFieldTemplates.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.TextFieldTemplates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tinymce.TextFieldTemplates.ParamsPanel({});
  return new Lino.tinymce.TextFieldTemplates.GridPanel(p);
});
Lino.tinymce.TextFieldTemplates.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/TextFieldTemplates", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tinymce.MyTextFieldTemplates
Lino.tinymce.MyTextFieldTemplates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tinymce/MyTextFieldTemplates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tinymce/MyTextFieldTemplates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tinymce/MyTextFieldTemplates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Minu Text Field Templates",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "name" }, { "name": "description" }, { "name": "text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 66,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tinymce.MyTextFieldTemplates.detail;
    this.ls_insert_handler = Lino.tinymce.MyTextFieldTemplates.insert;
    var ww = this.containing_window;
    var id5763 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user5764 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tinymce/MyTextFieldTemplates/user" }) }) });
    var name5765 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var description5766 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var text5767 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Template Text" });
    var mobile_item_disp5768 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5769 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5770 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5771 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      text5767.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5763, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tinymce.MyTextFieldTemplates.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user5764, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "name", "editable": true, "editor": name5765, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(tinymce.MyTextFieldTemplates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "description", "editable": true, "editor": description5766, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.description) ", "width": Lino.chars2width(61) }, { "colIndex": 4, "dataIndex": "text", "editable": true, "editor": text5767, "filter": { "type": "string" }, "header": "Template Text", "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.text) ", "width": Lino.chars2width(61) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tinymce.MyTextFieldTemplates.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.tinymce.MyTextFieldTemplates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tinymce.MyTextFieldTemplates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.MyTextFieldTemplates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.MyTextFieldTemplates.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tinymce.MyTextFieldTemplates.insertPanel = Ext.extend(Lino.tinymce.TextFieldTemplates.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tinymce/MyTextFieldTemplates",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tinymce.MyTextFieldTemplates.detail;
    this.ls_insert_handler = Lino.tinymce.MyTextFieldTemplates.insert;
    Lino.tinymce.MyTextFieldTemplates.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tinymce.MyTextFieldTemplates.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tinymce.MyTextFieldTemplates.insertPanel(p);
});
Lino.tinymce.MyTextFieldTemplates.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.MyTextFieldTemplates.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.MyTextFieldTemplates.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tinymce.MyTextFieldTemplates.detailPanel = Ext.extend(Lino.tinymce.TextFieldTemplates.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tinymce/MyTextFieldTemplates",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tinymce.MyTextFieldTemplates.detail;
    this.ls_insert_handler = Lino.tinymce.MyTextFieldTemplates.insert;
    Lino.tinymce.MyTextFieldTemplates.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tinymce.MyTextFieldTemplates.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tinymce.MyTextFieldTemplates.detailPanel(p);
});
Lino.tinymce.MyTextFieldTemplates.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tinymce.MyTextFieldTemplates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tinymce.TextFieldTemplates.ParamsPanel({});
  return new Lino.tinymce.MyTextFieldTemplates.GridPanel(p);
});
Lino.tinymce.MyTextFieldTemplates.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tinymce/MyTextFieldTemplates", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class dashboard.Widgets
Lino.dashboard.Widgets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/dashboard/Widgets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/dashboard/Widgets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/dashboard/Widgets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Widgets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "user" }, 'userHidden', { "name": "item_name" }, { "name": "visible", "type": "boolean" }, { "name": "title" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 67,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5773 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno5774 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user5775 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/Widgets/user" }) }) });
    var item_name5776 = new Lino.SimpleRemoteComboFieldElement({ "allowBlank": false, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/Widgets/item_name" }) }) });
    var visible5777 = new Ext.form.Checkbox({ "checked": true, "selectOnFocus": true });
    var title_disp5778 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5779 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5780 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5781 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5782 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp5783 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      item_name5776.setContextValue('user', record ? record.data['userHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      user5775.on('change',Lino.chooser_handler(item_name5776,'user'));
      Lino.dashboard.Widgets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5773, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(dashboard.Widgets.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno5774, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(dashboard.Widgets.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user5775, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(dashboard.Widgets.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "item_name", "editable": true, "editor": item_name5776, "filter": { "type": "string" }, "header": "Resource", "sortable": false, "tooltip": "(dashboard.Widgets.item_name) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "visible", "editable": true, "filter": { "type": "boolean" }, "header": "Visible", "sortable": false, "tooltip": "(dashboard.Widgets.visible) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 5, "dataIndex": "title", "editable": false, "header": "Label", "hidden": true, "sortable": false, "tooltip": "(dashboard.Widgets.title) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(dashboard.Widgets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(dashboard.Widgets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(dashboard.Widgets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(dashboard.Widgets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(dashboard.Widgets.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.dashboard.Widgets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.dashboard.Widgets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.dashboard.Widgets.ParamsPanel({});
  return new Lino.dashboard.Widgets.GridPanel(p);
});
Lino.dashboard.Widgets.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.Widgets.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/Widgets", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class dashboard.AllWidgets
Lino.dashboard.AllWidgets.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/dashboard/AllWidgets",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/dashboard/AllWidgets','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/dashboard/AllWidgets','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "All dashboard widgets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "seqno", "type": "int", "useNull": true }, { "name": "move_buttons" }, { "name": "title" }, { "name": "visible", "type": "boolean" }, { "name": "item_name" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 67,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id5785 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user5786 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/AllWidgets/user" }) }) });
    var seqno5787 = new Ext.form.NumberField({ "selectOnFocus": true });
    var move_buttons_disp5788 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var title_disp5789 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var visible5790 = new Ext.form.Checkbox({ "checked": true, "selectOnFocus": true });
    var item_name5791 = new Lino.SimpleRemoteComboFieldElement({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/AllWidgets/item_name" }) }) });
    var mobile_item_disp5792 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5793 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5794 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5795 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      item_name5791.setContextValue('user', record ? record.data['userHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      user5786.on('change',Lino.chooser_handler(item_name5791,'user'));
      Lino.dashboard.AllWidgets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5785, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(dashboard.AllWidgets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user5786, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(dashboard.AllWidgets.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "seqno", "editable": true, "editor": seqno5787, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(dashboard.AllWidgets.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "move_buttons", "editable": false, "header": "Move", "sortable": false, "tooltip": "(dashboard.AllWidgets.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "title", "editable": false, "header": "Label", "sortable": false, "tooltip": "(dashboard.AllWidgets.title) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "visible", "editable": true, "filter": { "type": "boolean" }, "header": "Visible", "sortable": false, "tooltip": "(dashboard.AllWidgets.visible) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 6, "dataIndex": "item_name", "editable": true, "editor": item_name5791, "filter": { "type": "string" }, "header": "Resource", "hidden": true, "sortable": false, "tooltip": "(dashboard.AllWidgets.item_name) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(dashboard.AllWidgets.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(dashboard.AllWidgets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(dashboard.AllWidgets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(dashboard.AllWidgets.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.dashboard.AllWidgets.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.dashboard.AllWidgets.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.dashboard.Widgets.ParamsPanel({});
  return new Lino.dashboard.AllWidgets.GridPanel(p);
});
Lino.dashboard.AllWidgets.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.AllWidgets.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/AllWidgets", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.OtherUsers
Lino.users.OtherUsers.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/users/OtherUsers",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/OtherUsers','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/OtherUsers','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Users",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 62,
  ls_store_fields : [ { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "first_name" }, { "name": "last_name" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "middle_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "created" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_actions" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.OtherUsers.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    var ww = this.containing_window;
    var username5797 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile5798 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var first_name5799 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name5800 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id5801 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email5802 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language5803 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url5804 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone5805 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm5806 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax5807 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country5808 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/OtherUsers/country" }) }) });
    var city5809 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/OtherUsers/city" }) }) });
    var zip_code5810 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region5811 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/OtherUsers/region" }) }) });
    var addr15812 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix5813 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street5814 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no5815 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box5816 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr25817 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name5818 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks5819 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title5820 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name5821 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender5822 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date5823 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private5824 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified5825 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created5826 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password5827 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login5828 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone5829 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/OtherUsers/timezone" }) }) });
    var initials5830 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode5831 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code5832 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state5833 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class5834 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type5835 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/OtherUsers/event_type" }) }) });
    var open_session_on_new_ticket5836 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself5837 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode5838 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox5839 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp5840 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5841 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5842 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5843 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5844 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5845 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp5846 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp5847 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp5848 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      remarks5819.refresh();
      about_me_htmlbox5839.refresh();
    };
    this.onRender = function(ct, position) {
      country5808.on('change',Lino.chooser_handler(city5809,'country'));
      region5811.on('change',Lino.chooser_handler(city5809,'region'));
      country5808.on('change',Lino.chooser_handler(region5811,'country'));
      Lino.users.OtherUsers.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username5797, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.OtherUsers.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile5798, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.OtherUsers.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 2, "dataIndex": "first_name", "editable": true, "editor": first_name5799, "filter": { "type": "string" }, "header": "Eesnimi", "sortable": true, "tooltip": "(users.OtherUsers.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "last_name", "editable": true, "editor": last_name5800, "filter": { "type": "string" }, "header": "Perenimi", "sortable": true, "tooltip": "(users.OtherUsers.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id5801, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "email", "editable": true, "editor": email5802, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language5803, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url5804, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone5805, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "gsm", "editable": true, "editor": gsm5806, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "fax", "editable": true, "editor": fax5807, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country5808, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(users.OtherUsers.country) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "city", "editable": true, "editor": city5809, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.OtherUsers.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code5810, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 14, "dataIndex": "region", "editable": true, "editor": region5811, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.OtherUsers.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr15812, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix5813, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "street", "editable": true, "editor": street5814, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "street_no", "editable": true, "editor": street_no5815, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "street_box", "editable": true, "editor": street_box5816, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "addr2", "editable": true, "editor": addr25817, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "name", "editable": true, "editor": name5818, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "remarks", "editable": true, "editor": remarks5819, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "title", "editable": true, "editor": title5820, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "middle_name", "editable": true, "editor": middle_name5821, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "gender", "editable": true, "editor": gender5822, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 26, "dataIndex": "birth_date", "editable": true, "editor": birth_date5823, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 27, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 29, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 30, "dataIndex": "password", "editable": true, "editor": password5827, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.password) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "last_login", "editable": true, "editor": last_login5828, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 32, "dataIndex": "timezone", "editable": true, "editor": timezone5829, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 33, "dataIndex": "initials", "editable": true, "editor": initials5830, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 35, "dataIndex": "verification_code", "editable": true, "editor": verification_code5832, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(users.OtherUsers.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 36, "dataIndex": "user_state", "editable": true, "editor": user_state5833, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 37, "dataIndex": "access_class", "editable": true, "editor": access_class5834, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 38, "dataIndex": "event_type", "editable": true, "editor": event_type5835, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(users.OtherUsers.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 39, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 40, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5838, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 42, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 44, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 45, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(users.OtherUsers.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.users.OtherUsers.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.OtherUsers.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.OtherUsers.detailPanel = Ext.extend(Lino.users.OtherUsers.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/OtherUsers",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.OtherUsers.detail;
    this.ls_insert_handler = Lino.users.Users.insert;
    Lino.users.OtherUsers.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.OtherUsers.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.OtherUsers.detailPanel(p);
});
Lino.users.OtherUsers.grid = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.users.OtherUsers.GridPanel(p);
});
Lino.users.OtherUsers.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.OtherUsers.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/OtherUsers", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.Register
Lino.users.Register.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/Register",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/Register','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/Register','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Users",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 63,
  ls_store_fields : [ { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "first_name" }, { "name": "last_name" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "middle_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "created" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.Register.detail;
    this.ls_insert_handler = Lino.users.Register.insert;
    var ww = this.containing_window;
    var username3040 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile3041 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var first_name3042 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name3043 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id3044 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email3045 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language3046 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url3047 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone3048 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm3049 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax3050 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country3051 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/country" }) }) });
    var city3052 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/city" }) }) });
    var zip_code3053 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region3054 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/region" }) }) });
    var addr13055 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix3056 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street3057 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no3058 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box3059 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr23060 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name3061 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks3062 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title3063 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name3064 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender3065 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date3066 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private3067 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified3068 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3069 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password3070 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login3071 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone3072 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/timezone" }) }) });
    var initials3073 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode3074 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code3075 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state3076 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class3077 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type3078 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/event_type" }) }) });
    var open_session_on_new_ticket3079 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself3080 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode3081 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox3082 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp3083 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3084 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3085 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3086 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3087 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3088 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp3089 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp3090 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp3091 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city3052.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city3052.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region3054.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks3062.refresh();
      timezone3072.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox3082.refresh();
    };
    this.onRender = function(ct, position) {
      country3051.on('change',Lino.chooser_handler(city3052,'country'));
      region3054.on('change',Lino.chooser_handler(city3052,'region'));
      country3051.on('change',Lino.chooser_handler(region3054,'country'));
      Lino.users.Register.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username3040, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.Register.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile3041, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.Register.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 2, "dataIndex": "first_name", "editable": true, "editor": first_name3042, "filter": { "type": "string" }, "header": "Eesnimi", "sortable": true, "tooltip": "(users.Register.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "last_name", "editable": true, "editor": last_name3043, "filter": { "type": "string" }, "header": "Perenimi", "sortable": true, "tooltip": "(users.Register.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id3044, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(users.Register.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "email", "editable": true, "editor": email3045, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(users.Register.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language3046, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(users.Register.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url3047, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.Register.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone3048, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(users.Register.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "gsm", "editable": true, "editor": gsm3049, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(users.Register.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "fax", "editable": true, "editor": fax3050, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.Register.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country3051, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(users.Register.country) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "city", "editable": true, "editor": city3052, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.Register.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code3053, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(users.Register.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 14, "dataIndex": "region", "editable": true, "editor": region3054, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.Register.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr13055, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(users.Register.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix3056, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(users.Register.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "street", "editable": true, "editor": street3057, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(users.Register.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "street_no", "editable": true, "editor": street_no3058, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(users.Register.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "street_box", "editable": true, "editor": street_box3059, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(users.Register.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "addr2", "editable": true, "editor": addr23060, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(users.Register.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "name", "editable": true, "editor": name3061, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(users.Register.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "remarks", "editable": true, "editor": remarks3062, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(users.Register.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "title", "editable": true, "editor": title3063, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(users.Register.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "middle_name", "editable": true, "editor": middle_name3064, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(users.Register.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "gender", "editable": true, "editor": gender3065, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(users.Register.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 26, "dataIndex": "birth_date", "editable": true, "editor": birth_date3066, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(users.Register.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 27, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(users.Register.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.Register.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 29, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(users.Register.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 30, "dataIndex": "password", "editable": true, "editor": password3070, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.Register.password) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "last_login", "editable": true, "editor": last_login3071, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.Register.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 32, "dataIndex": "timezone", "editable": true, "editor": timezone3072, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.Register.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 33, "dataIndex": "initials", "editable": true, "editor": initials3073, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.Register.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(users.Register.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 35, "dataIndex": "verification_code", "editable": true, "editor": verification_code3075, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(users.Register.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 36, "dataIndex": "user_state", "editable": true, "editor": user_state3076, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(users.Register.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 37, "dataIndex": "access_class", "editable": true, "editor": access_class3077, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(users.Register.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 38, "dataIndex": "event_type", "editable": true, "editor": event_type3078, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(users.Register.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 39, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(users.Register.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 40, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(users.Register.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode3081, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.Register.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 42, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.Register.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.Register.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 44, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Register.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 45, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Register.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.Register.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.Register.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.Register.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.Register.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.Register.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(users.Register.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.users.Register.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Register.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.Register.insertPanel = Ext.extend(Lino.users.Register.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/users/Register",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.Register.detail;
    this.ls_insert_handler = Lino.users.Register.insert;
    Lino.users.Register.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Register.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.Register.insertPanel(p);
});
Lino.users.Register.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.Register.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/Register",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.Register.detail;
    this.ls_insert_handler = Lino.users.Register.insert;
    Lino.users.Register.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.Register.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.Register.detailPanel(p);
});
Lino.users.Register.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.users.Register.GridPanel(p);
});
Lino.users.Register.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.NewUsers
Lino.users.NewUsers.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/NewUsers",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/NewUsers','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/NewUsers','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Uued kasutajataotlused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 63,
  ls_store_fields : [ { "name": "created" }, { "name": "first_name" }, { "name": "last_name" }, { "name": "username" }, { "name": "profile" }, 'profileHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "middle_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.NewUsers.detail;
    this.ls_insert_handler = Lino.users.NewUsers.insert;
    var ww = this.containing_window;
    var created5850 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var first_name5851 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name5852 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var username5853 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile5854 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var workflow_buttons_disp5855 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5856 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email5857 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language5858 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url5859 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone5860 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm5861 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax5862 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country5863 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/NewUsers/country" }) }) });
    var city5864 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/NewUsers/city" }) }) });
    var zip_code5865 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region5866 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/NewUsers/region" }) }) });
    var addr15867 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix5868 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street5869 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no5870 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box5871 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr25872 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name5873 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks5874 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title5875 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name5876 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender5877 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date5878 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private5879 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified5880 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password5881 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login5882 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone5883 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/NewUsers/timezone" }) }) });
    var initials5884 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode5885 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code5886 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state5887 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class5888 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type5889 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/NewUsers/event_type" }) }) });
    var open_session_on_new_ticket5890 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself5891 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode5892 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox5893 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp5894 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5895 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5896 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5897 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp5898 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp5899 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp5900 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp5901 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city5864.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city5864.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region5866.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks5874.refresh();
      timezone5883.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox5893.refresh();
    };
    this.onRender = function(ct, position) {
      country5863.on('change',Lino.chooser_handler(city5864,'country'));
      region5866.on('change',Lino.chooser_handler(city5864,'region'));
      country5863.on('change',Lino.chooser_handler(region5866,'country'));
      Lino.users.NewUsers.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(users.NewUsers.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "first_name", "editable": true, "editor": first_name5851, "filter": { "type": "string" }, "header": "Eesnimi", "sortable": true, "tooltip": "(users.NewUsers.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "last_name", "editable": true, "editor": last_name5852, "filter": { "type": "string" }, "header": "Perenimi", "sortable": true, "tooltip": "(users.NewUsers.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "username", "editable": true, "editor": username5853, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.NewUsers.username) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "profile", "editable": true, "editor": profile5854, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.NewUsers.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(users.NewUsers.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id5856, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "email", "editable": true, "editor": email5857, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "language", "editable": true, "editor": language5858, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "url", "editable": true, "editor": url5859, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.url) ", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "phone", "editable": true, "editor": phone5860, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "gsm", "editable": true, "editor": gsm5861, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 12, "dataIndex": "fax", "editable": true, "editor": fax5862, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 13, "dataIndex": "country", "editable": true, "editor": country5863, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(users.NewUsers.country) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "city", "editable": true, "editor": city5864, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.NewUsers.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "zip_code", "editable": true, "editor": zip_code5865, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 16, "dataIndex": "region", "editable": true, "editor": region5866, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(users.NewUsers.region) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "addr1", "editable": true, "editor": addr15867, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix5868, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "street", "editable": true, "editor": street5869, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 20, "dataIndex": "street_no", "editable": true, "editor": street_no5870, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 21, "dataIndex": "street_box", "editable": true, "editor": street_box5871, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 22, "dataIndex": "addr2", "editable": true, "editor": addr25872, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "name", "editable": true, "editor": name5873, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "remarks", "editable": true, "editor": remarks5874, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "title", "editable": true, "editor": title5875, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 26, "dataIndex": "middle_name", "editable": true, "editor": middle_name5876, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 27, "dataIndex": "gender", "editable": true, "editor": gender5877, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 28, "dataIndex": "birth_date", "editable": true, "editor": birth_date5878, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 29, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 30, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 31, "dataIndex": "password", "editable": true, "editor": password5881, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.password) ", "width": Lino.chars2width(22) }, { "colIndex": 32, "dataIndex": "last_login", "editable": true, "editor": last_login5882, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 33, "dataIndex": "timezone", "editable": true, "editor": timezone5883, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 34, "dataIndex": "initials", "editable": true, "editor": initials5884, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 35, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 36, "dataIndex": "verification_code", "editable": true, "editor": verification_code5886, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(users.NewUsers.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 37, "dataIndex": "user_state", "editable": true, "editor": user_state5887, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 38, "dataIndex": "access_class", "editable": true, "editor": access_class5888, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 39, "dataIndex": "event_type", "editable": true, "editor": event_type5889, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(users.NewUsers.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 40, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 42, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode5892, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 43, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 44, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 45, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(users.NewUsers.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.users.NewUsers.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.NewUsers.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.NewUsers.insertPanel = Ext.extend(Lino.users.Users.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/users/NewUsers",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.users.NewUsers.detail;
    this.ls_insert_handler = Lino.users.NewUsers.insert;
    Lino.users.NewUsers.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.users.NewUsers.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.users.NewUsers.insertPanel(p);
});
Lino.users.NewUsers.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.users.NewUsers.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/users/NewUsers",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.users.NewUsers.detail;
    this.ls_insert_handler = Lino.users.NewUsers.insert;
    Lino.users.NewUsers.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.users.NewUsers.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.NewUsers.detailPanel(p);
});
Lino.users.NewUsers.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.users.NewUsers.GridPanel(p);
});
Lino.users.NewUsers.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.NewUsers.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/NewUsers", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.Slots
Lino.courses.Slots.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/Slots",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/Slots','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/Slots','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Timetable Slots",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "start_time" }, { "name": "end_time" }, { "name": "name" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 25,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Slots.detail;
    this.ls_insert_handler = Lino.courses.Slots.insert;
    var ww = this.containing_window;
    var id5903 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno5904 = new Ext.form.NumberField({ "selectOnFocus": true });
    var start_time5905 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time5906 = new Lino.TimeField({ "selectOnFocus": true });
    var name5907 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var move_buttons_disp5908 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5909 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5910 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5911 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5912 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5903, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(courses.Slots.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno5904, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(courses.Slots.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "start_time", "editable": true, "editor": start_time5905, "header": "Algab (aeg)", "sortable": true, "tooltip": "(courses.Slots.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 3, "dataIndex": "end_time", "editable": true, "editor": end_time5906, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(courses.Slots.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 4, "dataIndex": "name", "editable": true, "editor": name5907, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(courses.Slots.name) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(courses.Slots.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Slots.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Slots.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.Slots.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.Slots.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.courses.Slots.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Slots.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Slots.insertPanel = Ext.extend(Lino.courses.Slots.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/Slots",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Slots.detail;
    this.ls_insert_handler = Lino.courses.Slots.insert;
    Lino.courses.Slots.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Slots.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Slots.insertPanel(p);
});
Lino.courses.Slots.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Slots.detailPanel = Ext.extend(Lino.courses.Slots.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/courses/Slots",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Slots.detail;
    this.ls_insert_handler = Lino.courses.Slots.insert;
    Lino.courses.Slots.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Slots.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Slots.detailPanel(p);
});
Lino.courses.Slots.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Slots.GridPanel(p);
});
Lino.courses.Slots.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Slots.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Slots", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.Topics
Lino.courses.Topics.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/Topics",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/Topics','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/Topics','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." } ],
  cell_edit : true,
  title : "Teemad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 26,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Topics.detail;
    this.ls_insert_handler = Lino.courses.Topics.insert;
    var ww = this.containing_window;
    var id5914 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name5915 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5916 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var mobile_item_disp5917 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5918 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5919 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5920 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id5914, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(courses.Topics.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5915, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.Topics.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et5916, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(courses.Topics.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Topics.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Topics.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.Topics.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.Topics.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.courses.Topics.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Topics.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Topics.insertPanel = Ext.extend(Lino.courses.Topics.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/Topics",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Topics.detail;
    this.ls_insert_handler = Lino.courses.Topics.insert;
    Lino.courses.Topics.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Topics.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Topics.insertPanel(p);
});
Lino.courses.Topics.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Topics.detailPanel = Ext.extend(Lino.courses.Topics.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." } ],
  ls_url: "/courses/Topics",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Topics.detail;
    this.ls_insert_handler = Lino.courses.Topics.insert;
    Lino.courses.Topics.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Topics.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Topics.detailPanel(p);
});
Lino.courses.Topics.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Topics.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Topics.GridPanel(p);
});
Lino.courses.Topics.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Topics", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.Lines
Lino.courses.Lines.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/Lines",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/Lines','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/Lines','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Tegevuste sarjad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 31,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "name_et" }, { "name": "topic" }, 'topicHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "guest_role" }, 'guest_roleHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "excerpt_title" }, { "name": "excerpt_title_et" }, { "name": "description" }, { "name": "description_et" }, { "name": "body_template" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 14,
  ls_grid_configs : [  ],
  content_type : 27,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Lines.detail;
    this.ls_insert_handler = Lino.courses.Lines.insert;
    var ww = this.containing_window;
    var ref5922 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name5923 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et5924 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var topic5925 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/topic" }) }) });
    var course_area5926 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.courses.CourseAreas });
    var event_type5927 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/event_type" }) }) });
    var guest_role5928 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/guest_role" }) }) });
    var every_unit5929 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every5930 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 1 });
    var id5931 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var company5932 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/company" }) }) });
    var contact_person5933 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/contact_person" }) }) });
    var contact_role5934 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/contact_role" }) }) });
    var excerpt_title5935 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var excerpt_title_et5936 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description5937 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et5938 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var body_template5939 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Lines/body_template" }) }) });
    var mobile_item_disp5940 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5941 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5942 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp5943 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person5933.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description5937.refresh();
      description_et5938.refresh();
    };
    this.onRender = function(ct, position) {
      company5932.on('change',Lino.chooser_handler(contact_person5933,'company'));
      Lino.courses.Lines.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref5922, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(courses.Lines.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5923, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.Lines.name) The designation of this activity line as seen by the user\ne.g. when selecting the line.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et5924, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(courses.Lines.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic5925, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.courses.Topics.detail'), "sortable": false, "tooltip": "(courses.Lines.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "course_area", "editable": true, "editor": course_area5926, "filter": { "type": "string" }, "header": "Layout", "sortable": false, "tooltip": "(courses.Lines.course_area) Pointer to CourseAreas.  This is used only when an\napplication defines several variants of\nEnrolmentsByPupil.", "width": Lino.chars2width(14) }, { "colIndex": 5, "dataIndex": "event_type", "editable": true, "editor": event_type5927, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(courses.Lines.event_type) The type of calendar entries to be generated. If this is empty, no calendar entries will be generated.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "guest_role", "editable": true, "editor": guest_role5928, "filter": { "type": "string" }, "header": "Manage presences as", "renderer": Lino.fk_renderer('guest_roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(courses.Lines.guest_role) The default guest role for particpants of calendar entries for activities in this series. Leave empty if you don't want any presences management.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "every_unit", "editable": true, "editor": every_unit5929, "filter": { "type": "string" }, "header": "Korduvus", "sortable": false, "tooltip": "(courses.Lines.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 8, "dataIndex": "every", "editable": true, "editor": every5930, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "sortable": true, "tooltip": "(courses.Lines.every) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 9, "dataIndex": "id", "editable": true, "editor": id5931, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.Lines.id) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "company", "editable": true, "editor": company5932, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(courses.Lines.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "contact_person", "editable": true, "editor": contact_person5933, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.Lines.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "contact_role", "editable": true, "editor": contact_role5934, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "excerpt_title", "editable": true, "editor": excerpt_title5935, "filter": { "type": "string" }, "header": "Excerpt title", "hidden": true, "sortable": true, "tooltip": "(courses.Lines.excerpt_title) The title to be used when printing an excerpt.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "excerpt_title_et", "editable": true, "editor": excerpt_title_et5936, "filter": { "type": "string" }, "header": "Excerpt title (et)", "hidden": true, "sortable": true, "tooltip": "(courses.Lines.excerpt_title_et) ", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "description", "editable": true, "editor": description5937, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.description) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "description_et", "editable": true, "editor": description_et5938, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "body_template", "editable": true, "editor": body_template5939, "filter": { "type": "string" }, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.body_template) The body template to use when printing a course of this series. Leave empty to use the site's default.", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.Lines.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.courses.Lines.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Lines.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Lines.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Lines.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Lines.insertPanel = Ext.extend(Lino.courses.Lines.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/Lines",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Lines.detail;
    this.ls_insert_handler = Lino.courses.Lines.insert;
    Lino.courses.Lines.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Lines.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(16), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(70) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Lines.insertPanel(p);
});
Lino.courses.Lines.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Lines.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Lines.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Lines.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Lines.detailPanel = Ext.extend(Lino.courses.Lines.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/courses/Lines",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Lines.detail;
    this.ls_insert_handler = Lino.courses.Lines.insert;
    Lino.courses.Lines.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Lines.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Lines.detailPanel(p);
});
Lino.courses.Lines.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Lines.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Lines.GridPanel(p);
});
Lino.courses.Lines.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Lines", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.Activities
Lino.courses.Activities.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/Activities",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/Activities','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/Activities','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "name" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "room" }, 'roomHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "ref" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Activities.detail;
    this.ls_insert_handler = Lino.courses.Activities.insert;
    var ww = this.containing_window;
    var start_date5945 = new Lino.DateField({ "selectOnFocus": true });
    var name5946 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    var line5947 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/line" }) }) });
    var teacher5948 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/teacher" }) }) });
    var room5949 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/room" }) }) });
    var workflow_buttons_disp5950 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5951 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref5952 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_time5953 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date5954 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time5955 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user5956 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/user" }) }) });
    var every_unit5957 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every5958 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday5959 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday5960 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday5961 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday5962 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday5963 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday5964 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday5965 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events5966 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date5967 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var slot5968 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Activities/slot" }) }) });
    var description5969 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et5970 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark5971 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state5972 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places5973 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var enrolments_until5974 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp5975 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments5976 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp5977 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested5978 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed5979 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox5980 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying5981 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places5982 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp5983 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp5984 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp5985 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp5986 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp5987 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp5988 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration5989 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description5969.refresh();
      description_et5970.refresh();
      remark5971.refresh();
      presences_box_htmlbox5980.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date5945, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.Activities.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5946, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.Activities.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "line", "editable": true, "editor": line5947, "filter": { "type": "string" }, "header": "Tegevuste sari", "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.Activities.line) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "teacher", "editable": true, "editor": teacher5948, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.Activities.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "room", "editable": true, "editor": room5949, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.Activities.room) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.Activities.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id5951, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "ref", "editable": true, "editor": ref5952, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time5953, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date5954, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time5955, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "user", "editable": true, "editor": user5956, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.Activities.user) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "every_unit", "editable": true, "editor": every_unit5957, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 13, "dataIndex": "every", "editable": true, "editor": every5958, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.every) ", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 20, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 21, "dataIndex": "max_events", "editable": true, "editor": max_events5966, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 22, "dataIndex": "max_date", "editable": true, "editor": max_date5967, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "slot", "editable": true, "editor": slot5968, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.Activities.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "description", "editable": true, "editor": description5969, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.description) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "description_et", "editable": true, "editor": description_et5970, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "remark", "editable": true, "editor": remark5971, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state5972, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 28, "dataIndex": "max_places", "editable": true, "editor": max_places5973, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 29, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until5974, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.Activities.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 30, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 32, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 33, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 34, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 35, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 36, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 37, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.Activities.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.Activities.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Activities.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Activities.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/Activities",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Activities.detail;
    this.ls_insert_handler = Lino.courses.Activities.insert;
    Lino.courses.Activities.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Activities.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Activities.insertPanel(p);
});
Lino.courses.Activities.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Activities.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/Activities",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Activities.detail;
    this.ls_insert_handler = Lino.courses.Activities.insert;
    Lino.courses.Activities.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Activities.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Activities.detailPanel(p);
});
Lino.courses.Activities.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.Activities.GridPanel(p);
});
Lino.courses.Activities.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Activities.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Activities", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.Courses
Lino.courses.Courses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/Courses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/Courses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/Courses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "name" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "room" }, 'roomHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "ref" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Courses.detail;
    this.ls_insert_handler = Lino.courses.Courses.insert;
    var ww = this.containing_window;
    var start_date5991 = new Lino.DateField({ "selectOnFocus": true });
    var name5992 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    var line5993 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Courses/line" }) }) });
    var teacher5994 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Courses/teacher" }) }) });
    var room5995 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Courses/room" }) }) });
    var workflow_buttons_disp5996 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id5997 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref5998 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_time5999 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6000 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6001 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6002 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Courses/user" }) }) });
    var every_unit6003 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6004 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6005 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6006 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6007 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6008 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6009 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6010 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6011 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6012 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6013 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var slot6014 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Courses/slot" }) }) });
    var description6015 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6016 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6017 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6018 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6019 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var enrolments_until6020 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6021 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments6022 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp6023 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6024 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6025 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6026 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6027 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places6028 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6029 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6030 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6031 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6032 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6033 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6034 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6035 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6015.refresh();
      description_et6016.refresh();
      remark6017.refresh();
      presences_box_htmlbox6026.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date5991, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.Courses.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name5992, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.Courses.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "line", "editable": true, "editor": line5993, "filter": { "type": "string" }, "header": "Tegevuste sari", "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.Courses.line) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "teacher", "editable": true, "editor": teacher5994, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.Courses.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "room", "editable": true, "editor": room5995, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.Courses.room) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.Courses.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id5997, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "ref", "editable": true, "editor": ref5998, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time5999, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date6000, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time6001, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "user", "editable": true, "editor": user6002, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.Courses.user) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "every_unit", "editable": true, "editor": every_unit6003, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 13, "dataIndex": "every", "editable": true, "editor": every6004, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.every) ", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 20, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 21, "dataIndex": "max_events", "editable": true, "editor": max_events6012, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 22, "dataIndex": "max_date", "editable": true, "editor": max_date6013, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "slot", "editable": true, "editor": slot6014, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.Courses.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "description", "editable": true, "editor": description6015, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.description) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "description_et", "editable": true, "editor": description_et6016, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "remark", "editable": true, "editor": remark6017, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state6018, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 28, "dataIndex": "max_places", "editable": true, "editor": max_places6019, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 29, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6020, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.Courses.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 30, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 32, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 33, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 34, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 35, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 36, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 37, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.Courses.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.Courses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Courses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Courses.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/Courses",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Courses.detail;
    this.ls_insert_handler = Lino.courses.Courses.insert;
    Lino.courses.Courses.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Courses.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Courses.insertPanel(p);
});
Lino.courses.Courses.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Courses.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/Courses",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Courses.detail;
    this.ls_insert_handler = Lino.courses.Courses.insert;
    Lino.courses.Courses.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Courses.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Courses.detailPanel(p);
});
Lino.courses.Courses.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.Courses.GridPanel(p);
});
Lino.courses.Courses.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Courses.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Courses", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.AllActivities
Lino.courses.AllActivities.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/AllActivities",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/AllActivities','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/AllActivities','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" }, { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" } ], "menu_item_text": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "line" }, 'lineHidden', { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "teacher" }, 'teacherHidden', { "name": "user" }, 'userHidden', { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.AllActivities.detail;
    this.ls_insert_handler = Lino.courses.AllActivities.insert;
    var ww = this.containing_window;
    var line6037 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/AllActivities/line" }) }) });
    var start_date6038 = new Lino.DateField({ "selectOnFocus": true });
    var teacher6039 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/AllActivities/teacher" }) }) });
    var user6040 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/AllActivities/user" }) }) });
    var weekdays_text_disp6041 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var times_text_disp6042 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "line", "editable": true, "editor": line6037, "filter": { "type": "string" }, "header": "Tegevuste sari", "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.AllActivities.line) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "start_date", "editable": true, "editor": start_date6038, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.AllActivities.start_date) ", "width": Lino.chars2width(9), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "teacher", "editable": true, "editor": teacher6039, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.AllActivities.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "user", "editable": true, "editor": user6040, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.AllActivities.user) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(courses.AllActivities.weekdays_text) ", "width": Lino.chars2width(11) }, { "colIndex": 5, "dataIndex": "times_text", "editable": false, "header": "Times", "sortable": false, "tooltip": "(courses.AllActivities.times_text) ", "width": Lino.chars2width(11) } ];
    Lino.courses.AllActivities.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.AllActivities.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.AllActivities.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/AllActivities",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.AllActivities.detail;
    this.ls_insert_handler = Lino.courses.AllActivities.insert;
    Lino.courses.AllActivities.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.AllActivities.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.AllActivities.insertPanel(p);
});
Lino.courses.AllActivities.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.AllActivities.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" }, { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" } ], "menu_item_text": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/AllActivities",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.AllActivities.detail;
    this.ls_insert_handler = Lino.courses.AllActivities.insert;
    Lino.courses.AllActivities.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.AllActivities.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.AllActivities.detailPanel(p);
});
Lino.courses.AllActivities.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.AllActivities.GridPanel(p);
});
Lino.courses.AllActivities.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllActivities.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllActivities", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.MyActivities
Lino.courses.MyActivities.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/MyActivities",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/MyActivities','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/MyActivities','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" }, { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" } ], "menu_item_text": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Minu Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "room" }, 'roomHidden', { "name": "name" }, { "name": "line" }, 'lineHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "ref" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "teacher" }, 'teacherHidden', { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.MyActivities.detail;
    this.ls_insert_handler = Lino.courses.MyActivities.insert;
    var ww = this.containing_window;
    var start_date6044 = new Lino.DateField({ "selectOnFocus": true });
    var room6045 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyActivities/room" }) }) });
    var name6046 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    var line6047 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyActivities/line" }) }) });
    var workflow_buttons_disp6048 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id6049 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6050 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_time6051 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6052 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6053 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6054 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyActivities/user" }) }) });
    var every_unit6055 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6056 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6057 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6058 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6059 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6060 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6061 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6062 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6063 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6064 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6065 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var teacher6066 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyActivities/teacher" }) }) });
    var slot6067 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyActivities/slot" }) }) });
    var description6068 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6069 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6070 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6071 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6072 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var enrolments_until6073 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6074 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments6075 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp6076 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6077 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6078 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6079 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6080 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places6081 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6082 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6083 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6084 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6085 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6086 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6087 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6088 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6068.refresh();
      description_et6069.refresh();
      remark6070.refresh();
      presences_box_htmlbox6079.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6044, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.MyActivities.start_date) ", "width": Lino.chars2width(9), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room6045, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.MyActivities.room) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "name", "editable": true, "editor": name6046, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.MyActivities.name) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "line", "editable": true, "editor": line6047, "filter": { "type": "string" }, "header": "Tegevuste sari", "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.MyActivities.line) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.MyActivities.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6049, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "ref", "editable": true, "editor": ref6050, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "start_time", "editable": true, "editor": start_time6051, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date6052, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "end_time", "editable": true, "editor": end_time6053, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "user", "editable": true, "editor": user6054, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.MyActivities.user) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "every_unit", "editable": true, "editor": every_unit6055, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 12, "dataIndex": "every", "editable": true, "editor": every6056, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.every) ", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 20, "dataIndex": "max_events", "editable": true, "editor": max_events6064, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 21, "dataIndex": "max_date", "editable": true, "editor": max_date6065, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 22, "dataIndex": "teacher", "editable": true, "editor": teacher6066, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "hidden": true, "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.MyActivities.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "slot", "editable": true, "editor": slot6067, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.MyActivities.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "description", "editable": true, "editor": description6068, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.description) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "description_et", "editable": true, "editor": description_et6069, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "remark", "editable": true, "editor": remark6070, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state6071, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 28, "dataIndex": "max_places", "editable": true, "editor": max_places6072, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 29, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6073, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.MyActivities.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 30, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 32, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 33, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 34, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 35, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 36, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 37, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.MyActivities.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.MyActivities.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.MyActivities.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.MyActivities.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/MyActivities",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.MyActivities.detail;
    this.ls_insert_handler = Lino.courses.MyActivities.insert;
    Lino.courses.MyActivities.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.MyActivities.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.MyActivities.insertPanel(p);
});
Lino.courses.MyActivities.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.MyActivities.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" }, { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" } ], "menu_item_text": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/MyActivities",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.MyActivities.detail;
    this.ls_insert_handler = Lino.courses.MyActivities.insert;
    Lino.courses.MyActivities.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.MyActivities.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.MyActivities.detailPanel(p);
});
Lino.courses.MyActivities.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.MyActivities.GridPanel(p);
});
Lino.courses.MyActivities.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyActivities.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyActivities", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.DraftCourses
Lino.courses.DraftCourses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/DraftCourses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/DraftCourses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/DraftCourses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Draft activities",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.DraftCourses.detail;
    this.ls_insert_handler = Lino.courses.DraftCourses.insert;
    var ww = this.containing_window;
    var overview_disp6090 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var room6091 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/DraftCourses/room" }) }) });
    var id6092 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6093 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_date6094 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6095 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6096 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6097 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6098 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/DraftCourses/user" }) }) });
    var every_unit6099 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6100 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6101 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6102 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6103 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6104 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6105 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6106 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6107 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6108 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6109 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var line6110 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/DraftCourses/line" }) }) });
    var teacher6111 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/DraftCourses/teacher" }) }) });
    var slot6112 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/DraftCourses/slot" }) }) });
    var description6113 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6114 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6115 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6116 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6117 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name6118 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until6119 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6120 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments6121 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp6122 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6123 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6124 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6125 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6126 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places6127 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6128 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6129 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6130 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6131 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6132 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6133 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6134 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6113.refresh();
      description_et6114.refresh();
      remark6115.refresh();
      presences_box_htmlbox6125.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(courses.DraftCourses.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room6091, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.DraftCourses.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6092, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "ref", "editable": true, "editor": ref6093, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "start_date", "editable": true, "editor": start_date6094, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "start_time", "editable": true, "editor": start_time6095, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 6, "dataIndex": "end_date", "editable": true, "editor": end_date6096, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "end_time", "editable": true, "editor": end_time6097, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "user", "editable": true, "editor": user6098, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.DraftCourses.user) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "every_unit", "editable": true, "editor": every_unit6099, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 10, "dataIndex": "every", "editable": true, "editor": every6100, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.every) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 18, "dataIndex": "max_events", "editable": true, "editor": max_events6108, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 19, "dataIndex": "max_date", "editable": true, "editor": max_date6109, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "line", "editable": true, "editor": line6110, "filter": { "type": "string" }, "header": "Tegevuste sari", "hidden": true, "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.DraftCourses.line) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "teacher", "editable": true, "editor": teacher6111, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "hidden": true, "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.DraftCourses.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "slot", "editable": true, "editor": slot6112, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.DraftCourses.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "description", "editable": true, "editor": description6113, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.description) ", "width": Lino.chars2width(61) }, { "colIndex": 24, "dataIndex": "description_et", "editable": true, "editor": description_et6114, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "remark", "editable": true, "editor": remark6115, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state6116, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 27, "dataIndex": "max_places", "editable": true, "editor": max_places6117, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 28, "dataIndex": "name", "editable": true, "editor": name6118, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.name) ", "width": Lino.chars2width(22) }, { "colIndex": 29, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6119, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.DraftCourses.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 30, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 32, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 33, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 34, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 35, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 36, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 37, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.DraftCourses.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.DraftCourses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.DraftCourses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.DraftCourses.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/DraftCourses",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.DraftCourses.detail;
    this.ls_insert_handler = Lino.courses.DraftCourses.insert;
    Lino.courses.DraftCourses.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.DraftCourses.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.DraftCourses.insertPanel(p);
});
Lino.courses.DraftCourses.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.DraftCourses.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/DraftCourses",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.DraftCourses.detail;
    this.ls_insert_handler = Lino.courses.DraftCourses.insert;
    Lino.courses.DraftCourses.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.DraftCourses.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.DraftCourses.detailPanel(p);
});
Lino.courses.DraftCourses.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.DraftCourses.GridPanel(p);
});
Lino.courses.DraftCourses.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.DraftCourses.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/DraftCourses", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.ActiveCourses
Lino.courses.ActiveCourses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/ActiveCourses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/ActiveCourses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/ActiveCourses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Current activities",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "enrolments" }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "teacher" }, 'teacherHidden', { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "line" }, 'lineHidden', { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.ActiveCourses.detail;
    this.ls_insert_handler = Lino.courses.ActiveCourses.insert;
    var ww = this.containing_window;
    var overview_disp6136 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var enrolments6137 = new Ext.form.NumberField({ "disabled": true });
    var free_places6138 = new Ext.form.NumberField({ "disabled": true });
    var teacher6139 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ActiveCourses/teacher" }) }) });
    var room6140 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ActiveCourses/room" }) }) });
    var id6141 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6142 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_date6143 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6144 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6145 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6146 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6147 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ActiveCourses/user" }) }) });
    var every_unit6148 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6149 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6150 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6151 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6152 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6153 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6154 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6155 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6156 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6157 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6158 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var line6159 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ActiveCourses/line" }) }) });
    var slot6160 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ActiveCourses/slot" }) }) });
    var description6161 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6162 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6163 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6164 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6165 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name6166 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until6167 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6168 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var print_actions_disp6169 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6170 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6171 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6172 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6173 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6174 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6175 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6176 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6177 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6178 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6179 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6180 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6161.refresh();
      description_et6162.refresh();
      remark6163.refresh();
      presences_box_htmlbox6172.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(courses.ActiveCourses.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 1, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "sortable": false, "tooltip": "(courses.ActiveCourses.enrolments) ", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 2, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "sortable": false, "tooltip": "(courses.ActiveCourses.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "teacher", "editable": true, "editor": teacher6139, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.ActiveCourses.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "room", "editable": true, "editor": room6140, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.ActiveCourses.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6141, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "ref", "editable": true, "editor": ref6142, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date6143, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time6144, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date6145, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time6146, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "user", "editable": true, "editor": user6147, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.ActiveCourses.user) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "every_unit", "editable": true, "editor": every_unit6148, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 13, "dataIndex": "every", "editable": true, "editor": every6149, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.every) ", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 20, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 21, "dataIndex": "max_events", "editable": true, "editor": max_events6157, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 22, "dataIndex": "max_date", "editable": true, "editor": max_date6158, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "line", "editable": true, "editor": line6159, "filter": { "type": "string" }, "header": "Tegevuste sari", "hidden": true, "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.ActiveCourses.line) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "slot", "editable": true, "editor": slot6160, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.ActiveCourses.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "description", "editable": true, "editor": description6161, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.description) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "description_et", "editable": true, "editor": description_et6162, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "remark", "editable": true, "editor": remark6163, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 28, "dataIndex": "state", "editable": true, "editor": state6164, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 29, "dataIndex": "max_places", "editable": true, "editor": max_places6165, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 30, "dataIndex": "name", "editable": true, "editor": name6166, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.name) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6167, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.ActiveCourses.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 32, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.events_text) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 34, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 35, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 36, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.trying) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.ActiveCourses.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.ActiveCourses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.ActiveCourses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.ActiveCourses.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/ActiveCourses",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.ActiveCourses.detail;
    this.ls_insert_handler = Lino.courses.ActiveCourses.insert;
    Lino.courses.ActiveCourses.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.ActiveCourses.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.ActiveCourses.insertPanel(p);
});
Lino.courses.ActiveCourses.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.ActiveCourses.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/ActiveCourses",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.ActiveCourses.detail;
    this.ls_insert_handler = Lino.courses.ActiveCourses.insert;
    Lino.courses.ActiveCourses.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.ActiveCourses.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.ActiveCourses.detailPanel(p);
});
Lino.courses.ActiveCourses.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.ActiveCourses.GridPanel(p);
});
Lino.courses.ActiveCourses.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ActiveCourses.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ActiveCourses", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.InactiveCourses
Lino.courses.InactiveCourses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/InactiveCourses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/InactiveCourses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/InactiveCourses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Inactive courses",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "enrolments" }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.InactiveCourses.detail;
    this.ls_insert_handler = Lino.courses.InactiveCourses.insert;
    var ww = this.containing_window;
    var overview_disp6182 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var enrolments6183 = new Ext.form.NumberField({ "disabled": true });
    var free_places6184 = new Ext.form.NumberField({ "disabled": true });
    var room6185 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/InactiveCourses/room" }) }) });
    var id6186 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6187 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_date6188 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6189 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6190 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6191 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6192 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/InactiveCourses/user" }) }) });
    var every_unit6193 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6194 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6195 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6196 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6197 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6198 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6199 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6200 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6201 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6202 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6203 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var line6204 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/InactiveCourses/line" }) }) });
    var teacher6205 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/InactiveCourses/teacher" }) }) });
    var slot6206 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/InactiveCourses/slot" }) }) });
    var description6207 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6208 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6209 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6210 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6211 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name6212 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until6213 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6214 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var print_actions_disp6215 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6216 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6217 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6218 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6219 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6220 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6221 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6222 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6223 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6224 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6225 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6226 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6207.refresh();
      description_et6208.refresh();
      remark6209.refresh();
      presences_box_htmlbox6218.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(courses.InactiveCourses.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 1, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "sortable": false, "tooltip": "(courses.InactiveCourses.enrolments) ", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 2, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "sortable": false, "tooltip": "(courses.InactiveCourses.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "room", "editable": true, "editor": room6185, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.InactiveCourses.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id6186, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref6187, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date6188, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "start_time", "editable": true, "editor": start_time6189, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date6190, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "end_time", "editable": true, "editor": end_time6191, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "user", "editable": true, "editor": user6192, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.InactiveCourses.user) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "every_unit", "editable": true, "editor": every_unit6193, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 12, "dataIndex": "every", "editable": true, "editor": every6194, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.every) ", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 20, "dataIndex": "max_events", "editable": true, "editor": max_events6202, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 21, "dataIndex": "max_date", "editable": true, "editor": max_date6203, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 22, "dataIndex": "line", "editable": true, "editor": line6204, "filter": { "type": "string" }, "header": "Tegevuste sari", "hidden": true, "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.InactiveCourses.line) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "teacher", "editable": true, "editor": teacher6205, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "hidden": true, "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.InactiveCourses.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "slot", "editable": true, "editor": slot6206, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.InactiveCourses.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "description", "editable": true, "editor": description6207, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.description) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "description_et", "editable": true, "editor": description_et6208, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "remark", "editable": true, "editor": remark6209, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 28, "dataIndex": "state", "editable": true, "editor": state6210, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 29, "dataIndex": "max_places", "editable": true, "editor": max_places6211, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 30, "dataIndex": "name", "editable": true, "editor": name6212, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.name) ", "width": Lino.chars2width(22) }, { "colIndex": 31, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6213, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.InactiveCourses.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 32, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.events_text) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 34, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 35, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 36, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.trying) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.InactiveCourses.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.InactiveCourses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.InactiveCourses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.InactiveCourses.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/InactiveCourses",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.InactiveCourses.detail;
    this.ls_insert_handler = Lino.courses.InactiveCourses.insert;
    Lino.courses.InactiveCourses.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.InactiveCourses.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.InactiveCourses.insertPanel(p);
});
Lino.courses.InactiveCourses.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.InactiveCourses.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/InactiveCourses",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.InactiveCourses.detail;
    this.ls_insert_handler = Lino.courses.InactiveCourses.insert;
    Lino.courses.InactiveCourses.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.InactiveCourses.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.InactiveCourses.detailPanel(p);
});
Lino.courses.InactiveCourses.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.InactiveCourses.GridPanel(p);
});
Lino.courses.InactiveCourses.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.InactiveCourses.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/InactiveCourses", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.ClosedCourses
Lino.courses.ClosedCourses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/ClosedCourses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/ClosedCourses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/ClosedCourses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Closed courses",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "enrolments" }, { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.ClosedCourses.detail;
    this.ls_insert_handler = Lino.courses.ClosedCourses.insert;
    var ww = this.containing_window;
    var overview_disp6228 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var enrolments6229 = new Ext.form.NumberField({ "disabled": true });
    var room6230 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ClosedCourses/room" }) }) });
    var id6231 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6232 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_date6233 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6234 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6235 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6236 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6237 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ClosedCourses/user" }) }) });
    var every_unit6238 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6239 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6240 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6241 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6242 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6243 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6244 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6245 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6246 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6247 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6248 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var line6249 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ClosedCourses/line" }) }) });
    var teacher6250 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ClosedCourses/teacher" }) }) });
    var slot6251 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/ClosedCourses/slot" }) }) });
    var description6252 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6253 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6254 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6255 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6256 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name6257 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until6258 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6259 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var print_actions_disp6260 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6261 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6262 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6263 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6264 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places6265 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6266 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6267 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6268 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6269 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6270 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6271 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6272 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6252.refresh();
      description_et6253.refresh();
      remark6254.refresh();
      presences_box_htmlbox6263.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(courses.ClosedCourses.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 1, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "sortable": false, "tooltip": "(courses.ClosedCourses.enrolments) ", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "room", "editable": true, "editor": room6230, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.ClosedCourses.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id6231, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "ref", "editable": true, "editor": ref6232, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "start_date", "editable": true, "editor": start_date6233, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "start_time", "editable": true, "editor": start_time6234, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date6235, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "end_time", "editable": true, "editor": end_time6236, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user6237, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.ClosedCourses.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "every_unit", "editable": true, "editor": every_unit6238, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 11, "dataIndex": "every", "editable": true, "editor": every6239, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.every) ", "width": Lino.chars2width(6) }, { "colIndex": 12, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 19, "dataIndex": "max_events", "editable": true, "editor": max_events6247, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 20, "dataIndex": "max_date", "editable": true, "editor": max_date6248, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "line", "editable": true, "editor": line6249, "filter": { "type": "string" }, "header": "Tegevuste sari", "hidden": true, "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.ClosedCourses.line) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "teacher", "editable": true, "editor": teacher6250, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "hidden": true, "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.ClosedCourses.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "slot", "editable": true, "editor": slot6251, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.ClosedCourses.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "description", "editable": true, "editor": description6252, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.description) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "description_et", "editable": true, "editor": description_et6253, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "remark", "editable": true, "editor": remark6254, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state6255, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 28, "dataIndex": "max_places", "editable": true, "editor": max_places6256, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 29, "dataIndex": "name", "editable": true, "editor": name6257, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.name) ", "width": Lino.chars2width(22) }, { "colIndex": 30, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6258, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.ClosedCourses.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 31, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.events_text) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 33, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 34, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 35, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 36, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 37, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.ClosedCourses.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.ClosedCourses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.ClosedCourses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.ClosedCourses.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/ClosedCourses",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.ClosedCourses.detail;
    this.ls_insert_handler = Lino.courses.ClosedCourses.insert;
    Lino.courses.ClosedCourses.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.ClosedCourses.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.ClosedCourses.insertPanel(p);
});
Lino.courses.ClosedCourses.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.ClosedCourses.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/ClosedCourses",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.ClosedCourses.detail;
    this.ls_insert_handler = Lino.courses.ClosedCourses.insert;
    Lino.courses.ClosedCourses.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.ClosedCourses.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.ClosedCourses.detailPanel(p);
});
Lino.courses.ClosedCourses.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.ClosedCourses.GridPanel(p);
});
Lino.courses.ClosedCourses.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.ClosedCourses.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/ClosedCourses", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.Enrolments
Lino.courses.Enrolments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/Enrolments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/Enrolments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/Enrolments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Osav\u00f5tud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "name": "course" }, 'courseHidden', { "name": "course__state" }, 'course__stateHidden', { "name": "pupil" }, 'pupilHidden', { "name": "workflow_buttons" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "printed_by" }, 'printed_byHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "state" }, 'stateHidden', { "name": "places", "type": "int", "useNull": true }, { "name": "remark" }, { "name": "confirmation_details" }, { "name": "pupil_info" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "printed" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 10,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Enrolments.detail;
    this.ls_insert_handler = Lino.courses.Enrolments.insert;
    var ww = this.containing_window;
    var request_date6274 = new Lino.DateField({ "allowBlank": false, "selectOnFocus": true });
    var course6275 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/course" }) }) });
    var course__state6276 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "disabled": true, "maxLength": 10, "sortable": false });
    var pupil6277 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/pupil" }) }) });
    var workflow_buttons_disp6278 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user6279 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/Enrolments/user" }) }) });
    var id6280 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date6281 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date6282 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var printed_by6283 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var course_area6284 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "hidden": true, "store": [['','<br>']].concat(Lino.courses.CourseAreas) });
    var state6285 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.EnrolmentStates });
    var places6286 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var remark6287 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var confirmation_details6288 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Confirmation details" });
    var pupil_info_htmlbox6289 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "pupil_info", "title": "Participant", "value": "<br/>" });
    var mobile_item_disp6290 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6291 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6292 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var printed_disp6293 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      course6275.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course6275.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil6277.setContextValue('course', record ? record.data['courseHidden'] : undefined);
      confirmation_details6288.refresh();
      pupil_info_htmlbox6289.refresh();
    };
    this.onRender = function(ct, position) {
      course_area6284.on('change',Lino.chooser_handler(course6275,'course_area'));
      request_date6274.on('change',Lino.chooser_handler(course6275,'request_date'));
      course6275.on('change',Lino.chooser_handler(pupil6277,'course'));
      Lino.courses.Enrolments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "request_date", "editable": true, "editor": request_date6274, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "sortable": true, "tooltip": "(courses.Enrolments.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "course", "editable": true, "editor": course6275, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.Enrolments.course) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "course__state", "editable": false, "filter": { "type": "string" }, "header": "Staatus", "sortable": true, "tooltip": "(courses.Enrolments.course__state) ", "width": Lino.chars2width(12) }, { "colIndex": 3, "dataIndex": "pupil", "editable": true, "editor": pupil6277, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.Enrolments.pupil) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.Enrolments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "user", "editable": true, "editor": user6279, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.Enrolments.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id6280, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.Enrolments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date6281, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.Enrolments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date6282, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.Enrolments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(courses.Enrolments.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "course_area", "editable": false, "filter": { "type": "string" }, "header": "Layout", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.course_area) ", "width": Lino.chars2width(14) }, { "colIndex": 11, "dataIndex": "state", "editable": true, "editor": state6285, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.state) One of lino_xl.lib.courses.choicelists.EnrolmentStates.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 12, "dataIndex": "places", "editable": true, "editor": places6286, "filter": { "type": "numeric" }, "format": "0", "header": "Places used", "hidden": true, "sortable": true, "tooltip": "(courses.Enrolments.places) The number of participants in this enrolment.", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "remark", "editable": true, "editor": remark6287, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": true, "tooltip": "(courses.Enrolments.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "confirmation_details", "editable": true, "editor": confirmation_details6288, "filter": { "type": "string" }, "header": "Confirmation details", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.confirmation_details) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "pupil_info", "editable": false, "header": "Participant", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.pupil_info) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "hidden": true, "sortable": false, "tooltip": "(courses.Enrolments.printed) ", "width": Lino.chars2width(31) } ];
    Lino.courses.Enrolments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Enrolments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Enrolments.insertPanel = Ext.extend(Lino.courses.Enrolments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/Enrolments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Enrolments.detail;
    this.ls_insert_handler = Lino.courses.Enrolments.insert;
    Lino.courses.Enrolments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Enrolments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.Enrolments.insertPanel(p);
});
Lino.courses.Enrolments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.Enrolments.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/Enrolments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.Enrolments.detail;
    this.ls_insert_handler = Lino.courses.Enrolments.insert;
    Lino.courses.Enrolments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.Enrolments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.Enrolments.detailPanel(p);
});
Lino.courses.Enrolments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.Enrolments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Enrolments.ParamsPanel({});
  return new Lino.courses.Enrolments.GridPanel(p);
});
Lino.courses.Enrolments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/Enrolments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.AllEnrolments
Lino.courses.AllEnrolments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/AllEnrolments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/AllEnrolments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/AllEnrolments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Osav\u00f5tud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 34,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "course" }, 'courseHidden', { "name": "pupil" }, 'pupilHidden', { "name": "pupil__birth_date" }, { "name": "pupil__age" }, { "name": "pupil__country" }, 'pupil__countryHidden', { "name": "pupil__city" }, 'pupil__cityHidden', { "name": "pupil__gender" }, 'pupil__genderHidden', { "name": "printed_by" }, 'printed_byHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "state" }, 'stateHidden', { "name": "places", "type": "int", "useNull": true }, { "name": "remark" }, { "name": "confirmation_details" }, { "name": "pupil_info" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "printed" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.AllEnrolments.detail;
    this.ls_insert_handler = Lino.courses.AllEnrolments.insert;
    var ww = this.containing_window;
    var id6295 = new Ext.form.NumberField({ "selectOnFocus": true });
    var request_date6296 = new Lino.DateField({ "allowBlank": false, "selectOnFocus": true });
    var start_date6297 = new Lino.DateField({ "selectOnFocus": true });
    var end_date6298 = new Lino.DateField({ "selectOnFocus": true });
    var user6299 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/AllEnrolments/user" }) }) });
    var course6300 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/AllEnrolments/course" }) }) });
    var pupil6301 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/AllEnrolments/pupil" }) }) });
    var pupil__birth_date6302 = new Lino.IncompleteDateField({ "disabled": true, "sortable": false });
    var pupil__age_disp6303 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "sortable": false, "value": "<br/>" });
    var pupil__country6304 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Riik...", "pageSize": 20, "sortable": false, "store": new Lino.ComplexRemoteComboStore({  }) });
    var pupil__city6305 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Asum...", "pageSize": 20, "sortable": false, "store": new Lino.ComplexRemoteComboStore({  }) });
    var pupil__gender6306 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "disabled": true, "maxLength": 10, "sortable": false });
    var printed_by6307 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var course_area6308 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "hidden": true, "store": [['','<br>']].concat(Lino.courses.CourseAreas) });
    var state6309 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.EnrolmentStates });
    var places6310 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var remark6311 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var confirmation_details6312 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Confirmation details" });
    var pupil_info_htmlbox6313 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "pupil_info", "title": "Participant", "value": "<br/>" });
    var mobile_item_disp6314 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6315 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6316 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6317 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var printed_disp6318 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      course6300.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course6300.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil6301.setContextValue('course', record ? record.data['courseHidden'] : undefined);
      confirmation_details6312.refresh();
      pupil_info_htmlbox6313.refresh();
    };
    this.onRender = function(ct, position) {
      course_area6308.on('change',Lino.chooser_handler(course6300,'course_area'));
      request_date6296.on('change',Lino.chooser_handler(course6300,'request_date'));
      course6300.on('change',Lino.chooser_handler(pupil6301,'course'));
      Lino.courses.AllEnrolments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id6295, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(courses.AllEnrolments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "request_date", "editable": true, "editor": request_date6296, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "sortable": true, "tooltip": "(courses.AllEnrolments.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "start_date", "editable": true, "editor": start_date6297, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.AllEnrolments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 3, "dataIndex": "end_date", "editable": true, "editor": end_date6298, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "sortable": true, "tooltip": "(courses.AllEnrolments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 4, "dataIndex": "user", "editable": true, "editor": user6299, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.AllEnrolments.user) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "course", "editable": true, "editor": course6300, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.AllEnrolments.course) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "pupil", "editable": true, "editor": pupil6301, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.AllEnrolments.pupil) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "pupil__birth_date", "editable": false, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "sortable": true, "tooltip": "(courses.AllEnrolments.pupil__birth_date) ", "width": Lino.chars2width(13) }, { "colIndex": 8, "dataIndex": "pupil__age", "editable": false, "header": "Vanus", "sortable": false, "tooltip": "(courses.AllEnrolments.pupil__age) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "pupil__country", "editable": false, "filter": { "type": "string" }, "header": "Riik", "sortable": false, "tooltip": "(courses.AllEnrolments.pupil__country) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "pupil__city", "editable": false, "filter": { "type": "string" }, "header": "Linn", "sortable": false, "tooltip": "(courses.AllEnrolments.pupil__city) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "pupil__gender", "editable": false, "filter": { "type": "string" }, "header": "Sugu", "sortable": true, "tooltip": "(courses.AllEnrolments.pupil__gender) ", "width": Lino.chars2width(12) }, { "colIndex": 12, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(courses.AllEnrolments.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "course_area", "editable": false, "filter": { "type": "string" }, "header": "Layout", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.course_area) ", "width": Lino.chars2width(14) }, { "colIndex": 14, "dataIndex": "state", "editable": true, "editor": state6309, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.state) One of lino_xl.lib.courses.choicelists.EnrolmentStates.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 15, "dataIndex": "places", "editable": true, "editor": places6310, "filter": { "type": "numeric" }, "format": "0", "header": "Places used", "hidden": true, "sortable": true, "tooltip": "(courses.AllEnrolments.places) The number of participants in this enrolment.", "width": Lino.chars2width(6) }, { "colIndex": 16, "dataIndex": "remark", "editable": true, "editor": remark6311, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": true, "tooltip": "(courses.AllEnrolments.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "confirmation_details", "editable": true, "editor": confirmation_details6312, "filter": { "type": "string" }, "header": "Confirmation details", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.confirmation_details) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "pupil_info", "editable": false, "header": "Participant", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.pupil_info) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "hidden": true, "sortable": false, "tooltip": "(courses.AllEnrolments.printed) ", "width": Lino.chars2width(31) } ];
    Lino.courses.AllEnrolments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.AllEnrolments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.AllEnrolments.insertPanel = Ext.extend(Lino.courses.Enrolments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/AllEnrolments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.AllEnrolments.detail;
    this.ls_insert_handler = Lino.courses.AllEnrolments.insert;
    Lino.courses.AllEnrolments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.AllEnrolments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.AllEnrolments.insertPanel(p);
});
Lino.courses.AllEnrolments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.AllEnrolments.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/AllEnrolments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.AllEnrolments.detail;
    this.ls_insert_handler = Lino.courses.AllEnrolments.insert;
    Lino.courses.AllEnrolments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.AllEnrolments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.AllEnrolments.detailPanel(p);
});
Lino.courses.AllEnrolments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.AllEnrolments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Enrolments.ParamsPanel({});
  return new Lino.courses.AllEnrolments.GridPanel(p);
});
Lino.courses.AllEnrolments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/AllEnrolments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.PendingRequestedEnrolments
Lino.courses.PendingRequestedEnrolments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/PendingRequestedEnrolments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/PendingRequestedEnrolments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/PendingRequestedEnrolments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Pending requested enrolments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "name": "course" }, 'courseHidden', { "name": "pupil" }, 'pupilHidden', { "name": "remark" }, { "name": "user" }, 'userHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.PendingRequestedEnrolments.detail;
    this.ls_insert_handler = Lino.courses.PendingRequestedEnrolments.insert;
    var ww = this.containing_window;
    var request_date6320 = new Lino.DateField({ "allowBlank": false, "selectOnFocus": true });
    var course6321 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/PendingRequestedEnrolments/course" }) }) });
    var pupil6322 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/PendingRequestedEnrolments/pupil" }) }) });
    var remark6323 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user6324 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/PendingRequestedEnrolments/user" }) }) });
    var workflow_buttons_disp6325 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      course6321.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course6321.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil6322.setContextValue('course', record ? record.data['courseHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      request_date6320.on('change',Lino.chooser_handler(course6321,'request_date'));
      course6321.on('change',Lino.chooser_handler(pupil6322,'course'));
      Lino.courses.PendingRequestedEnrolments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "request_date", "editable": true, "editor": request_date6320, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "sortable": true, "tooltip": "(courses.PendingRequestedEnrolments.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "course", "editable": true, "editor": course6321, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.PendingRequestedEnrolments.course) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "pupil", "editable": true, "editor": pupil6322, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.PendingRequestedEnrolments.pupil) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark6323, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(courses.PendingRequestedEnrolments.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "user", "editable": true, "editor": user6324, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.PendingRequestedEnrolments.user) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.PendingRequestedEnrolments.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.courses.PendingRequestedEnrolments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.PendingRequestedEnrolments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.PendingRequestedEnrolments.insertPanel = Ext.extend(Lino.courses.Enrolments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/PendingRequestedEnrolments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.PendingRequestedEnrolments.detail;
    this.ls_insert_handler = Lino.courses.PendingRequestedEnrolments.insert;
    Lino.courses.PendingRequestedEnrolments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.PendingRequestedEnrolments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.PendingRequestedEnrolments.insertPanel(p);
});
Lino.courses.PendingRequestedEnrolments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.PendingRequestedEnrolments.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/PendingRequestedEnrolments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.PendingRequestedEnrolments.detail;
    this.ls_insert_handler = Lino.courses.PendingRequestedEnrolments.insert;
    Lino.courses.PendingRequestedEnrolments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.PendingRequestedEnrolments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.PendingRequestedEnrolments.detailPanel(p);
});
Lino.courses.PendingRequestedEnrolments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingRequestedEnrolments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Enrolments.ParamsPanel({});
  return new Lino.courses.PendingRequestedEnrolments.GridPanel(p);
});
Lino.courses.PendingRequestedEnrolments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingRequestedEnrolments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.PendingConfirmedEnrolments
Lino.courses.PendingConfirmedEnrolments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/PendingConfirmedEnrolments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/PendingConfirmedEnrolments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/PendingConfirmedEnrolments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Pending confirmed enrolments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "name": "course" }, 'courseHidden', { "name": "course__state" }, 'course__stateHidden', { "name": "pupil" }, 'pupilHidden', { "name": "workflow_buttons" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "printed_by" }, 'printed_byHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "state" }, 'stateHidden', { "name": "places", "type": "int", "useNull": true }, { "name": "remark" }, { "name": "confirmation_details" }, { "name": "pupil_info" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "printed" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 10,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.PendingConfirmedEnrolments.detail;
    this.ls_insert_handler = Lino.courses.PendingConfirmedEnrolments.insert;
    var ww = this.containing_window;
    var request_date6327 = new Lino.DateField({ "allowBlank": false, "selectOnFocus": true });
    var course6328 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/PendingConfirmedEnrolments/course" }) }) });
    var course__state6329 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "disabled": true, "maxLength": 10, "sortable": false });
    var pupil6330 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/PendingConfirmedEnrolments/pupil" }) }) });
    var workflow_buttons_disp6331 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user6332 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/PendingConfirmedEnrolments/user" }) }) });
    var id6333 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date6334 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date6335 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var printed_by6336 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var course_area6337 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "hidden": true, "store": [['','<br>']].concat(Lino.courses.CourseAreas) });
    var state6338 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.EnrolmentStates });
    var places6339 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var remark6340 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var confirmation_details6341 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Confirmation details" });
    var pupil_info_htmlbox6342 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "pupil_info", "title": "Participant", "value": "<br/>" });
    var mobile_item_disp6343 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6344 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6345 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var printed_disp6346 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      course6328.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course6328.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil6330.setContextValue('course', record ? record.data['courseHidden'] : undefined);
      confirmation_details6341.refresh();
      pupil_info_htmlbox6342.refresh();
    };
    this.onRender = function(ct, position) {
      course_area6337.on('change',Lino.chooser_handler(course6328,'course_area'));
      request_date6327.on('change',Lino.chooser_handler(course6328,'request_date'));
      course6328.on('change',Lino.chooser_handler(pupil6330,'course'));
      Lino.courses.PendingConfirmedEnrolments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "request_date", "editable": true, "editor": request_date6327, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "course", "editable": true, "editor": course6328, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.course) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "course__state", "editable": false, "filter": { "type": "string" }, "header": "Staatus", "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.course__state) ", "width": Lino.chars2width(12) }, { "colIndex": 3, "dataIndex": "pupil", "editable": true, "editor": pupil6330, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.pupil) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "user", "editable": true, "editor": user6332, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id6333, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date6334, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date6335, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "course_area", "editable": false, "filter": { "type": "string" }, "header": "Layout", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.course_area) ", "width": Lino.chars2width(14) }, { "colIndex": 11, "dataIndex": "state", "editable": true, "editor": state6338, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.state) One of lino_xl.lib.courses.choicelists.EnrolmentStates.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 12, "dataIndex": "places", "editable": true, "editor": places6339, "filter": { "type": "numeric" }, "format": "0", "header": "Places used", "hidden": true, "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.places) The number of participants in this enrolment.", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "remark", "editable": true, "editor": remark6340, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": true, "tooltip": "(courses.PendingConfirmedEnrolments.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "confirmation_details", "editable": true, "editor": confirmation_details6341, "filter": { "type": "string" }, "header": "Confirmation details", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.confirmation_details) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "pupil_info", "editable": false, "header": "Participant", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.pupil_info) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "hidden": true, "sortable": false, "tooltip": "(courses.PendingConfirmedEnrolments.printed) ", "width": Lino.chars2width(31) } ];
    Lino.courses.PendingConfirmedEnrolments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.PendingConfirmedEnrolments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.PendingConfirmedEnrolments.insertPanel = Ext.extend(Lino.courses.Enrolments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/PendingConfirmedEnrolments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.PendingConfirmedEnrolments.detail;
    this.ls_insert_handler = Lino.courses.PendingConfirmedEnrolments.insert;
    Lino.courses.PendingConfirmedEnrolments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.PendingConfirmedEnrolments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.PendingConfirmedEnrolments.insertPanel(p);
});
Lino.courses.PendingConfirmedEnrolments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.PendingConfirmedEnrolments.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/PendingConfirmedEnrolments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.PendingConfirmedEnrolments.detail;
    this.ls_insert_handler = Lino.courses.PendingConfirmedEnrolments.insert;
    Lino.courses.PendingConfirmedEnrolments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.PendingConfirmedEnrolments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.PendingConfirmedEnrolments.detailPanel(p);
});
Lino.courses.PendingConfirmedEnrolments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.PendingConfirmedEnrolments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Enrolments.ParamsPanel({});
  return new Lino.courses.PendingConfirmedEnrolments.GridPanel(p);
});
Lino.courses.PendingConfirmedEnrolments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/PendingConfirmedEnrolments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class deploy.Deployments
Lino.deploy.Deployments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/deploy/Deployments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/deploy/Deployments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/deploy/Deployments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Wishes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "ticket" }, 'ticketHidden', { "name": "milestone" }, 'milestoneHidden', { "name": "remark" }, { "name": "wish_type" }, 'wish_typeHidden', { "name": "old_ticket_state" }, 'old_ticket_stateHidden', { "name": "new_ticket_state" }, 'new_ticket_stateHidden', { "name": "deferred_to" }, 'deferred_toHidden', { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 50,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.Deployments.detail;
    this.ls_insert_handler = Lino.deploy.Deployments.insert;
    var ww = this.containing_window;
    var id6348 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno6349 = new Ext.form.NumberField({ "selectOnFocus": true });
    var ticket6350 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/Deployments/ticket" }) }) });
    var milestone6351 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/Deployments/milestone" }) }) });
    var remark6352 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var wish_type6353 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.deploy.WishTypes) });
    var old_ticket_state6354 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var new_ticket_state6355 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var deferred_to6356 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/Deployments/deferred_to" }) }) });
    var workflow_buttons_disp6357 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp6358 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6359 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6360 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6361 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id6348, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(deploy.Deployments.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno6349, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(deploy.Deployments.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "ticket", "editable": true, "editor": ticket6350, "filter": { "type": "string" }, "header": "Lipik", "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(deploy.Deployments.ticket) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "milestone", "editable": true, "editor": milestone6351, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('milestoneHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(deploy.Deployments.milestone) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "remark", "editable": true, "editor": remark6352, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": false, "tooltip": "(deploy.Deployments.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 5, "dataIndex": "wish_type", "editable": true, "editor": wish_type6353, "filter": { "type": "string" }, "header": "Wish type", "sortable": false, "tooltip": "(deploy.Deployments.wish_type) ", "width": Lino.chars2width(16) }, { "colIndex": 6, "dataIndex": "old_ticket_state", "editable": true, "editor": old_ticket_state6354, "filter": { "type": "string" }, "header": "", "sortable": false, "tooltip": "(deploy.Deployments.old_ticket_state) ", "width": Lino.chars2width(12) }, { "colIndex": 7, "dataIndex": "new_ticket_state", "editable": true, "editor": new_ticket_state6355, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(deploy.Deployments.new_ticket_state) ", "width": Lino.chars2width(12) }, { "colIndex": 8, "dataIndex": "deferred_to", "editable": true, "editor": deferred_to6356, "filter": { "type": "string" }, "header": "Deferred to", "renderer": Lino.fk_renderer('deferred_toHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(deploy.Deployments.deferred_to) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(deploy.Deployments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(deploy.Deployments.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(deploy.Deployments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(deploy.Deployments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(deploy.Deployments.overview) ", "width": Lino.chars2width(31) } ];
    Lino.deploy.Deployments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.Deployments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.deploy.Deployments.insertPanel = Ext.extend(Lino.deploy.Deployments.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/deploy/Deployments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.Deployments.detail;
    this.ls_insert_handler = Lino.deploy.Deployments.insert;
    Lino.deploy.Deployments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.Deployments.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.deploy.Deployments.insertPanel(p);
});
Lino.deploy.Deployments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.deploy.Deployments.detailPanel = Ext.extend(Lino.deploy.Deployments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/deploy/Deployments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.Deployments.detail;
    this.ls_insert_handler = Lino.deploy.Deployments.insert;
    Lino.deploy.Deployments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.Deployments.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "is_main_window": true };
  return new Lino.deploy.Deployments.detailPanel(p);
});
Lino.deploy.Deployments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.deploy.Deployments.ParamsPanel({});
  return new Lino.deploy.Deployments.GridPanel(p);
});
Lino.deploy.Deployments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.Deployments.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/Deployments", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class meetings.Meetings
Lino.meetings.Meetings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/meetings/Meetings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/Meetings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/Meetings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Meetings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 38,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "name" }, { "name": "room" }, 'roomHidden', { "name": "workflow_buttons" }, { "name": "list" }, 'listHidden', { "name": "id", "type": "int" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 68,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.Meetings.detail;
    this.ls_insert_handler = Lino.meetings.Meetings.insert;
    var ww = this.containing_window;
    var start_date6363 = new Lino.DateField({ "selectOnFocus": true });
    var name6364 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    var room6365 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/room" }) }) });
    var workflow_buttons_disp6366 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var list6367 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/list" }) }) });
    var id6368 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_time6369 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6370 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6371 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6372 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/Meetings/user" }) }) });
    var every_unit6373 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6374 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var monday6375 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6376 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6377 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6378 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6379 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6380 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6381 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6382 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6383 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var description6384 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6385 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6386 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6387 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.meetings.MeetingStates });
    var mobile_item_disp6388 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6389 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6390 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var weekdays_text_disp6391 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6392 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6393 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6394 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6384.refresh();
      description_et6385.refresh();
      remark6386.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6363, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(meetings.Meetings.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name6364, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(meetings.Meetings.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "room", "editable": true, "editor": room6365, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(meetings.Meetings.room) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(meetings.Meetings.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "list", "editable": true, "editor": list6367, "filter": { "type": "string" }, "header": "Memebers", "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(meetings.Meetings.list) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6368, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "start_time", "editable": true, "editor": start_time6369, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date6370, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "end_time", "editable": true, "editor": end_time6371, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "user", "editable": true, "editor": user6372, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(meetings.Meetings.user) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "every_unit", "editable": true, "editor": every_unit6373, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 11, "dataIndex": "every", "editable": true, "editor": every6374, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.every) ", "width": Lino.chars2width(6) }, { "colIndex": 12, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 19, "dataIndex": "max_events", "editable": true, "editor": max_events6382, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 20, "dataIndex": "max_date", "editable": true, "editor": max_date6383, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(meetings.Meetings.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "description", "editable": true, "editor": description6384, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.description) ", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "description_et", "editable": true, "editor": description_et6385, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "remark", "editable": true, "editor": remark6386, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 24, "dataIndex": "state", "editable": true, "editor": state6387, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "colIndex": 25, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.what_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(meetings.Meetings.duration) ", "width": Lino.chars2width(8) } ];
    Lino.meetings.Meetings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.Meetings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.Meetings.insertPanel = Ext.extend(Lino.meetings.Meetings.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/meetings/Meetings",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.Meetings.detail;
    this.ls_insert_handler = Lino.meetings.Meetings.insert;
    Lino.meetings.Meetings.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.Meetings.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.meetings.Meetings.insertPanel(p);
});
Lino.meetings.Meetings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.Meetings.detailPanel = Ext.extend(Lino.meetings.Meetings.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/meetings/Meetings",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.Meetings.detail;
    this.ls_insert_handler = Lino.meetings.Meetings.insert;
    Lino.meetings.Meetings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.Meetings.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.Meetings.detailPanel(p);
});
Lino.meetings.Meetings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.meetings.Meetings.ParamsPanel({});
  return new Lino.meetings.Meetings.GridPanel(p);
});
Lino.meetings.Meetings.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.Meetings.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/Meetings", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class meetings.AllMeetings
Lino.meetings.AllMeetings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/meetings/AllMeetings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/AllMeetings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/AllMeetings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Meetings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "room" }, 'roomHidden', { "name": "user" }, 'userHidden', { "name": "name" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 68,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.AllMeetings.detail;
    this.ls_insert_handler = Lino.meetings.AllMeetings.insert;
    var ww = this.containing_window;
    var start_date6396 = new Lino.DateField({ "selectOnFocus": true });
    var room6397 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/AllMeetings/room" }) }) });
    var user6398 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/AllMeetings/user" }) }) });
    var name6399 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6396, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(meetings.AllMeetings.start_date) ", "width": Lino.chars2width(9), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room6397, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(meetings.AllMeetings.room) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user6398, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(meetings.AllMeetings.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "name", "editable": true, "editor": name6399, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(meetings.AllMeetings.name) ", "width": Lino.chars2width(22) } ];
    Lino.meetings.AllMeetings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.AllMeetings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.AllMeetings.insertPanel = Ext.extend(Lino.meetings.Meetings.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/meetings/AllMeetings",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.AllMeetings.detail;
    this.ls_insert_handler = Lino.meetings.AllMeetings.insert;
    Lino.meetings.AllMeetings.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.AllMeetings.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.meetings.AllMeetings.insertPanel(p);
});
Lino.meetings.AllMeetings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.AllMeetings.detailPanel = Ext.extend(Lino.meetings.Meetings.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/meetings/AllMeetings",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.AllMeetings.detail;
    this.ls_insert_handler = Lino.meetings.AllMeetings.insert;
    Lino.meetings.AllMeetings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.AllMeetings.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.AllMeetings.detailPanel(p);
});
Lino.meetings.AllMeetings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.meetings.Meetings.ParamsPanel({});
  return new Lino.meetings.AllMeetings.GridPanel(p);
});
Lino.meetings.AllMeetings.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.AllMeetings.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/AllMeetings", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class meetings.MyMeetings
Lino.meetings.MyMeetings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/meetings/MyMeetings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/MyMeetings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/MyMeetings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Meetings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 38,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "room" }, 'roomHidden', { "name": "name" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "list" }, 'listHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 68,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.MyMeetings.detail;
    this.ls_insert_handler = Lino.meetings.MyMeetings.insert;
    var ww = this.containing_window;
    var start_date6401 = new Lino.DateField({ "selectOnFocus": true });
    var room6402 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/MyMeetings/room" }) }) });
    var name6403 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    var workflow_buttons_disp6404 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id6405 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_time6406 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6407 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6408 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6409 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/MyMeetings/user" }) }) });
    var every_unit6410 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6411 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var monday6412 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6413 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6414 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6415 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6416 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6417 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6418 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6419 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6420 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var list6421 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/MyMeetings/list" }) }) });
    var description6422 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6423 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6424 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6425 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.meetings.MeetingStates });
    var mobile_item_disp6426 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6427 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6428 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var weekdays_text_disp6429 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6430 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6431 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6432 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6422.refresh();
      description_et6423.refresh();
      remark6424.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6401, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(meetings.MyMeetings.start_date) ", "width": Lino.chars2width(9), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room6402, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(meetings.MyMeetings.room) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "name", "editable": true, "editor": name6403, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(meetings.MyMeetings.name) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(meetings.MyMeetings.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id6405, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "start_time", "editable": true, "editor": start_time6406, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 6, "dataIndex": "end_date", "editable": true, "editor": end_date6407, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "end_time", "editable": true, "editor": end_time6408, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "user", "editable": true, "editor": user6409, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(meetings.MyMeetings.user) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "every_unit", "editable": true, "editor": every_unit6410, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 10, "dataIndex": "every", "editable": true, "editor": every6411, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.every) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 18, "dataIndex": "max_events", "editable": true, "editor": max_events6419, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 19, "dataIndex": "max_date", "editable": true, "editor": max_date6420, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(meetings.MyMeetings.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "list", "editable": true, "editor": list6421, "filter": { "type": "string" }, "header": "Memebers", "hidden": true, "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(meetings.MyMeetings.list) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "description", "editable": true, "editor": description6422, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.description) ", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "description_et", "editable": true, "editor": description_et6423, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "remark", "editable": true, "editor": remark6424, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 24, "dataIndex": "state", "editable": true, "editor": state6425, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "colIndex": 25, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.what_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(meetings.MyMeetings.duration) ", "width": Lino.chars2width(8) } ];
    Lino.meetings.MyMeetings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.MyMeetings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.MyMeetings.insertPanel = Ext.extend(Lino.meetings.Meetings.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/meetings/MyMeetings",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.MyMeetings.detail;
    this.ls_insert_handler = Lino.meetings.MyMeetings.insert;
    Lino.meetings.MyMeetings.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.MyMeetings.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.meetings.MyMeetings.insertPanel(p);
});
Lino.meetings.MyMeetings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.MyMeetings.detailPanel = Ext.extend(Lino.meetings.Meetings.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/meetings/MyMeetings",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.MyMeetings.detail;
    this.ls_insert_handler = Lino.meetings.MyMeetings.insert;
    Lino.meetings.MyMeetings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.MyMeetings.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.MyMeetings.detailPanel(p);
});
Lino.meetings.MyMeetings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.meetings.Meetings.ParamsPanel({});
  return new Lino.meetings.MyMeetings.GridPanel(p);
});
Lino.meetings.MyMeetings.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MyMeetings.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MyMeetings", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class meetings.ActiveMeetings
Lino.meetings.ActiveMeetings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/meetings/ActiveMeetings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/ActiveMeetings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/ActiveMeetings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Future Meetings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 38,
  ls_store_fields : [ { "name": "overview" }, { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "list" }, 'listHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "name" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 68,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.ActiveMeetings.detail;
    this.ls_insert_handler = Lino.meetings.ActiveMeetings.insert;
    var ww = this.containing_window;
    var overview_disp6434 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var room6435 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/ActiveMeetings/room" }) }) });
    var id6436 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date6437 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6438 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6439 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6440 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6441 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/ActiveMeetings/user" }) }) });
    var every_unit6442 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6443 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var monday6444 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6445 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6446 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6447 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6448 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6449 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6450 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6451 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6452 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var list6453 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/ActiveMeetings/list" }) }) });
    var description6454 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6455 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6456 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6457 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.meetings.MeetingStates });
    var name6458 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var mobile_item_disp6459 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6460 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6461 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var weekdays_text_disp6462 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6463 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6464 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6465 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6454.refresh();
      description_et6455.refresh();
      remark6456.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(meetings.ActiveMeetings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room6435, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(meetings.ActiveMeetings.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6436, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "start_date", "editable": true, "editor": start_date6437, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 4, "dataIndex": "start_time", "editable": true, "editor": start_time6438, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date6439, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "end_time", "editable": true, "editor": end_time6440, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user6441, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(meetings.ActiveMeetings.user) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "every_unit", "editable": true, "editor": every_unit6442, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 9, "dataIndex": "every", "editable": true, "editor": every6443, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.every) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 17, "dataIndex": "max_events", "editable": true, "editor": max_events6451, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 18, "dataIndex": "max_date", "editable": true, "editor": max_date6452, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 19, "dataIndex": "list", "editable": true, "editor": list6453, "filter": { "type": "string" }, "header": "Memebers", "hidden": true, "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(meetings.ActiveMeetings.list) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "description", "editable": true, "editor": description6454, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.description) ", "width": Lino.chars2width(61) }, { "colIndex": 21, "dataIndex": "description_et", "editable": true, "editor": description_et6455, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "remark", "editable": true, "editor": remark6456, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "state", "editable": true, "editor": state6457, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "colIndex": 24, "dataIndex": "name", "editable": true, "editor": name6458, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(meetings.ActiveMeetings.name) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.what_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(meetings.ActiveMeetings.duration) ", "width": Lino.chars2width(8) } ];
    Lino.meetings.ActiveMeetings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.ActiveMeetings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.ActiveMeetings.insertPanel = Ext.extend(Lino.meetings.Meetings.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/meetings/ActiveMeetings",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.ActiveMeetings.detail;
    this.ls_insert_handler = Lino.meetings.ActiveMeetings.insert;
    Lino.meetings.ActiveMeetings.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.ActiveMeetings.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.meetings.ActiveMeetings.insertPanel(p);
});
Lino.meetings.ActiveMeetings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.ActiveMeetings.detailPanel = Ext.extend(Lino.meetings.Meetings.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/meetings/ActiveMeetings",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.ActiveMeetings.detail;
    this.ls_insert_handler = Lino.meetings.ActiveMeetings.insert;
    Lino.meetings.ActiveMeetings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.ActiveMeetings.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.ActiveMeetings.detailPanel(p);
});
Lino.meetings.ActiveMeetings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.meetings.Meetings.ParamsPanel({});
  return new Lino.meetings.ActiveMeetings.GridPanel(p);
});
Lino.meetings.ActiveMeetings.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.ActiveMeetings.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/ActiveMeetings", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class meetings.InactiveMeetings
Lino.meetings.InactiveMeetings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/meetings/InactiveMeetings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/InactiveMeetings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/InactiveMeetings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Inactive Meetings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 38,
  ls_store_fields : [ { "name": "overview" }, { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "list" }, 'listHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "name" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 68,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.InactiveMeetings.detail;
    this.ls_insert_handler = Lino.meetings.InactiveMeetings.insert;
    var ww = this.containing_window;
    var overview_disp6467 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var room6468 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/InactiveMeetings/room" }) }) });
    var id6469 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date6470 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6471 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6472 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6473 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6474 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/InactiveMeetings/user" }) }) });
    var every_unit6475 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6476 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var monday6477 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6478 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6479 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6480 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6481 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6482 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6483 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6484 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6485 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var list6486 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/InactiveMeetings/list" }) }) });
    var description6487 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6488 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6489 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6490 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.meetings.MeetingStates });
    var name6491 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var mobile_item_disp6492 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6493 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6494 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var weekdays_text_disp6495 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6496 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6497 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6498 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description6487.refresh();
      description_et6488.refresh();
      remark6489.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(meetings.InactiveMeetings.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room6468, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(meetings.InactiveMeetings.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6469, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "start_date", "editable": true, "editor": start_date6470, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 4, "dataIndex": "start_time", "editable": true, "editor": start_time6471, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date6472, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "end_time", "editable": true, "editor": end_time6473, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user6474, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(meetings.InactiveMeetings.user) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "every_unit", "editable": true, "editor": every_unit6475, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 9, "dataIndex": "every", "editable": true, "editor": every6476, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.every) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 17, "dataIndex": "max_events", "editable": true, "editor": max_events6484, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 18, "dataIndex": "max_date", "editable": true, "editor": max_date6485, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 19, "dataIndex": "list", "editable": true, "editor": list6486, "filter": { "type": "string" }, "header": "Memebers", "hidden": true, "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(meetings.InactiveMeetings.list) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "description", "editable": true, "editor": description6487, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.description) ", "width": Lino.chars2width(61) }, { "colIndex": 21, "dataIndex": "description_et", "editable": true, "editor": description_et6488, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "remark", "editable": true, "editor": remark6489, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "state", "editable": true, "editor": state6490, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "colIndex": 24, "dataIndex": "name", "editable": true, "editor": name6491, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(meetings.InactiveMeetings.name) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.what_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(meetings.InactiveMeetings.duration) ", "width": Lino.chars2width(8) } ];
    Lino.meetings.InactiveMeetings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.InactiveMeetings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.InactiveMeetings.insertPanel = Ext.extend(Lino.meetings.Meetings.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/meetings/InactiveMeetings",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.InactiveMeetings.detail;
    this.ls_insert_handler = Lino.meetings.InactiveMeetings.insert;
    Lino.meetings.InactiveMeetings.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.InactiveMeetings.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.meetings.InactiveMeetings.insertPanel(p);
});
Lino.meetings.InactiveMeetings.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.meetings.InactiveMeetings.detailPanel = Ext.extend(Lino.meetings.Meetings.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/meetings/InactiveMeetings",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.meetings.InactiveMeetings.detail;
    this.ls_insert_handler = Lino.meetings.InactiveMeetings.insert;
    Lino.meetings.InactiveMeetings.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.InactiveMeetings.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.InactiveMeetings.detailPanel(p);
});
Lino.meetings.InactiveMeetings.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.meetings.Meetings.ParamsPanel({});
  return new Lino.meetings.InactiveMeetings.GridPanel(p);
});
Lino.meetings.InactiveMeetings.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.InactiveMeetings.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/InactiveMeetings", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class sessions.SessionTable
Lino.sessions.SessionTable.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/sessions/SessionTable",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/sessions/SessionTable','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/sessions/SessionTable','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "sessioonid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "session_key" }, { "name": "session_data" }, { "name": "expire_date" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 69,
  ls_id_property : "session_key",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var session_key6500 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 40, "selectOnFocus": true });
    var session_data6501 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "sessiooni andmed" });
    var expire_date6502 = new Ext.form.DisplayField({ "allowBlank": false, "selectOnFocus": true, "value": "<br>" });
    this.before_row_edit = function(record) {
      session_data6501.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "session_key", "editable": true, "editor": session_key6500, "filter": { "type": "string" }, "header": "sessiooniv\u00f5ti", "sortable": true, "tooltip": "(sessions.SessionTable.session_key) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "session_data", "editable": true, "editor": session_data6501, "filter": { "type": "string" }, "header": "sessiooni andmed", "sortable": false, "tooltip": "(sessions.SessionTable.session_data) ", "width": Lino.chars2width(61) }, { "colIndex": 2, "dataIndex": "expire_date", "editable": true, "editor": expire_date6502, "header": "kehtivusaja l\u00f5pp", "sortable": true, "tooltip": "(sessions.SessionTable.expire_date) ", "width": Lino.chars2width(17) } ];
    Lino.sessions.SessionTable.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.sessions.SessionTable.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/sessions/SessionTable", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.sessions.SessionTable.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/sessions/SessionTable", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.sessions.SessionTable.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/sessions/SessionTable", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.sessions.SessionTable.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/sessions/SessionTable", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.sessions.SessionTable.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/sessions/SessionTable", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.sessions.SessionTable.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/sessions/SessionTable", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.sessions.SessionTable.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.sessions.SessionTable.GridPanel(p);
});

// js_render_GridPanel_class countries.PlacesByPlace
Lino.countries.PlacesByPlace.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/countries/PlacesByPlace",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/countries/PlacesByPlace','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/countries/PlacesByPlace','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Subdivisions",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "type" }, 'typeHidden', { "name": "zip_code" }, { "name": "id", "type": "int" }, { "name": "country" }, 'countryHidden', { "name": "children_summary" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "parent" }, 'parentHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 2,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.PlacesByPlace.detail;
    this.ls_insert_handler = Lino.countries.PlacesByPlace.insert;
    var ww = this.containing_window;
    var name1929 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et1930 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var type1931 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/PlacesByPlace/type" }) }) });
    var zip_code1932 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(8), "maxLength": 8, "selectOnFocus": true });
    var id1933 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var country1934 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/PlacesByPlace/country" }) }) });
    var children_summary_disp1935 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp1936 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1937 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1938 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1939 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var parent1940 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/PlacesByPlace/parent" }) }) });
    this.before_row_edit = function(record) {
      type1931.setContextValue('country', record ? record.data['countryHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      country1934.on('change',Lino.chooser_handler(type1931,'country'));
      Lino.countries.PlacesByPlace.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name1929, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(countries.PlacesByPlace.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et1930, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(countries.PlacesByPlace.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "type", "editable": true, "editor": type1931, "filter": { "type": "string" }, "header": "Asumiliik", "sortable": false, "tooltip": "(countries.PlacesByPlace.type) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "zip_code", "editable": true, "editor": zip_code1932, "filter": { "type": "string" }, "header": "zip code", "sortable": true, "tooltip": "(countries.PlacesByPlace.zip_code) ", "width": Lino.chars2width(10) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id1933, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(countries.PlacesByPlace.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "country", "editable": true, "editor": country1934, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(countries.PlacesByPlace.country) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByPlace.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByPlace.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByPlace.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByPlace.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByPlace.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "parent", "editable": true, "editor": parent1940, "filter": { "type": "string" }, "header": "Part of", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(countries.PlacesByPlace.parent) The superordinate geographic place of which this place is a part.", "width": Lino.chars2width(21) } ];
    Lino.countries.PlacesByPlace.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlacesByPlace.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByPlace.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByPlace.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.PlacesByPlace.insertPanel = Ext.extend(Lino.countries.Places.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/countries/PlacesByPlace",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.PlacesByPlace.detail;
    this.ls_insert_handler = Lino.countries.PlacesByPlace.insert;
    Lino.countries.PlacesByPlace.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlacesByPlace.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.countries.PlacesByPlace.insertPanel(p);
});
Lino.countries.PlacesByPlace.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByPlace.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByPlace.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByPlace.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.PlacesByPlace.detailPanel = Ext.extend(Lino.countries.Places.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/countries/PlacesByPlace",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.PlacesByPlace.detail;
    this.ls_insert_handler = Lino.countries.PlacesByPlace.insert;
    Lino.countries.PlacesByPlace.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlacesByPlace.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.PlacesByPlace.detailPanel(p);
});
Lino.countries.PlacesByPlace.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByPlace.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.PlacesByPlace.GridPanel(p);
});
Lino.countries.PlacesByPlace.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByPlace", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class countries.PlacesByCountry
Lino.countries.PlacesByCountry.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/countries/PlacesByCountry",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/countries/PlacesByCountry','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/countries/PlacesByCountry','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Asumid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "name" }, { "name": "name_et" }, { "name": "type" }, 'typeHidden', { "name": "zip_code" }, { "name": "id", "type": "int" }, { "name": "parent" }, 'parentHidden', { "name": "children_summary" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "country" }, 'countryHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 2,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.PlacesByCountry.detail;
    this.ls_insert_handler = Lino.countries.PlacesByCountry.insert;
    var ww = this.containing_window;
    var name1900 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et1901 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var type1902 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/PlacesByCountry/type" }) }) });
    var zip_code1903 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(8), "maxLength": 8, "selectOnFocus": true });
    var id1904 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var parent1905 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/PlacesByCountry/parent" }) }) });
    var children_summary_disp1906 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp1907 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1908 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1909 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1910 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var country1911 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/PlacesByCountry/country" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      type1902.setContextValue('mk',bp['mk']);
      type1902.setContextValue('mt',bp['mt']);
    };
    this.onRender = function(ct, position) {
      country1911.on('change',Lino.chooser_handler(type1902,'country'));
      Lino.countries.PlacesByCountry.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": true, "editor": name1900, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(countries.PlacesByCountry.name) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name_et", "editable": true, "editor": name_et1901, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(countries.PlacesByCountry.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "type", "editable": true, "editor": type1902, "filter": { "type": "string" }, "header": "Asumiliik", "sortable": false, "tooltip": "(countries.PlacesByCountry.type) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "zip_code", "editable": true, "editor": zip_code1903, "filter": { "type": "string" }, "header": "zip code", "sortable": true, "tooltip": "(countries.PlacesByCountry.zip_code) ", "width": Lino.chars2width(10) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id1904, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(countries.PlacesByCountry.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "parent", "editable": true, "editor": parent1905, "filter": { "type": "string" }, "header": "Part of", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(countries.PlacesByCountry.parent) The superordinate geographic place of which this place is a part.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByCountry.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByCountry.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByCountry.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByCountry.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(countries.PlacesByCountry.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country1911, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(countries.PlacesByCountry.country) ", "width": Lino.chars2width(21) } ];
    Lino.countries.PlacesByCountry.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlacesByCountry.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByCountry.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByCountry.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.PlacesByCountry.insertPanel = Ext.extend(Lino.countries.Places.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/countries/PlacesByCountry",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.PlacesByCountry.detail;
    this.ls_insert_handler = Lino.countries.PlacesByCountry.insert;
    Lino.countries.PlacesByCountry.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlacesByCountry.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.countries.PlacesByCountry.insertPanel(p);
});
Lino.countries.PlacesByCountry.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByCountry.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByCountry.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByCountry.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.countries.PlacesByCountry.detailPanel = Ext.extend(Lino.countries.Places.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/countries/PlacesByCountry",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.countries.PlacesByCountry.detail;
    this.ls_insert_handler = Lino.countries.PlacesByCountry.insert;
    Lino.countries.PlacesByCountry.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlacesByCountry.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.PlacesByCountry.detailPanel(p);
});
Lino.countries.PlacesByCountry.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlacesByCountry.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.PlacesByCountry.GridPanel(p);
});
Lino.countries.PlacesByCountry.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlacesByCountry", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.PartnersByCity
Lino.contacts.PartnersByCity.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/PartnersByCity",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/PartnersByCity','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/PartnersByCity','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Partnerid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 31,
  ls_store_fields : [ { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "language" }, 'languageHidden', { "name": "id", "type": "int" }, { "name": "email" }, { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "remarks" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "city" }, 'cityHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.PartnersByCity.detail;
    this.ls_insert_handler = Lino.contacts.PartnersByCity.insert;
    var ww = this.containing_window;
    var street1959 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var street_no1960 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "maxLength": 10, "selectOnFocus": true });
    var street_box1961 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "maxLength": 10, "selectOnFocus": true });
    var addr21962 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var name1963 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var language1964 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var id1965 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email1966 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var url1967 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone1968 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm1969 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax1970 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country1971 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/PartnersByCity/country" }) }) });
    var zip_code1972 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region1973 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/PartnersByCity/region" }) }) });
    var addr11974 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix1975 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks1976 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var name_column_disp1977 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp1978 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1979 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1980 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1981 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp1982 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp1983 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var city1984 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/PartnersByCity/city" }) }) });
    this.before_row_edit = function(record) {
      region1973.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks1976.refresh();
      city1984.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1984.setContextValue('region', record ? record.data['regionHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      country1971.on('change',Lino.chooser_handler(region1973,'country'));
      country1971.on('change',Lino.chooser_handler(city1984,'country'));
      region1973.on('change',Lino.chooser_handler(city1984,'region'));
      Lino.contacts.PartnersByCity.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "street", "editable": true, "editor": street1959, "filter": { "type": "string" }, "header": "T\u00e4nav", "sortable": true, "tooltip": "(contacts.PartnersByCity.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "street_no", "editable": true, "editor": street_no1960, "filter": { "type": "string" }, "header": "Nr.", "sortable": true, "tooltip": "(contacts.PartnersByCity.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 2, "dataIndex": "street_box", "editable": true, "editor": street_box1961, "filter": { "type": "string" }, "header": "Box", "sortable": true, "tooltip": "(contacts.PartnersByCity.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 3, "dataIndex": "addr2", "editable": true, "editor": addr21962, "filter": { "type": "string" }, "header": "Address line after street", "sortable": true, "tooltip": "(contacts.PartnersByCity.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "name", "editable": true, "editor": name1963, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(contacts.PartnersByCity.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "language", "editable": true, "editor": language1964, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(contacts.PartnersByCity.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id1965, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "email", "editable": true, "editor": email1966, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "url", "editable": true, "editor": url1967, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.url) ", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "phone", "editable": true, "editor": phone1968, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "gsm", "editable": true, "editor": gsm1969, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "fax", "editable": true, "editor": fax1970, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 12, "dataIndex": "country", "editable": true, "editor": country1971, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(contacts.PartnersByCity.country) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code1972, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 14, "dataIndex": "region", "editable": true, "editor": region1973, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.PartnersByCity.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr11974, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix1975, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCity.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "remarks", "editable": true, "editor": remarks1976, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.name_column) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 24, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCity.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "city", "editable": true, "editor": city1984, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.PartnersByCity.city) A pointer to Place.", "width": Lino.chars2width(21) } ];
    Lino.contacts.PartnersByCity.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnersByCity.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.PartnersByCity.insertPanel = Ext.extend(Lino.contacts.Partners.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/contacts/PartnersByCity",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.PartnersByCity.detail;
    this.ls_insert_handler = Lino.contacts.PartnersByCity.insert;
    Lino.contacts.PartnersByCity.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnersByCity.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.contacts.PartnersByCity.insertPanel(p);
});
Lino.contacts.PartnersByCity.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.PartnersByCity.detailPanel = Ext.extend(Lino.contacts.Partners.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/contacts/PartnersByCity",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.PartnersByCity.detail;
    this.ls_insert_handler = Lino.contacts.PartnersByCity.insert;
    Lino.contacts.PartnersByCity.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnersByCity.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.PartnersByCity.detailPanel(p);
});
Lino.contacts.PartnersByCity.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.contacts.Partners.ParamsPanel({});
  return new Lino.contacts.PartnersByCity.GridPanel(p);
});
Lino.contacts.PartnersByCity.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCity.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCity", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.PartnersByCountry
Lino.contacts.PartnersByCountry.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/PartnersByCountry",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/PartnersByCountry','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/PartnersByCountry','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Partnerid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 31,
  ls_store_fields : [ { "name": "city" }, 'cityHidden', { "name": "street" }, { "name": "street_no" }, { "name": "name" }, { "name": "language" }, 'languageHidden', { "name": "id", "type": "int" }, { "name": "email" }, { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "remarks" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "country" }, 'countryHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.PartnersByCountry.detail;
    this.ls_insert_handler = Lino.contacts.PartnersByCountry.insert;
    var ww = this.containing_window;
    var city6504 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/PartnersByCountry/city" }) }) });
    var street6505 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var street_no6506 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "maxLength": 10, "selectOnFocus": true });
    var name6507 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var language6508 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var id6509 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email6510 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var url6511 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone6512 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm6513 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax6514 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var zip_code6515 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region6516 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/PartnersByCountry/region" }) }) });
    var addr16517 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix6518 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_box6519 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr26520 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks6521 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var name_column_disp6522 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6523 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6524 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6525 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6526 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp6527 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp6528 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var country6529 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/PartnersByCountry/country" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      city6504.setContextValue('mk',bp['mk']);
      city6504.setContextValue('mt',bp['mt']);
      city6504.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      var bp = this.get_base_params();
      region6516.setContextValue('mk',bp['mk']);
      region6516.setContextValue('mt',bp['mt']);
      remarks6521.refresh();
    };
    this.onRender = function(ct, position) {
      country6529.on('change',Lino.chooser_handler(city6504,'country'));
      region6516.on('change',Lino.chooser_handler(city6504,'region'));
      country6529.on('change',Lino.chooser_handler(region6516,'country'));
      Lino.contacts.PartnersByCountry.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "city", "editable": true, "editor": city6504, "filter": { "type": "string" }, "header": "Linn", "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.PartnersByCountry.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "street", "editable": true, "editor": street6505, "filter": { "type": "string" }, "header": "T\u00e4nav", "sortable": true, "tooltip": "(contacts.PartnersByCountry.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "street_no", "editable": true, "editor": street_no6506, "filter": { "type": "string" }, "header": "Nr.", "sortable": true, "tooltip": "(contacts.PartnersByCountry.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 3, "dataIndex": "name", "editable": true, "editor": name6507, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(contacts.PartnersByCountry.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "language", "editable": true, "editor": language6508, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(contacts.PartnersByCountry.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6509, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "email", "editable": true, "editor": email6510, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url6511, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone6512, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "gsm", "editable": true, "editor": gsm6513, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "fax", "editable": true, "editor": fax6514, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "zip_code", "editable": true, "editor": zip_code6515, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 12, "dataIndex": "region", "editable": true, "editor": region6516, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.PartnersByCountry.region) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "addr1", "editable": true, "editor": addr16517, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix6518, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "street_box", "editable": true, "editor": street_box6519, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 16, "dataIndex": "addr2", "editable": true, "editor": addr26520, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(contacts.PartnersByCountry.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "remarks", "editable": true, "editor": remarks6521, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.name_column) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 24, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnersByCountry.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "country", "editable": true, "editor": country6529, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(contacts.PartnersByCountry.country) ", "width": Lino.chars2width(21) } ];
    Lino.contacts.PartnersByCountry.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnersByCountry.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.PartnersByCountry.insertPanel = Ext.extend(Lino.contacts.Partners.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/contacts/PartnersByCountry",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.PartnersByCountry.detail;
    this.ls_insert_handler = Lino.contacts.PartnersByCountry.insert;
    Lino.contacts.PartnersByCountry.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnersByCountry.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.contacts.PartnersByCountry.insertPanel(p);
});
Lino.contacts.PartnersByCountry.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.PartnersByCountry.detailPanel = Ext.extend(Lino.contacts.Partners.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/contacts/PartnersByCountry",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.PartnersByCountry.detail;
    this.ls_insert_handler = Lino.contacts.PartnersByCountry.insert;
    Lino.contacts.PartnersByCountry.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnersByCountry.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.PartnersByCountry.detailPanel(p);
});
Lino.contacts.PartnersByCountry.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.contacts.Partners.ParamsPanel({});
  return new Lino.contacts.PartnersByCountry.GridPanel(p);
});
Lino.contacts.PartnersByCountry.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnersByCountry.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnersByCountry", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class contacts.RolesByCompany
Lino.contacts.RolesByCompany.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/RolesByCompany",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/RolesByCompany','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/RolesByCompany','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Contact persons",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 12,
  ls_store_fields : [ { "name": "person" }, 'personHidden', { "name": "type" }, 'typeHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "company" }, 'companyHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 7,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var person1214 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/RolesByCompany/person" }) }) });
    var type1215 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/RolesByCompany/type" }) }) });
    var id1216 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp1217 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1218 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1219 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1220 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var company1221 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/RolesByCompany/company" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "person", "editable": true, "editor": person1214, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(contacts.RolesByCompany.person) The person having this role in this company.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type1215, "filter": { "type": "string" }, "header": "Contact Role", "sortable": false, "tooltip": "(contacts.RolesByCompany.type) The role of this person in this company.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id1216, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(contacts.RolesByCompany.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByCompany.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByCompany.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByCompany.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByCompany.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "company", "editable": true, "editor": company1221, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(contacts.RolesByCompany.company) The company where this person has a role.", "width": Lino.chars2width(21) } ];
    Lino.contacts.RolesByCompany.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.RolesByCompany.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByCompany", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByCompany.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByCompany", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByCompany.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByCompany", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByCompany.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByCompany", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByCompany.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByCompany", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByCompany.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByCompany", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByCompany.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.RolesByCompany.GridPanel(p);
});

// js_render_GridPanel_class contacts.RolesByPerson
Lino.contacts.RolesByPerson.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/RolesByPerson",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/RolesByPerson','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/RolesByPerson','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Contact for",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 12,
  ls_store_fields : [ { "name": "company" }, 'companyHidden', { "name": "type" }, 'typeHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "person" }, 'personHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 7,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var company501 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Organisatsioon...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/RolesByPerson/company" }) }) });
    var type502 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/RolesByPerson/type" }) }) });
    var id503 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp504 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp505 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp506 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp507 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var person508 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/RolesByPerson/person" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "company", "editable": true, "editor": company501, "filter": { "type": "string" }, "header": "Organisatsioon", "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(contacts.RolesByPerson.company) The company where this person has a role.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type502, "filter": { "type": "string" }, "header": "Contact Role", "sortable": false, "tooltip": "(contacts.RolesByPerson.type) The role of this person in this company.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id503, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(contacts.RolesByPerson.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByPerson.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByPerson.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByPerson.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.RolesByPerson.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "person", "editable": true, "editor": person508, "filter": { "type": "string" }, "header": "Inimene", "hidden": true, "renderer": Lino.fk_renderer('personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(contacts.RolesByPerson.person) The person having this role in this company.", "width": Lino.chars2width(21) } ];
    Lino.contacts.RolesByPerson.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.RolesByPerson.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByPerson", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByPerson.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByPerson", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByPerson.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByPerson", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByPerson.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByPerson", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByPerson.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByPerson", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByPerson.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/RolesByPerson", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.RolesByPerson.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.RolesByPerson.GridPanel(p);
});

// js_render_GridPanel_class contacts.CompaniesByCompany
Lino.contacts.CompaniesByCompany.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/contacts/CompaniesByCompany",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/CompaniesByCompany','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/CompaniesByCompany','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Organisatsioonid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 38,
  ls_store_fields : [ { "name": "name_column" }, { "name": "address_column" }, { "name": "email" }, { "name": "phone" }, { "name": "gsm" }, { "name": "id", "type": "int" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "prefix" }, { "name": "type" }, 'typeHidden', { "name": "private", "type": "boolean" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mti_navigator" }, { "name": "children_summary" }, { "name": "parent" }, 'parentHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.CompaniesByCompany.detail;
    this.ls_insert_handler = Lino.contacts.CompaniesByCompany.insert;
    var ww = this.containing_window;
    var name_column_disp1259 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var address_column_disp1260 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var email1261 = new Ext.form.TextField({ "maxLength": 254, "selectOnFocus": true });
    var phone1262 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var gsm1263 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id1264 = new Ext.form.NumberField({ "selectOnFocus": true });
    var language1265 = new Lino.ChoicesFieldElement({ "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url1266 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax1267 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country1268 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/CompaniesByCompany/country" }) }) });
    var city1269 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/CompaniesByCompany/city" }) }) });
    var zip_code1270 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region1271 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/CompaniesByCompany/region" }) }) });
    var addr11272 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix1273 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street1274 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no1275 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box1276 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr21277 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name1278 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks1279 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var prefix1280 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var type1281 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsiooniliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/CompaniesByCompany/type" }) }) });
    var private1282 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mobile_item_disp1283 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1284 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1285 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1286 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp1287 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp1288 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var parent1289 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/contacts/CompaniesByCompany/parent" }) }) });
    this.before_row_edit = function(record) {
      city1269.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1269.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region1271.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks1279.refresh();
    };
    this.onRender = function(ct, position) {
      country1268.on('change',Lino.chooser_handler(city1269,'country'));
      region1271.on('change',Lino.chooser_handler(city1269,'region'));
      country1268.on('change',Lino.chooser_handler(region1271,'country'));
      Lino.contacts.CompaniesByCompany.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name_column", "editable": false, "header": "Nimi", "sortable": false, "tooltip": "(contacts.CompaniesByCompany.name_column) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "address_column", "editable": false, "header": "Aadres", "sortable": false, "tooltip": "(contacts.CompaniesByCompany.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "email", "editable": true, "editor": email1261, "filter": { "type": "string" }, "header": "e-mail address", "sortable": true, "tooltip": "(contacts.CompaniesByCompany.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "phone", "editable": true, "editor": phone1262, "filter": { "type": "string" }, "header": "Phone", "sortable": true, "tooltip": "(contacts.CompaniesByCompany.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "gsm", "editable": true, "editor": gsm1263, "filter": { "type": "string" }, "header": "GSM", "sortable": true, "tooltip": "(contacts.CompaniesByCompany.gsm) The primary mobile phone number.", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id1264, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(contacts.CompaniesByCompany.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "language", "editable": true, "editor": language1265, "filter": { "type": "string" }, "header": "Keel", "sortable": false, "tooltip": "(contacts.CompaniesByCompany.language) The language to use when communicating with this partner.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "url", "editable": true, "editor": url1266, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "fax", "editable": true, "editor": fax1267, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "country", "editable": true, "editor": country1268, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(contacts.CompaniesByCompany.country) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "city", "editable": true, "editor": city1269, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.CompaniesByCompany.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "zip_code", "editable": true, "editor": zip_code1270, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 12, "dataIndex": "region", "editable": true, "editor": region1271, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(contacts.CompaniesByCompany.region) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "addr1", "editable": true, "editor": addr11272, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix1273, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "street", "editable": true, "editor": street1274, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "street_no", "editable": true, "editor": street_no1275, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 17, "dataIndex": "street_box", "editable": true, "editor": street_box1276, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "addr2", "editable": true, "editor": addr21277, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "name", "editable": true, "editor": name1278, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 20, "dataIndex": "remarks", "editable": true, "editor": remarks1279, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 21, "dataIndex": "prefix", "editable": true, "editor": prefix1280, "filter": { "type": "string" }, "header": "Name prefix", "hidden": true, "sortable": true, "tooltip": "(contacts.CompaniesByCompany.prefix) ", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "type", "editable": true, "editor": type1281, "filter": { "type": "string" }, "header": "Organisatsiooniliik", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.type) Pointer to the CompanyType.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(contacts.CompaniesByCompany.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "parent", "editable": true, "editor": parent1289, "filter": { "type": "string" }, "header": "Parent", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(contacts.CompaniesByCompany.parent) ", "width": Lino.chars2width(21) } ];
    Lino.contacts.CompaniesByCompany.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.CompaniesByCompany.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.CompaniesByCompany.insertPanel = Ext.extend(Lino.contacts.Companies.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/contacts/CompaniesByCompany",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.CompaniesByCompany.detail;
    this.ls_insert_handler = Lino.contacts.CompaniesByCompany.insert;
    Lino.contacts.CompaniesByCompany.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.CompaniesByCompany.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.contacts.CompaniesByCompany.insertPanel(p);
});
Lino.contacts.CompaniesByCompany.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.contacts.CompaniesByCompany.detailPanel = Ext.extend(Lino.contacts.Companies.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/contacts/CompaniesByCompany",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.contacts.CompaniesByCompany.detail;
    this.ls_insert_handler = Lino.contacts.CompaniesByCompany.insert;
    Lino.contacts.CompaniesByCompany.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.CompaniesByCompany.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.CompaniesByCompany.detailPanel(p);
});
Lino.contacts.CompaniesByCompany.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.contacts.Partners.ParamsPanel({});
  return new Lino.contacts.CompaniesByCompany.GridPanel(p);
});
Lino.contacts.CompaniesByCompany.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.CompaniesByCompany.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/CompaniesByCompany", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.SubscriptionsByUser
Lino.cal.SubscriptionsByUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/SubscriptionsByUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/SubscriptionsByUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/SubscriptionsByUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Subscriptions",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "calendar" }, 'calendarHidden', { "name": "is_hidden", "type": "boolean" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "user" }, 'userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 23,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id6531 = new Ext.form.NumberField({ "selectOnFocus": true });
    var calendar6532 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kalender...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/SubscriptionsByUser/calendar" }) }) });
    var is_hidden6533 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var mobile_item_disp6534 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6535 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6536 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6537 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var user6538 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/SubscriptionsByUser/user" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id6531, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.SubscriptionsByUser.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "calendar", "editable": true, "editor": calendar6532, "filter": { "type": "string" }, "header": "Kalender", "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.SubscriptionsByUser.calendar) The calendar you want to subscribe to.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "is_hidden", "editable": true, "filter": { "type": "boolean" }, "header": "hidden", "sortable": false, "tooltip": "(cal.SubscriptionsByUser.is_hidden) Whether this subscription should \"\n        \"initially be displayed as a hidden calendar.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByUser.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByUser.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByUser.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user6538, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.SubscriptionsByUser.user) ", "width": Lino.chars2width(21) } ];
    Lino.cal.SubscriptionsByUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.SubscriptionsByUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Subscriptions.ParamsPanel({});
  return new Lino.cal.SubscriptionsByUser.GridPanel(p);
});

// js_render_GridPanel_class cal.SubscriptionsByCalendar
Lino.cal.SubscriptionsByCalendar.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/SubscriptionsByCalendar",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/SubscriptionsByCalendar','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/SubscriptionsByCalendar','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Subscriptions",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "is_hidden", "type": "boolean" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "calendar" }, 'calendarHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 23,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id2484 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user2485 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/SubscriptionsByCalendar/user" }) }) });
    var is_hidden2486 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    var mobile_item_disp2487 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2488 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2489 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2490 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var calendar2491 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/SubscriptionsByCalendar/calendar" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id2484, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.SubscriptionsByCalendar.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user2485, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "is_hidden", "editable": true, "filter": { "type": "boolean" }, "header": "hidden", "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.is_hidden) Whether this subscription should \"\n        \"initially be displayed as a hidden calendar.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "calendar", "editable": true, "editor": calendar2491, "filter": { "type": "string" }, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.SubscriptionsByCalendar.calendar) The calendar you want to subscribe to.", "width": Lino.chars2width(21) } ];
    Lino.cal.SubscriptionsByCalendar.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.SubscriptionsByCalendar.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByCalendar", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByCalendar.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByCalendar", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByCalendar.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByCalendar", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByCalendar.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByCalendar", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByCalendar.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByCalendar", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByCalendar.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/SubscriptionsByCalendar", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.SubscriptionsByCalendar.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Subscriptions.ParamsPanel({});
  return new Lino.cal.SubscriptionsByCalendar.GridPanel(p);
});

// js_render_GridPanel_class cal.TasksByUser
Lino.cal.TasksByUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/TasksByUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/TasksByUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/TasksByUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Tasks",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 29,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "start_time" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "due_date", "type": "date" }, { "name": "due_time" }, { "name": "percent", "type": "int", "useNull": true }, { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "user" }, 'userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 12,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.TasksByUser.detail;
    this.ls_insert_handler = Lino.cal.TasksByUser.insert;
    var ww = this.containing_window;
    var start_date6540 = new Lino.DateField({ "selectOnFocus": true });
    var summary6541 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp6542 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id6543 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified6544 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created6545 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_time6546 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var owner_type6547 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/TasksByUser/owner_type" }) }) });
    var owner_id6548 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/TasksByUser/owner_id" }) }) });
    var description6549 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class6550 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence6551 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type6552 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var due_date6553 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var due_time6554 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var percent6555 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var state6556 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.TaskStates });
    var owner_disp6557 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp6558 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6559 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6560 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp6561 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var user6562 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/TasksByUser/user" }) }) });
    this.before_row_edit = function(record) {
      owner_id6548.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type6547.on('change',Lino.chooser_handler(owner_id6548,'owner_type'));
      Lino.cal.TasksByUser.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6540, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.TasksByUser.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary6541, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.TasksByUser.summary) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.TasksByUser.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id6543, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "start_time", "editable": true, "editor": start_time6546, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 7, "dataIndex": "owner_type", "editable": true, "editor": owner_type6547, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.TasksByUser.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_id", "editable": true, "editor": owner_id6548, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "description", "editable": true, "editor": description6549, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.description) ", "width": Lino.chars2width(61) }, { "colIndex": 10, "dataIndex": "access_class", "editable": true, "editor": access_class6550, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 11, "dataIndex": "sequence", "editable": true, "editor": sequence6551, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 12, "dataIndex": "auto_type", "editable": true, "editor": auto_type6552, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "due_date", "editable": true, "editor": due_date6553, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Due date", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.due_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 14, "dataIndex": "due_time", "editable": true, "editor": due_time6554, "header": "Due time", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.due_time) ", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 15, "dataIndex": "percent", "editable": true, "editor": percent6555, "filter": { "type": "numeric" }, "format": "0", "header": "Duration value", "hidden": true, "sortable": true, "tooltip": "(cal.TasksByUser.percent) ", "width": Lino.chars2width(6) }, { "colIndex": 16, "dataIndex": "state", "editable": true, "editor": state6556, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.state) The state of this Task. one of TaskStates.", "width": Lino.chars2width(13) }, { "colIndex": 17, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.TasksByUser.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "user", "editable": true, "editor": user6562, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.TasksByUser.user) ", "width": Lino.chars2width(21) } ];
    Lino.cal.TasksByUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TasksByUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.TasksByUser.insertPanel = Ext.extend(Lino.cal.Tasks.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/TasksByUser",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.TasksByUser.detail;
    this.ls_insert_handler = Lino.cal.TasksByUser.insert;
    Lino.cal.TasksByUser.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TasksByUser.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.TasksByUser.insertPanel(p);
});
Lino.cal.TasksByUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.TasksByUser.detailPanel = Ext.extend(Lino.cal.Tasks.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/TasksByUser",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.TasksByUser.detail;
    this.ls_insert_handler = Lino.cal.TasksByUser.insert;
    Lino.cal.TasksByUser.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TasksByUser.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.TasksByUser.detailPanel(p);
});
Lino.cal.TasksByUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Tasks.ParamsPanel({});
  return new Lino.cal.TasksByUser.GridPanel(p);
});
Lino.cal.TasksByUser.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByUser.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByUser", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.GuestsByEvent
Lino.cal.GuestsByEvent.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/GuestsByEvent",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/GuestsByEvent','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/GuestsByEvent','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Kohalolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByEvent.detail;
    this.ls_insert_handler = Lino.cal.GuestsByEvent.insert;
    var ww = this.containing_window;
    var partner2466 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/GuestsByEvent/partner" }) }) });
    var role2467 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/GuestsByEvent/role" }) }) });
    var workflow_buttons_disp2468 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner2466, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(cal.GuestsByEvent.partner) The partner to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "role", "editable": true, "editor": role2467, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.GuestsByEvent.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.GuestsByEvent.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.GuestsByEvent.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByEvent.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestsByEvent.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/GuestsByEvent",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByEvent.detail;
    this.ls_insert_handler = Lino.cal.GuestsByEvent.insert;
    Lino.cal.GuestsByEvent.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByEvent.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.GuestsByEvent.insertPanel(p);
});
Lino.cal.GuestsByEvent.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestsByEvent.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/GuestsByEvent",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByEvent.detail;
    this.ls_insert_handler = Lino.cal.GuestsByEvent.insert;
    Lino.cal.GuestsByEvent.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByEvent.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.GuestsByEvent.detailPanel(p);
});
Lino.cal.GuestsByEvent.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.GuestsByEvent.GridPanel(p);
});
Lino.cal.GuestsByEvent.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByEvent.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByEvent", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.GuestsByRole
Lino.cal.GuestsByRole.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/GuestsByRole",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/GuestsByRole','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/GuestsByRole','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Kohalolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "role" }, 'roleHidden', { "name": "workflow_buttons" }, { "name": "remark" }, { "name": "event" }, 'eventHidden', { "name": "id", "type": "int" }, { "name": "state" }, 'stateHidden', { "name": "event_summary" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByRole.detail;
    this.ls_insert_handler = Lino.cal.GuestsByRole.insert;
    var ww = this.containing_window;
    var partner1512 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/GuestsByRole/partner" }) }) });
    var role1513 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/GuestsByRole/role" }) }) });
    var workflow_buttons_disp1514 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var remark1515 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event1516 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni event...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/GuestsByRole/event" }) }) });
    var id1517 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var state1518 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var event_summary_disp1519 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp1520 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1521 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1522 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner1512, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(cal.GuestsByRole.partner) The partner to which this presence applies.", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "role", "editable": true, "editor": role1513, "filter": { "type": "string" }, "header": "Role", "renderer": Lino.fk_renderer('roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(cal.GuestsByRole.role) The role of this partner in this presence.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.GuestsByRole.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark1515, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(cal.GuestsByRole.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "event", "editable": true, "editor": event1516, "filter": { "type": "string" }, "header": "event", "renderer": Lino.fk_renderer('eventHidden','Lino.cal.OneEvent.detail'), "sortable": false, "tooltip": "(cal.GuestsByRole.event) The calendar event to which this presence applies.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id1517, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.GuestsByRole.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "state", "editable": true, "editor": state1518, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.GuestsByRole.state) The state of this presence.", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "event_summary", "editable": false, "header": "Event", "hidden": true, "sortable": false, "tooltip": "(cal.GuestsByRole.event_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.GuestsByRole.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.GuestsByRole.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.GuestsByRole.overview) ", "width": Lino.chars2width(31) } ];
    Lino.cal.GuestsByRole.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByRole.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestsByRole.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/GuestsByRole",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByRole.detail;
    this.ls_insert_handler = Lino.cal.GuestsByRole.insert;
    Lino.cal.GuestsByRole.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByRole.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.GuestsByRole.insertPanel(p);
});
Lino.cal.GuestsByRole.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestsByRole.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/GuestsByRole",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByRole.detail;
    this.ls_insert_handler = Lino.cal.GuestsByRole.insert;
    Lino.cal.GuestsByRole.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByRole.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.GuestsByRole.detailPanel(p);
});
Lino.cal.GuestsByRole.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.GuestsByRole.GridPanel(p);
});
Lino.cal.GuestsByRole.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByRole.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByRole", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.GuestsByPartner
Lino.cal.GuestsByPartner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/GuestsByPartner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/GuestsByPartner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/GuestsByPartner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Kohalolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "event__when_text" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByPartner.detail;
    this.ls_insert_handler = Lino.cal.GuestsByPartner.insert;
    var ww = this.containing_window;
    var event__when_text_disp6564 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "sortable": false, "value": "<br/>" });
    var workflow_buttons_disp6565 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "event__when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.GuestsByPartner.event__when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.GuestsByPartner.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.cal.GuestsByPartner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByPartner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestsByPartner.insertPanel = Ext.extend(Lino.cal.Guests.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/GuestsByPartner",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByPartner.detail;
    this.ls_insert_handler = Lino.cal.GuestsByPartner.insert;
    Lino.cal.GuestsByPartner.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByPartner.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.GuestsByPartner.insertPanel(p);
});
Lino.cal.GuestsByPartner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.GuestsByPartner.detailPanel = Ext.extend(Lino.cal.Guests.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/GuestsByPartner",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.GuestsByPartner.detail;
    this.ls_insert_handler = Lino.cal.GuestsByPartner.insert;
    Lino.cal.GuestsByPartner.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestsByPartner.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.GuestsByPartner.detailPanel(p);
});
Lino.cal.GuestsByPartner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Guests.ParamsPanel({});
  return new Lino.cal.GuestsByPartner.GridPanel(p);
});
Lino.cal.GuestsByPartner.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestsByPartner.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestsByPartner", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.EntriesByType
Lino.cal.EntriesByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/EntriesByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_text" }, { "name": "user" }, 'userHidden', { "name": "summary" }, { "name": "event_type" }, 'event_typeHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByType.detail;
    this.ls_insert_handler = Lino.cal.EntriesByType.insert;
    var ww = this.containing_window;
    var when_text_disp2387 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user2388 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/user" }) }) });
    var summary2389 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event_type2390 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/event_type" }) }) });
    var id2391 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified2392 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2393 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date2394 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time2395 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date2396 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time2397 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time2398 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method2399 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company2400 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/company" }) }) });
    var contact_person2401 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/contact_person" }) }) });
    var contact_role2402 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/contact_role" }) }) });
    var assigned_to2403 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/assigned_to" }) }) });
    var owner_type2404 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/owner_type" }) }) });
    var owner_id2405 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/owner_id" }) }) });
    var description2406 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class2407 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence2408 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type2409 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent2410 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room2411 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/room" }) }) });
    var priority2412 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByType/priority" }) }) });
    var state2413 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp2414 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar2415 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp2416 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp2417 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day2418 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp2419 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2420 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2421 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2422 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2423 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp2424 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration2425 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person2401.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id2405.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company2400.on('change',Lino.chooser_handler(contact_person2401,'company'));
      owner_type2404.on('change',Lino.chooser_handler(owner_id2405,'owner_type'));
      Lino.cal.EntriesByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.EntriesByType.when_text) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user2388, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "summary", "editable": true, "editor": summary2389, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.EntriesByType.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "event_type", "editable": true, "editor": event_type2390, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id2391, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.EntriesByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date2394, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time2395, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date2396, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time2397, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 12, "dataIndex": "build_method", "editable": true, "editor": build_method2399, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 13, "dataIndex": "company", "editable": true, "editor": company2400, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_person", "editable": true, "editor": contact_person2401, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "contact_role", "editable": true, "editor": contact_role2402, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to2403, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type2404, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id2405, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description2406, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class2407, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence2408, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type2409, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByType.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "room", "editable": true, "editor": room2411, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.room) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "priority", "editable": true, "editor": priority2412, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state2413, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 27, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.EntriesByType.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 32, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.url) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByType.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.EntriesByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByType.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/EntriesByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByType.detail;
    this.ls_insert_handler = Lino.cal.EntriesByType.insert;
    Lino.cal.EntriesByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByType.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.EntriesByType.insertPanel(p);
});
Lino.cal.EntriesByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByType.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/EntriesByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByType.detail;
    this.ls_insert_handler = Lino.cal.EntriesByType.insert;
    Lino.cal.EntriesByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByType.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EntriesByType.detailPanel(p);
});
Lino.cal.EntriesByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.EntriesByType.GridPanel(p);
});
Lino.cal.EntriesByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByType.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByType", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.ConflictingEvents
Lino.cal.ConflictingEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/ConflictingEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/ConflictingEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/ConflictingEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "\u00a0\u2694\u00a0",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "name": "end_time" }, { "name": "room" }, 'roomHidden', { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "summary" }, { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "event_type" }, 'event_typeHidden', { "name": "transparent", "type": "boolean" }, { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.ConflictingEvents.detail;
    this.ls_insert_handler = Lino.cal.ConflictingEvents.insert;
    var ww = this.containing_window;
    var start_date6567 = new Lino.DateField({ "selectOnFocus": true });
    var start_time6568 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time6569 = new Lino.TimeField({ "selectOnFocus": true });
    var room6570 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/room" }) }) });
    var user6571 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/user" }) }) });
    var id6572 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified6573 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created6574 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var end_date6575 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var build_time6576 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method6577 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company6578 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/company" }) }) });
    var contact_person6579 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/contact_person" }) }) });
    var contact_role6580 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/contact_role" }) }) });
    var assigned_to6581 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/assigned_to" }) }) });
    var owner_type6582 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/owner_type" }) }) });
    var owner_id6583 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/owner_id" }) }) });
    var summary6584 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description6585 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class6586 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence6587 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type6588 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event_type6589 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/event_type" }) }) });
    var transparent6590 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority6591 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/ConflictingEvents/priority" }) }) });
    var state6592 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp6593 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar6594 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp6595 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp6596 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp6597 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day6598 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp6599 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6600 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6601 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6602 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6603 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp6604 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6605 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person6579.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id6583.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company6578.on('change',Lino.chooser_handler(contact_person6579,'company'));
      owner_type6582.on('change',Lino.chooser_handler(owner_id6583,'owner_type'));
      Lino.cal.ConflictingEvents.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6567, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.ConflictingEvents.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "start_time", "editable": true, "editor": start_time6568, "header": "Start time", "sortable": true, "tooltip": "(cal.ConflictingEvents.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "end_time", "editable": true, "editor": end_time6569, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(cal.ConflictingEvents.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 3, "dataIndex": "room", "editable": true, "editor": room6570, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.room) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "user", "editable": true, "editor": user6571, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.user) The responsible user.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6572, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date6575, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 10, "dataIndex": "build_method", "editable": true, "editor": build_method6577, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 11, "dataIndex": "company", "editable": true, "editor": company6578, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "contact_person", "editable": true, "editor": contact_person6579, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_role", "editable": true, "editor": contact_role6580, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to6581, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "owner_type", "editable": true, "editor": owner_type6582, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "owner_id", "editable": true, "editor": owner_id6583, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 17, "dataIndex": "summary", "editable": true, "editor": summary6584, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "description", "editable": true, "editor": description6585, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 19, "dataIndex": "access_class", "editable": true, "editor": access_class6586, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 20, "dataIndex": "sequence", "editable": true, "editor": sequence6587, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 21, "dataIndex": "auto_type", "editable": true, "editor": auto_type6588, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.ConflictingEvents.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 22, "dataIndex": "event_type", "editable": true, "editor": event_type6589, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "priority", "editable": true, "editor": priority6591, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "state", "editable": true, "editor": state6592, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 26, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 27, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.ConflictingEvents.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 28, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 32, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.url) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 38, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.ConflictingEvents.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.ConflictingEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.ConflictingEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.ConflictingEvents.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/ConflictingEvents",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.ConflictingEvents.detail;
    this.ls_insert_handler = Lino.cal.ConflictingEvents.insert;
    Lino.cal.ConflictingEvents.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.ConflictingEvents.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.ConflictingEvents.insertPanel(p);
});
Lino.cal.ConflictingEvents.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.ConflictingEvents.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/ConflictingEvents",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.ConflictingEvents.detail;
    this.ls_insert_handler = Lino.cal.ConflictingEvents.insert;
    Lino.cal.ConflictingEvents.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.ConflictingEvents.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.ConflictingEvents.detailPanel(p);
});
Lino.cal.ConflictingEvents.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.ConflictingEvents.GridPanel(p);
});
Lino.cal.ConflictingEvents.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.ConflictingEvents.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/ConflictingEvents", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.EntriesByRoom
Lino.cal.EntriesByRoom.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/EntriesByRoom",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByRoom','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByRoom','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_text" }, { "name": "user" }, 'userHidden', { "name": "summary" }, { "name": "event_type" }, 'event_typeHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "transparent", "type": "boolean" }, { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "owner" }, { "name": "calendar" }, 'calendarHidden', { "name": "when_html" }, { "name": "reminder" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "room" }, 'roomHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByRoom.detail;
    this.ls_insert_handler = Lino.cal.EntriesByRoom.insert;
    var ww = this.containing_window;
    var when_text_disp2879 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var user2880 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/user" }) }) });
    var summary2881 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var event_type2882 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/event_type" }) }) });
    var id2883 = new Ext.form.NumberField({ "selectOnFocus": true });
    var modified2884 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2885 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date2886 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time2887 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date2888 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time2889 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time2890 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method2891 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company2892 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/company" }) }) });
    var contact_person2893 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/contact_person" }) }) });
    var contact_role2894 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/contact_role" }) }) });
    var assigned_to2895 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/assigned_to" }) }) });
    var owner_type2896 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/owner_type" }) }) });
    var owner_id2897 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/owner_id" }) }) });
    var description2898 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class2899 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence2900 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type2901 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent2902 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority2903 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/priority" }) }) });
    var state2904 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp2905 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar2906 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp2907 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp2908 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day2909 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp2910 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2911 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2912 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2913 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2914 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp2915 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration2916 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    var room2917 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByRoom/room" }) }) });
    this.before_row_edit = function(record) {
      contact_person2893.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id2897.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company2892.on('change',Lino.chooser_handler(contact_person2893,'company'));
      owner_type2896.on('change',Lino.chooser_handler(owner_id2897,'owner_type'));
      Lino.cal.EntriesByRoom.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.EntriesByRoom.when_text) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user2880, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "summary", "editable": true, "editor": summary2881, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.EntriesByRoom.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "event_type", "editable": true, "editor": event_type2882, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id2883, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.EntriesByRoom.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date2886, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time2887, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date2888, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time2889, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 12, "dataIndex": "build_method", "editable": true, "editor": build_method2891, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 13, "dataIndex": "company", "editable": true, "editor": company2892, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_person", "editable": true, "editor": contact_person2893, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "contact_role", "editable": true, "editor": contact_role2894, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to2895, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type2896, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id2897, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description2898, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class2899, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence2900, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type2901, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByRoom.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "priority", "editable": true, "editor": priority2903, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "state", "editable": true, "editor": state2904, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 26, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 27, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 28, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 31, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.url) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByRoom.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 38, "dataIndex": "room", "editable": true, "editor": room2917, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.EntriesByRoom.room) ", "width": Lino.chars2width(21) } ];
    Lino.cal.EntriesByRoom.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByRoom.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByRoom.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/EntriesByRoom",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByRoom.detail;
    this.ls_insert_handler = Lino.cal.EntriesByRoom.insert;
    Lino.cal.EntriesByRoom.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByRoom.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.EntriesByRoom.insertPanel(p);
});
Lino.cal.EntriesByRoom.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByRoom.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/EntriesByRoom",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByRoom.detail;
    this.ls_insert_handler = Lino.cal.EntriesByRoom.insert;
    Lino.cal.EntriesByRoom.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByRoom.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EntriesByRoom.detailPanel(p);
});
Lino.cal.EntriesByRoom.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.EntriesByRoom.GridPanel(p);
});
Lino.cal.EntriesByRoom.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByRoom.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByRoom", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class addresses.AddressesByPartner
Lino.addresses.AddressesByPartner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/addresses/AddressesByPartner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/addresses/AddressesByPartner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/addresses/AddressesByPartner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Aadressid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "address_type" }, 'address_typeHidden', { "name": "remark" }, { "name": "address_column" }, { "name": "primary", "type": "boolean" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 24,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.addresses.AddressesByPartner.detail;
    this.ls_insert_handler = Lino.addresses.AddressesByPartner.insert;
    var ww = this.containing_window;
    var address_type6607 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.addresses.AddressTypes });
    var remark6608 = new Ext.form.TextField({ "maxLength": 50, "selectOnFocus": true });
    var address_column_disp6609 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var primary6610 = new Ext.form.Checkbox({ "checked": false, "selectOnFocus": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "address_type", "editable": true, "editor": address_type6607, "filter": { "type": "string" }, "header": "Aadressiliik", "sortable": false, "tooltip": "(addresses.AddressesByPartner.address_type) ", "width": Lino.chars2width(11) }, { "colIndex": 1, "dataIndex": "remark", "editable": true, "editor": remark6608, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(addresses.AddressesByPartner.remark) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "address_column", "editable": false, "header": "Aadres", "sortable": false, "tooltip": "(addresses.AddressesByPartner.address_column) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "primary", "editable": true, "filter": { "type": "boolean" }, "header": "Primary", "sortable": false, "tooltip": "(addresses.AddressesByPartner.primary) Checking this field will automatically uncheck any previous primary addresses and update the partner's address data fields.", "width": Lino.chars2width(6), "xtype": "checkcolumn" } ];
    Lino.addresses.AddressesByPartner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.AddressesByPartner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressesByPartner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressesByPartner.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.addresses.AddressesByPartner.insertPanel = Ext.extend(Lino.addresses.Addresses.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/addresses/AddressesByPartner",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.addresses.AddressesByPartner.detail;
    this.ls_insert_handler = Lino.addresses.AddressesByPartner.insert;
    Lino.addresses.AddressesByPartner.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.AddressesByPartner.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.addresses.AddressesByPartner.insertPanel(p);
});
Lino.addresses.AddressesByPartner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressesByPartner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressesByPartner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.addresses.AddressesByPartner.detailPanel = Ext.extend(Lino.addresses.Addresses.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/addresses/AddressesByPartner",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.addresses.AddressesByPartner.detail;
    this.ls_insert_handler = Lino.addresses.AddressesByPartner.insert;
    Lino.addresses.AddressesByPartner.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.AddressesByPartner.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "is_main_window": true };
  return new Lino.addresses.AddressesByPartner.detailPanel(p);
});
Lino.addresses.AddressesByPartner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressesByPartner.grid = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.addresses.AddressesByPartner.GridPanel(p);
});
Lino.addresses.AddressesByPartner.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressesByPartner", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class topics.TopicsByGroup
Lino.topics.TopicsByGroup.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/TopicsByGroup",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/TopicsByGroup','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/TopicsByGroup','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Teemad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "name_et" }, { "name": "topic_group" }, 'topic_groupHidden', { "name": "id", "type": "int" }, { "name": "description" }, { "name": "description_et" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 31,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.TopicsByGroup.detail;
    this.ls_insert_handler = Lino.topics.TopicsByGroup.insert;
    var ww = this.containing_window;
    var ref721 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name722 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et723 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var topic_group724 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Topic group...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/TopicsByGroup/topic_group" }) }) });
    var id725 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var description726 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Long description" });
    var description_et727 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Long description (et)" });
    var mobile_item_disp728 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp729 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp730 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp731 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description726.refresh();
      description_et727.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref721, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(topics.TopicsByGroup.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name722, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(topics.TopicsByGroup.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et723, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(topics.TopicsByGroup.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "topic_group", "editable": true, "editor": topic_group724, "filter": { "type": "string" }, "header": "Topic group", "renderer": Lino.fk_renderer('topic_groupHidden','Lino.topics.TopicGroups.detail'), "sortable": false, "tooltip": "(topics.TopicsByGroup.topic_group) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id725, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.TopicsByGroup.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "description", "editable": true, "editor": description726, "filter": { "type": "string" }, "header": "Long description", "hidden": true, "sortable": false, "tooltip": "(topics.TopicsByGroup.description) ", "width": Lino.chars2width(61) }, { "colIndex": 6, "dataIndex": "description_et", "editable": true, "editor": description_et727, "filter": { "type": "string" }, "header": "Long description (et)", "hidden": true, "sortable": false, "tooltip": "(topics.TopicsByGroup.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.TopicsByGroup.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.TopicsByGroup.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.TopicsByGroup.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.TopicsByGroup.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.topics.TopicsByGroup.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.TopicsByGroup.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicsByGroup.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicsByGroup.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.TopicsByGroup.insertPanel = Ext.extend(Lino.topics.Topics.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/topics/TopicsByGroup",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.TopicsByGroup.detail;
    this.ls_insert_handler = Lino.topics.TopicsByGroup.insert;
    Lino.topics.TopicsByGroup.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.TopicsByGroup.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.topics.TopicsByGroup.insertPanel(p);
});
Lino.topics.TopicsByGroup.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicsByGroup.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicsByGroup.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.topics.TopicsByGroup.detailPanel = Ext.extend(Lino.topics.Topics.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/topics/TopicsByGroup",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.topics.TopicsByGroup.detail;
    this.ls_insert_handler = Lino.topics.TopicsByGroup.insert;
    Lino.topics.TopicsByGroup.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.TopicsByGroup.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.TopicsByGroup.detailPanel(p);
});
Lino.topics.TopicsByGroup.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.TopicsByGroup.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.TopicsByGroup.GridPanel(p);
});
Lino.topics.TopicsByGroup.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/TopicsByGroup", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class topics.InterestsByPartner
Lino.topics.InterestsByPartner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/InterestsByPartner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/InterestsByPartner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/InterestsByPartner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Interests",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "topic" }, 'topicHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "partner" }, 'partnerHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 32,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var topic6612 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/InterestsByPartner/topic" }) }) });
    var id6613 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp6614 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6615 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6616 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6617 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var partner6618 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/InterestsByPartner/partner" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "topic", "editable": true, "editor": topic6612, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(topics.InterestsByPartner.topic) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 1, "dataIndex": "id", "editable": true, "editor": id6613, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.InterestsByPartner.id) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByPartner.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByPartner.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByPartner.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByPartner.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "partner", "editable": true, "editor": partner6618, "filter": { "type": "string" }, "header": "Partner", "hidden": true, "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(topics.InterestsByPartner.partner) ", "width": Lino.chars2width(21) } ];
    Lino.topics.InterestsByPartner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.InterestsByPartner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByPartner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByPartner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByPartner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByPartner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByPartner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByPartner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByPartner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByPartner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByPartner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByPartner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByPartner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByPartner.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.InterestsByPartner.GridPanel(p);
});

// js_render_GridPanel_class topics.InterestsByTopic
Lino.topics.InterestsByTopic.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/topics/InterestsByTopic",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/topics/InterestsByTopic','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/topics/InterestsByTopic','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Interests",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "topic" }, 'topicHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 32,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var partner747 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/InterestsByTopic/partner" }) }) });
    var id748 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp749 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp750 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp751 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp752 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var topic753 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/topics/InterestsByTopic/topic" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner747, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(topics.InterestsByTopic.partner) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 1, "dataIndex": "id", "editable": true, "editor": id748, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(topics.InterestsByTopic.id) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByTopic.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByTopic.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByTopic.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(topics.InterestsByTopic.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "topic", "editable": true, "editor": topic753, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(topics.InterestsByTopic.topic) ", "width": Lino.chars2width(21) } ];
    Lino.topics.InterestsByTopic.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.topics.InterestsByTopic.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByTopic", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByTopic.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByTopic", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByTopic.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByTopic", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByTopic.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByTopic", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByTopic.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByTopic", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByTopic.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/topics/InterestsByTopic", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.topics.InterestsByTopic.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.topics.InterestsByTopic.GridPanel(p);
});

// js_render_GridPanel_class excerpts.ExcerptsByType
Lino.excerpts.ExcerptsByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/excerpts/ExcerptsByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/ExcerptsByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/ExcerptsByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  cell_edit : true,
  title : "V\u00e4ljav\u00f5ted",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "name": "build_time" }, { "name": "owner" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "language" }, 'languageHidden', { "name": "body_template_content" }, { "name": "preview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "excerpt_type" }, 'excerpt_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 37,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptsByType.detail;
    var ww = this.containing_window;
    var build_time2104 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var owner_disp2105 = new Ext.form.DisplayField({ "disabled": true });
    var user2106 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/user" }) }) });
    var id2107 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var build_method2108 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company2109 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/company" }) }) });
    var contact_person2110 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/contact_person" }) }) });
    var contact_role2111 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/contact_role" }) }) });
    var owner_type2112 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/owner_type" }) }) });
    var owner_id2113 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/owner_id" }) }) });
    var language2114 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var body_template_content2115 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body template" });
    var preview_htmlbox2116 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "preview", "title": "Eelvaade", "value": "<br/>" });
    var mobile_item_disp2117 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2118 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2119 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2120 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var excerpt_type2121 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByType/excerpt_type" }) }) });
    this.before_row_edit = function(record) {
      contact_person2110.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id2113.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body_template_content2115.refresh();
      preview_htmlbox2116.refresh();
      excerpt_type2121.setContextValue('owner', record ? record.data['owner'] : undefined);
    };
    this.onRender = function(ct, position) {
      company2109.on('change',Lino.chooser_handler(contact_person2110,'company'));
      owner_type2112.on('change',Lino.chooser_handler(owner_id2113,'owner_type'));
      owner_disp2105.on('change',Lino.chooser_handler(excerpt_type2121,'owner'));
      Lino.excerpts.ExcerptsByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "build_time", "editable": false, "header": "build time", "sortable": true, "tooltip": "(excerpts.ExcerptsByType.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(excerpts.ExcerptsByType.owner) The object being printed by this excerpt.\nSee Controllable.owner.", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user2106, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByType.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id2107, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(excerpts.ExcerptsByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "build_method", "editable": true, "editor": build_method2108, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 5, "dataIndex": "company", "editable": true, "editor": company2109, "filter": { "type": "string" }, "header": "Saaja (Firma)", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByType.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "contact_person", "editable": true, "editor": contact_person2110, "filter": { "type": "string" }, "header": "Saaja (Isik)", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByType.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "contact_role", "editable": true, "editor": contact_role2111, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_type", "editable": true, "editor": owner_type2112, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByType.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner_id", "editable": true, "editor": owner_id2113, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "language", "editable": true, "editor": language2114, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.language) The language used for printing this excerpt.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "body_template_content", "editable": false, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.body_template_content) ", "width": Lino.chars2width(61) }, { "colIndex": 12, "dataIndex": "preview", "editable": false, "header": "Eelvaade", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.preview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "excerpt_type", "editable": true, "editor": excerpt_type2121, "filter": { "type": "string" }, "header": "V\u00e4ljav\u00f5teliik", "hidden": true, "renderer": Lino.fk_renderer('excerpt_typeHidden','Lino.excerpts.ExcerptTypes.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByType.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).", "width": Lino.chars2width(21) } ];
    Lino.excerpts.ExcerptsByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptsByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.ExcerptsByType.detailPanel = Ext.extend(Lino.excerpts.Excerpts.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  ls_url: "/excerpts/ExcerptsByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptsByType.detail;
    Lino.excerpts.ExcerptsByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptsByType.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.ExcerptsByType.detailPanel(p);
});
Lino.excerpts.ExcerptsByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.excerpts.Excerpts.ParamsPanel({});
  return new Lino.excerpts.ExcerptsByType.GridPanel(p);
});
Lino.excerpts.ExcerptsByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByType.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByType", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class comments.CommentsByType
Lino.comments.CommentsByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/CommentsByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/CommentsByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/CommentsByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "short_text" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "owner" }, { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByType.detail;
    this.ls_insert_handler = Lino.comments.CommentsByType.insert;
    var ww = this.containing_window;
    var short_text6620 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var created6621 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var user6622 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var id6623 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified6624 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var owner_type6625 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByType/owner_type" }) }) });
    var owner_id6626 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByType/owner_id" }) }) });
    var reply_to6627 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByType/reply_to" }) }) });
    var more_text6628 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "More text" });
    var owner_disp6629 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var created_natural_disp6630 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6631 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6632 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6633 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6634 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var comment_type6635 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByType/comment_type" }) }) });
    this.before_row_edit = function(record) {
      short_text6620.refresh();
      owner_id6626.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      more_text6628.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type6625.on('change',Lino.chooser_handler(owner_id6626,'owner_type'));
      Lino.comments.CommentsByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "short_text", "editable": true, "editor": short_text6620, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.CommentsByType.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 1, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(comments.CommentsByType.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.CommentsByType.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id6623, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(comments.CommentsByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(comments.CommentsByType.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type6625, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.CommentsByType.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id6626, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "reply_to", "editable": true, "editor": reply_to6627, "filter": { "type": "string" }, "header": "Reply to", "hidden": true, "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.CommentsByType.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "more_text", "editable": true, "editor": more_text6628, "filter": { "type": "string" }, "header": "More text", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "comment_type", "editable": true, "editor": comment_type6635, "filter": { "type": "string" }, "header": "Comment Type", "hidden": true, "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.CommentsByType.comment_type) ", "width": Lino.chars2width(21) } ];
    Lino.comments.CommentsByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentsByType.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/CommentsByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByType.detail;
    this.ls_insert_handler = Lino.comments.CommentsByType.insert;
    Lino.comments.CommentsByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByType.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.CommentsByType.insertPanel(p);
});
Lino.comments.CommentsByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentsByType.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/CommentsByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByType.detail;
    this.ls_insert_handler = Lino.comments.CommentsByType.insert;
    Lino.comments.CommentsByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByType.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.CommentsByType.detailPanel(p);
});
Lino.comments.CommentsByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.CommentsByType.GridPanel(p);
});
Lino.comments.CommentsByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.ProjectsByParent
Lino.tickets.ProjectsByParent.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/ProjectsByParent",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByParent','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByParent','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Subprojects",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "children_summary" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "private", "type": "boolean" }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "parent" }, 'parentHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByParent.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByParent.insert;
    var ww = this.containing_window;
    var ref1426 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name1427 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var children_summary_disp1428 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id1429 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date1430 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date1431 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var company1432 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByParent/company" }) }) });
    var contact_person1433 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByParent/contact_person" }) }) });
    var contact_role1434 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByParent/contact_role" }) }) });
    var private1435 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var closed1436 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time1437 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to1438 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByParent/assign_to" }) }) });
    var type1439 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByParent/type" }) }) });
    var description1440 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template1441 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template1442 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type1443 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp1444 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp1445 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1446 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1447 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1448 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var parent1449 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByParent/parent" }) }) });
    this.before_row_edit = function(record) {
      contact_person1433.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description1440.refresh();
    };
    this.onRender = function(ct, position) {
      company1432.on('change',Lino.chooser_handler(contact_person1433,'company'));
      Lino.tickets.ProjectsByParent.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref1426, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.ProjectsByParent.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name1427, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.ProjectsByParent.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "children_summary", "editable": false, "header": "Children", "sortable": false, "tooltip": "(tickets.ProjectsByParent.children_summary) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id1429, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByParent.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "start_date", "editable": true, "editor": start_date1430, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByParent.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date1431, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByParent.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "company", "editable": true, "editor": company1432, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByParent.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "contact_person", "editable": true, "editor": contact_person1433, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByParent.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_role", "editable": true, "editor": contact_role1434, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time1437, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByParent.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "assign_to", "editable": true, "editor": assign_to1438, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByParent.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "type", "editable": true, "editor": type1439, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByParent.type) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description1440, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template1441, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByParent.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template1442, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByParent.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 17, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type1443, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByParent.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "parent", "editable": true, "editor": parent1449, "filter": { "type": "string" }, "header": "Parent", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByParent.parent) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.ProjectsByParent.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByParent.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByParent.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByParent.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByParent.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/ProjectsByParent",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByParent.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByParent.insert;
    Lino.tickets.ProjectsByParent.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByParent.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.ProjectsByParent.insertPanel(p);
});
Lino.tickets.ProjectsByParent.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByParent.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByParent.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByParent.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByParent.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/ProjectsByParent",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByParent.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByParent.insert;
    Lino.tickets.ProjectsByParent.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByParent.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectsByParent.detailPanel(p);
});
Lino.tickets.ProjectsByParent.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByParent.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.ProjectsByParent.GridPanel(p);
});
Lino.tickets.ProjectsByParent.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByParent", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.ProjectsByType
Lino.tickets.ProjectsByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/ProjectsByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Eesm\u00e4rgid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "id", "type": "int" }, { "name": "parent" }, 'parentHidden', { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "private", "type": "boolean" }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "type" }, 'typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByType.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByType.insert;
    var ww = this.containing_window;
    var ref2656 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name2657 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var id2658 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var parent2659 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByType/parent" }) }) });
    var start_date2660 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date2661 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var company2662 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByType/company" }) }) });
    var contact_person2663 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByType/contact_person" }) }) });
    var contact_role2664 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByType/contact_role" }) }) });
    var private2665 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var closed2666 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time2667 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to2668 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByType/assign_to" }) }) });
    var description2669 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template2670 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template2671 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type2672 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp2673 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2674 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2675 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2676 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2677 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp2678 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type2679 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByType/type" }) }) });
    this.before_row_edit = function(record) {
      contact_person2663.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2669.refresh();
    };
    this.onRender = function(ct, position) {
      company2662.on('change',Lino.chooser_handler(contact_person2663,'company'));
      Lino.tickets.ProjectsByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref2656, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.ProjectsByType.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name2657, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.ProjectsByType.name) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id2658, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "parent", "editable": true, "editor": parent2659, "filter": { "type": "string" }, "header": "Parent", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByType.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "start_date", "editable": true, "editor": start_date2660, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByType.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date2661, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByType.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "company", "editable": true, "editor": company2662, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByType.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "contact_person", "editable": true, "editor": contact_person2663, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByType.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_role", "editable": true, "editor": contact_role2664, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time2667, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByType.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "assign_to", "editable": true, "editor": assign_to2668, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByType.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description2669, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template2670, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByType.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template2671, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByType.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type2672, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 17, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByType.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "type", "editable": true, "editor": type2679, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByType.type) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.ProjectsByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByType.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/ProjectsByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByType.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByType.insert;
    Lino.tickets.ProjectsByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByType.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.ProjectsByType.insertPanel(p);
});
Lino.tickets.ProjectsByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByType.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByType.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/ProjectsByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByType.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByType.insert;
    Lino.tickets.ProjectsByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByType.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectsByType.detailPanel(p);
});
Lino.tickets.ProjectsByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.ProjectsByType.GridPanel(p);
});
Lino.tickets.ProjectsByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.ProjectsByCompany
Lino.tickets.ProjectsByCompany.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/ProjectsByCompany",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByCompany','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByCompany','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Eesm\u00e4rgid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "id", "type": "int" }, { "name": "parent" }, 'parentHidden', { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "private", "type": "boolean" }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "company" }, 'companyHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByCompany.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByCompany.insert;
    var ww = this.containing_window;
    var ref6637 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name6638 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var id6639 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var parent6640 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByCompany/parent" }) }) });
    var start_date6641 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date6642 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var contact_person6643 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByCompany/contact_person" }) }) });
    var contact_role6644 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByCompany/contact_role" }) }) });
    var private6645 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var closed6646 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time6647 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to6648 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByCompany/assign_to" }) }) });
    var type6649 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByCompany/type" }) }) });
    var description6650 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template6651 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template6652 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type6653 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp6654 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6655 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6656 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6657 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6658 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp6659 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var company6660 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByCompany/company" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      contact_person6643.setContextValue('mk',bp['mk']);
      contact_person6643.setContextValue('mt',bp['mt']);
      description6650.refresh();
    };
    this.onRender = function(ct, position) {
      company6660.on('change',Lino.chooser_handler(contact_person6643,'company'));
      Lino.tickets.ProjectsByCompany.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref6637, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.ProjectsByCompany.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name6638, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.ProjectsByCompany.name) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6639, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByCompany.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "parent", "editable": true, "editor": parent6640, "filter": { "type": "string" }, "header": "Parent", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByCompany.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "start_date", "editable": true, "editor": start_date6641, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByCompany.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date6642, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByCompany.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "contact_person", "editable": true, "editor": contact_person6643, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByCompany.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "contact_role", "editable": true, "editor": contact_role6644, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time6647, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByCompany.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "assign_to", "editable": true, "editor": assign_to6648, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByCompany.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "type", "editable": true, "editor": type6649, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByCompany.type) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description6650, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template6651, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByCompany.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template6652, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByCompany.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type6653, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 17, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByCompany.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "company", "editable": true, "editor": company6660, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByCompany.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) } ];
    Lino.tickets.ProjectsByCompany.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByCompany.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByCompany.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByCompany.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByCompany.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/ProjectsByCompany",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByCompany.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByCompany.insert;
    Lino.tickets.ProjectsByCompany.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByCompany.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.ProjectsByCompany.insertPanel(p);
});
Lino.tickets.ProjectsByCompany.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByCompany.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByCompany.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByCompany.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByCompany.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/ProjectsByCompany",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByCompany.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByCompany.insert;
    Lino.tickets.ProjectsByCompany.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByCompany.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectsByCompany.detailPanel(p);
});
Lino.tickets.ProjectsByCompany.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByCompany.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.ProjectsByCompany.GridPanel(p);
});
Lino.tickets.ProjectsByCompany.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByCompany", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.ProjectsByPerson
Lino.tickets.ProjectsByPerson.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/ProjectsByPerson",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByPerson','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectsByPerson','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Eesm\u00e4rgid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 32,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "id", "type": "int" }, { "name": "parent" }, 'parentHidden', { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "company" }, 'companyHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "private", "type": "boolean" }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "assign_to" }, 'assign_toHidden', { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "srcref_url_template" }, { "name": "changeset_url_template" }, { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "activity_overview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "contact_person" }, 'contact_personHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByPerson.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByPerson.insert;
    var ww = this.containing_window;
    var ref6662 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name6663 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var id6664 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var parent6665 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByPerson/parent" }) }) });
    var start_date6666 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date6667 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var company6668 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByPerson/company" }) }) });
    var contact_role6669 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByPerson/contact_role" }) }) });
    var private6670 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var closed6671 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time6672 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var assign_to6673 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByPerson/assign_to" }) }) });
    var type6674 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Project Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByPerson/type" }) }) });
    var description6675 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var srcref_url_template6676 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var changeset_url_template6677 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var reporting_type6678 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var activity_overview_disp6679 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6680 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6681 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6682 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6683 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp6684 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var contact_person6685 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/ProjectsByPerson/contact_person" }) }) });
    this.before_row_edit = function(record) {
      description6675.refresh();
      contact_person6685.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company6668.on('change',Lino.chooser_handler(contact_person6685,'company'));
      Lino.tickets.ProjectsByPerson.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref6662, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(tickets.ProjectsByPerson.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name6663, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(tickets.ProjectsByPerson.name) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6664, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByPerson.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "parent", "editable": true, "editor": parent6665, "filter": { "type": "string" }, "header": "Parent", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByPerson.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "start_date", "editable": true, "editor": start_date6666, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByPerson.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date6667, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByPerson.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "company", "editable": true, "editor": company6668, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByPerson.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "contact_role", "editable": true, "editor": contact_role6669, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time6672, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByPerson.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "assign_to", "editable": true, "editor": assign_to6673, "filter": { "type": "string" }, "header": "Assign tickets to", "hidden": true, "renderer": Lino.fk_renderer('assign_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByPerson.assign_to) The user to whom new tickets will be assigned.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "type", "editable": true, "editor": type6674, "filter": { "type": "string" }, "header": "Project Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.tickets.ProjectTypes.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByPerson.type) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description6675, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "srcref_url_template", "editable": true, "editor": srcref_url_template6676, "filter": { "type": "string" }, "header": "srcref url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByPerson.srcref_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "changeset_url_template", "editable": true, "editor": changeset_url_template6677, "filter": { "type": "string" }, "header": "changeset url template", "hidden": true, "sortable": true, "tooltip": "(tickets.ProjectsByPerson.changeset_url_template) ", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type6678, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 17, "dataIndex": "activity_overview", "editable": false, "header": "Activity overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.activity_overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 22, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectsByPerson.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 23, "dataIndex": "contact_person", "editable": true, "editor": contact_person6685, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(tickets.ProjectsByPerson.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) } ];
    Lino.tickets.ProjectsByPerson.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByPerson.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByPerson.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByPerson.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByPerson.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/ProjectsByPerson",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByPerson.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByPerson.insert;
    Lino.tickets.ProjectsByPerson.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByPerson.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.ProjectsByPerson.insertPanel(p);
});
Lino.tickets.ProjectsByPerson.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByPerson.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByPerson.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByPerson.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.ProjectsByPerson.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/ProjectsByPerson",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.ProjectsByPerson.detail;
    this.ls_insert_handler = Lino.tickets.ProjectsByPerson.insert;
    Lino.tickets.ProjectsByPerson.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectsByPerson.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectsByPerson.detailPanel(p);
});
Lino.tickets.ProjectsByPerson.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectsByPerson.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.tickets.ProjectsByPerson.GridPanel(p);
});
Lino.tickets.ProjectsByPerson.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectsByPerson", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.LinksByTicket
Lino.tickets.LinksByTicket.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/LinksByTicket",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/LinksByTicket','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/LinksByTicket','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Dependencies",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "parent" }, 'parentHidden', { "name": "type_as_parent" }, { "name": "child" }, 'childHidden', { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 42,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.LinksByTicket.detail;
    this.ls_insert_handler = Lino.tickets.LinksByTicket.insert;
    var ww = this.containing_window;
    var parent6687 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/LinksByTicket/parent" }) }) });
    var type_as_parent_disp6688 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var child6689 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/LinksByTicket/child" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "parent", "editable": true, "editor": parent6687, "filter": { "type": "string" }, "header": "Parent", "renderer": Lino.fk_renderer('parentHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.LinksByTicket.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "type_as_parent", "editable": false, "header": "Type", "sortable": false, "tooltip": "(tickets.LinksByTicket.type_as_parent) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "child", "editable": true, "editor": child6689, "filter": { "type": "string" }, "header": "Child", "renderer": Lino.fk_renderer('childHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.LinksByTicket.child) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.LinksByTicket.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.LinksByTicket.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinksByTicket.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinksByTicket.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.LinksByTicket.insertPanel = Ext.extend(Lino.tickets.Links.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/LinksByTicket",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.LinksByTicket.detail;
    this.ls_insert_handler = Lino.tickets.LinksByTicket.insert;
    Lino.tickets.LinksByTicket.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.LinksByTicket.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.LinksByTicket.insertPanel(p);
});
Lino.tickets.LinksByTicket.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinksByTicket.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinksByTicket.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.LinksByTicket.detailPanel = Ext.extend(Lino.tickets.Links.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/LinksByTicket",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.LinksByTicket.detail;
    this.ls_insert_handler = Lino.tickets.LinksByTicket.insert;
    Lino.tickets.LinksByTicket.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.LinksByTicket.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.LinksByTicket.detailPanel(p);
});
Lino.tickets.LinksByTicket.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinksByTicket.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.LinksByTicket.GridPanel(p);
});
Lino.tickets.LinksByTicket.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinksByTicket", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.DuplicatesByTicket
Lino.tickets.DuplicatesByTicket.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/DuplicatesByTicket",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/DuplicatesByTicket','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/DuplicatesByTicket','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Duplicates",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.DuplicatesByTicket.detail;
    this.ls_insert_handler = Lino.tickets.DuplicatesByTicket.insert;
    var ww = this.containing_window;
    var id888 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary889 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var modified890 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created891 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref892 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private893 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user894 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/user" }) }) });
    var priority895 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed896 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time897 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project898 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/project" }) }) });
    var site899 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/site" }) }) });
    var topic900 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/topic" }) }) });
    var description901 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes902 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type903 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/ticket_type" }) }) });
    var end_user904 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/end_user" }) }) });
    var state905 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline906 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for907 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/reported_for" }) }) });
    var fixed_for908 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/fixed_for" }) }) });
    var reporter909 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/reporter" }) }) });
    var waiting_for910 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback911 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby912 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp913 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp914 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp915 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp916 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp917 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp918 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp919 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duplicate_of920 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/DuplicatesByTicket/duplicate_of" }) }) });
    this.before_row_edit = function(record) {
      description901.refresh();
      reported_for907.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for908.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site899.on('change',Lino.chooser_handler(reported_for907,'site'));
      site899.on('change',Lino.chooser_handler(fixed_for908,'site'));
      Lino.tickets.DuplicatesByTicket.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id888, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary889, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 3, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "ref", "editable": true, "editor": ref892, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 6, "dataIndex": "user", "editable": true, "editor": user894, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority895, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time897, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "project", "editable": true, "editor": project898, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site899, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.site) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "topic", "editable": true, "editor": topic900, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description901, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes902, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type903, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "end_user", "editable": true, "editor": end_user904, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "state", "editable": true, "editor": state905, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.state) ", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline906, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 19, "dataIndex": "reported_for", "editable": true, "editor": reported_for907, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for908, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter909, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for910, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of920, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.duplicate_of) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.DuplicatesByTicket.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.DuplicatesByTicket.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.DuplicatesByTicket.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/DuplicatesByTicket",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.DuplicatesByTicket.detail;
    this.ls_insert_handler = Lino.tickets.DuplicatesByTicket.insert;
    Lino.tickets.DuplicatesByTicket.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.DuplicatesByTicket.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.DuplicatesByTicket.insertPanel(p);
});
Lino.tickets.DuplicatesByTicket.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.DuplicatesByTicket.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/DuplicatesByTicket",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.DuplicatesByTicket.detail;
    this.ls_insert_handler = Lino.tickets.DuplicatesByTicket.insert;
    Lino.tickets.DuplicatesByTicket.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.DuplicatesByTicket.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.DuplicatesByTicket.detailPanel(p);
});
Lino.tickets.DuplicatesByTicket.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.DuplicatesByTicket.GridPanel(p);
});
Lino.tickets.DuplicatesByTicket.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.SuggestedTicketsByEndUser
Lino.tickets.SuggestedTicketsByEndUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/SuggestedTicketsByEndUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/SuggestedTicketsByEndUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/SuggestedTicketsByEndUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Kus ma saan aidata",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "needed_skills" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.SuggestedTicketsByEndUser.detail;
    this.ls_insert_handler = Lino.tickets.SuggestedTicketsByEndUser.insert;
    var ww = this.containing_window;
    var overview_disp6691 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var needed_skills_disp6692 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp6693 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id6694 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified6695 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created6696 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref6697 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private6698 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user6699 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/user" }) }) });
    var priority6700 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed6701 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time6702 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project6703 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/project" }) }) });
    var site6704 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/site" }) }) });
    var topic6705 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/topic" }) }) });
    var summary6706 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description6707 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes6708 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type6709 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/ticket_type" }) }) });
    var duplicate_of6710 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/duplicate_of" }) }) });
    var end_user6711 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/end_user" }) }) });
    var state6712 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline6713 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for6714 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/reported_for" }) }) });
    var fixed_for6715 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/fixed_for" }) }) });
    var reporter6716 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/SuggestedTicketsByEndUser/reporter" }) }) });
    var waiting_for6717 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback6718 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby6719 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var suppliers_disp6720 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6721 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6722 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp6723 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description6707.refresh();
      reported_for6714.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for6715.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site6704.on('change',Lino.chooser_handler(reported_for6714,'site'));
      site6704.on('change',Lino.chooser_handler(fixed_for6715,'site'));
      Lino.tickets.SuggestedTicketsByEndUser.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id6694, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "ref", "editable": true, "editor": ref6697, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 8, "dataIndex": "user", "editable": true, "editor": user6699, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 9, "dataIndex": "priority", "editable": true, "editor": priority6700, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time6702, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "project", "editable": true, "editor": project6703, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.project) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "site", "editable": true, "editor": site6704, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.site) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "topic", "editable": true, "editor": topic6705, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "summary", "editable": true, "editor": summary6706, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 16, "dataIndex": "description", "editable": true, "editor": description6707, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.description) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes6708, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 18, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type6709, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of6710, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "end_user", "editable": true, "editor": end_user6711, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "state", "editable": true, "editor": state6712, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.state) ", "width": Lino.chars2width(12) }, { "colIndex": 22, "dataIndex": "deadline", "editable": true, "editor": deadline6713, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "reported_for", "editable": true, "editor": reported_for6714, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for6715, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 25, "dataIndex": "reporter", "editable": true, "editor": reporter6716, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for6717, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.SuggestedTicketsByEndUser.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 27, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 28, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 29, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.SuggestedTicketsByEndUser.created_natural) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.SuggestedTicketsByEndUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.SuggestedTicketsByEndUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.SuggestedTicketsByEndUser.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/SuggestedTicketsByEndUser",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.SuggestedTicketsByEndUser.detail;
    this.ls_insert_handler = Lino.tickets.SuggestedTicketsByEndUser.insert;
    Lino.tickets.SuggestedTicketsByEndUser.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.SuggestedTicketsByEndUser.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.SuggestedTicketsByEndUser.insertPanel(p);
});
Lino.tickets.SuggestedTicketsByEndUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.SuggestedTicketsByEndUser.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/SuggestedTicketsByEndUser",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.SuggestedTicketsByEndUser.detail;
    this.ls_insert_handler = Lino.tickets.SuggestedTicketsByEndUser.insert;
    Lino.tickets.SuggestedTicketsByEndUser.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.SuggestedTicketsByEndUser.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.SuggestedTicketsByEndUser.detailPanel(p);
});
Lino.tickets.SuggestedTicketsByEndUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.SuggestedTicketsByEndUser.ParamsPanel({});
  return new Lino.tickets.SuggestedTicketsByEndUser.GridPanel(p);
});
Lino.tickets.SuggestedTicketsByEndUser.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.SuggestedTicketsByEndUser.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/SuggestedTicketsByEndUser", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsByEndUser
Lino.tickets.TicketsByEndUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsByEndUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByEndUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByEndUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "end_user" }, 'end_userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByEndUser.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByEndUser.insert;
    var ww = this.containing_window;
    var overview_disp3093 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp3094 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id3095 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified3096 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3097 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref3098 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private3099 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user3100 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/user" }) }) });
    var priority3101 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3102 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3103 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3104 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/project" }) }) });
    var site3105 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/site" }) }) });
    var topic3106 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/topic" }) }) });
    var summary3107 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description3108 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3109 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3110 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/ticket_type" }) }) });
    var duplicate_of3111 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/duplicate_of" }) }) });
    var state3112 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3113 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3114 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/reported_for" }) }) });
    var fixed_for3115 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/fixed_for" }) }) });
    var reporter3116 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/reporter" }) }) });
    var waiting_for3117 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3118 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3119 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3120 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3121 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3122 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3123 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3124 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var end_user3125 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByEndUser/end_user" }) }) });
    this.before_row_edit = function(record) {
      description3108.refresh();
      reported_for3114.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for3115.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site3105.on('change',Lino.chooser_handler(reported_for3114,'site'));
      site3105.on('change',Lino.chooser_handler(fixed_for3115,'site'));
      Lino.tickets.TicketsByEndUser.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.TicketsByEndUser.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.TicketsByEndUser.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id3095, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref3098, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user3100, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 8, "dataIndex": "priority", "editable": true, "editor": priority3101, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time3103, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "project", "editable": true, "editor": project3104, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.project) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "site", "editable": true, "editor": site3105, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.site) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "topic", "editable": true, "editor": topic3106, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "summary", "editable": true, "editor": summary3107, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "description", "editable": true, "editor": description3108, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.description) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3109, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3110, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3111, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state3112, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline3113, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for3114, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3115, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter3116, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3117, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "end_user", "editable": true, "editor": end_user3125, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsByEndUser.end_user) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsByEndUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByEndUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByEndUser.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsByEndUser",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByEndUser.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByEndUser.insert;
    Lino.tickets.TicketsByEndUser.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByEndUser.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsByEndUser.insertPanel(p);
});
Lino.tickets.TicketsByEndUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByEndUser.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsByEndUser",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByEndUser.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByEndUser.insert;
    Lino.tickets.TicketsByEndUser.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByEndUser.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsByEndUser.detailPanel(p);
});
Lino.tickets.TicketsByEndUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsByEndUser.GridPanel(p);
});
Lino.tickets.TicketsByEndUser.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsByType
Lino.tickets.TicketsByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "summary" }, { "name": "state" }, 'stateHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByType.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByType.insert;
    var ww = this.containing_window;
    var summary2799 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var state2800 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var id2801 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified2802 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2803 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref2804 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private2805 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user2806 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/user" }) }) });
    var priority2807 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed2808 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time2809 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project2810 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/project" }) }) });
    var site2811 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/site" }) }) });
    var topic2812 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/topic" }) }) });
    var description2813 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes2814 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var duplicate_of2815 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/duplicate_of" }) }) });
    var end_user2816 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/end_user" }) }) });
    var deadline2817 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for2818 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/reported_for" }) }) });
    var fixed_for2819 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/fixed_for" }) }) });
    var reporter2820 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/reporter" }) }) });
    var waiting_for2821 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback2822 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby2823 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp2824 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp2825 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2826 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2827 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2828 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2829 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp2830 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var ticket_type2831 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByType/ticket_type" }) }) });
    this.before_row_edit = function(record) {
      description2813.refresh();
      reported_for2818.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for2819.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site2811.on('change',Lino.chooser_handler(reported_for2818,'site'));
      site2811.on('change',Lino.chooser_handler(fixed_for2819,'site'));
      Lino.tickets.TicketsByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "summary", "editable": true, "editor": summary2799, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.TicketsByType.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "state", "editable": true, "editor": state2800, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(tickets.TicketsByType.state) ", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id2801, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref2804, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user2806, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 8, "dataIndex": "priority", "editable": true, "editor": priority2807, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time2809, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "project", "editable": true, "editor": project2810, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.project) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "site", "editable": true, "editor": site2811, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.site) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "topic", "editable": true, "editor": topic2812, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description2813, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes2814, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of2815, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "end_user", "editable": true, "editor": end_user2816, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline2817, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 19, "dataIndex": "reported_for", "editable": true, "editor": reported_for2818, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for2819, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter2820, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for2821, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type2831, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsByType.ticket_type) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByType.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByType.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByType.insert;
    Lino.tickets.TicketsByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByType.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsByType.insertPanel(p);
});
Lino.tickets.TicketsByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByType.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByType.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByType.insert;
    Lino.tickets.TicketsByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByType.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsByType.detailPanel(p);
});
Lino.tickets.TicketsByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsByType.GridPanel(p);
});
Lino.tickets.TicketsByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsByTopic
Lino.tickets.TicketsByTopic.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsByTopic",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByTopic','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByTopic','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "summary" }, { "name": "state" }, 'stateHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "topic" }, 'topicHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByTopic.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByTopic.insert;
    var ww = this.containing_window;
    var summary3127 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var state3128 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var id3129 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified3130 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3131 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref3132 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private3133 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user3134 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/user" }) }) });
    var priority3135 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3136 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3137 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3138 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/project" }) }) });
    var site3139 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/site" }) }) });
    var description3140 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3141 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3142 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/ticket_type" }) }) });
    var duplicate_of3143 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/duplicate_of" }) }) });
    var end_user3144 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/end_user" }) }) });
    var deadline3145 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3146 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/reported_for" }) }) });
    var fixed_for3147 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/fixed_for" }) }) });
    var reporter3148 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/reporter" }) }) });
    var waiting_for3149 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3150 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3151 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3152 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3153 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3154 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3155 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3156 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3157 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3158 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var topic3159 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByTopic/topic" }) }) });
    this.before_row_edit = function(record) {
      description3140.refresh();
      reported_for3146.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for3147.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site3139.on('change',Lino.chooser_handler(reported_for3146,'site'));
      site3139.on('change',Lino.chooser_handler(fixed_for3147,'site'));
      Lino.tickets.TicketsByTopic.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "summary", "editable": true, "editor": summary3127, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.TicketsByTopic.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "state", "editable": true, "editor": state3128, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(tickets.TicketsByTopic.state) ", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id3129, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref3132, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 7, "dataIndex": "user", "editable": true, "editor": user3134, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 8, "dataIndex": "priority", "editable": true, "editor": priority3135, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time3137, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "project", "editable": true, "editor": project3138, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.project) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "site", "editable": true, "editor": site3139, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.site) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description3140, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3141, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3142, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3143, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3144, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline3145, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 19, "dataIndex": "reported_for", "editable": true, "editor": reported_for3146, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3147, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter3148, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3149, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "topic", "editable": true, "editor": topic3159, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsByTopic.topic) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsByTopic.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByTopic.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByTopic.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsByTopic",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByTopic.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByTopic.insert;
    Lino.tickets.TicketsByTopic.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByTopic.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsByTopic.insertPanel(p);
});
Lino.tickets.TicketsByTopic.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByTopic.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsByTopic",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByTopic.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByTopic.insert;
    Lino.tickets.TicketsByTopic.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByTopic.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsByTopic.detailPanel(p);
});
Lino.tickets.TicketsByTopic.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsByTopic.GridPanel(p);
});
Lino.tickets.TicketsByTopic.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsFixed
Lino.tickets.TicketsFixed.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/tickets/TicketsFixed",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsFixed','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsFixed','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" } ],
  cell_edit : true,
  title : "Fixed tickets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 44,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "fixed_for" }, 'fixed_forHidden', { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsFixed.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    var ww = this.containing_window;
    var id3161 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3162 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3163 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/user" }) }) });
    var modified3164 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3165 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref3166 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private3167 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3168 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3169 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3170 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3171 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/project" }) }) });
    var site3172 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/site" }) }) });
    var topic3173 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/topic" }) }) });
    var description3174 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3175 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3176 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/ticket_type" }) }) });
    var duplicate_of3177 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/duplicate_of" }) }) });
    var end_user3178 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/end_user" }) }) });
    var state3179 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3180 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3181 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/reported_for" }) }) });
    var reporter3182 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/reporter" }) }) });
    var waiting_for3183 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3184 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3185 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3186 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3187 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3188 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3189 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3190 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3191 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3192 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var fixed_for3193 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsFixed/fixed_for" }) }) });
    this.before_row_edit = function(record) {
      description3174.refresh();
    };
    this.onRender = function(ct, position) {
      site3172.on('change',Lino.chooser_handler(reported_for3181,'site'));
      site3172.on('change',Lino.chooser_handler(fixed_for3193,'site'));
      Lino.tickets.TicketsFixed.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3161, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsFixed.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3162, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.TicketsFixed.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3163, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref3166, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority3168, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time3170, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "project", "editable": true, "editor": project3171, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site3172, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.site) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "topic", "editable": true, "editor": topic3173, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description3174, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3175, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3176, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3177, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3178, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "state", "editable": true, "editor": state3179, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline3180, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "reported_for", "editable": true, "editor": reported_for3181, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter3182, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3183, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3193, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsFixed.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsFixed.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsFixed.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsFixed.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/tickets/TicketsFixed",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsFixed.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    Lino.tickets.TicketsFixed.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsFixed.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsFixed.detailPanel(p);
});
Lino.tickets.TicketsFixed.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsFixed.GridPanel(p);
});
Lino.tickets.TicketsFixed.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsReported
Lino.tickets.TicketsReported.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/tickets/TicketsReported",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsReported','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsReported','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" } ],
  cell_edit : true,
  title : "Reported tickets",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 44,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsReported.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    var ww = this.containing_window;
    var id3195 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3196 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3197 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/user" }) }) });
    var modified3198 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3199 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref3200 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private3201 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3202 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3203 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3204 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3205 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/project" }) }) });
    var site3206 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/site" }) }) });
    var topic3207 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/topic" }) }) });
    var description3208 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3209 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3210 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/ticket_type" }) }) });
    var duplicate_of3211 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/duplicate_of" }) }) });
    var end_user3212 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/end_user" }) }) });
    var state3213 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3214 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var fixed_for3215 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/fixed_for" }) }) });
    var reporter3216 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/reporter" }) }) });
    var waiting_for3217 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3218 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3219 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3220 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3221 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3222 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3223 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3224 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3225 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3226 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reported_for3227 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsReported/reported_for" }) }) });
    this.before_row_edit = function(record) {
      description3208.refresh();
    };
    this.onRender = function(ct, position) {
      site3206.on('change',Lino.chooser_handler(fixed_for3215,'site'));
      site3206.on('change',Lino.chooser_handler(reported_for3227,'site'));
      Lino.tickets.TicketsReported.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3195, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsReported.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3196, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.TicketsReported.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3197, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref3200, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority3202, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time3204, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "project", "editable": true, "editor": project3205, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site3206, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.site) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "topic", "editable": true, "editor": topic3207, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description3208, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3209, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3210, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3211, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3212, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "state", "editable": true, "editor": state3213, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline3214, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3215, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter3216, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3217, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "reported_for", "editable": true, "editor": reported_for3227, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsReported.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsReported.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsReported.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsReported.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/tickets/TicketsReported",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsReported.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    Lino.tickets.TicketsReported.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsReported.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsReported.detailPanel(p);
});
Lino.tickets.TicketsReported.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsReported.GridPanel(p);
});
Lino.tickets.TicketsReported.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsByReporter
Lino.tickets.TicketsByReporter.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsByReporter",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByReporter','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByReporter','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Reported tickets ",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "project" }, 'projectHidden', { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "user" }, 'userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByReporter.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByReporter.insert;
    var ww = this.containing_window;
    var id3229 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3230 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp3231 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var modified3232 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3233 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref3234 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private3235 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3236 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3237 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3238 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3239 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/project" }) }) });
    var site3240 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/site" }) }) });
    var topic3241 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/topic" }) }) });
    var description3242 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3243 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3244 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/ticket_type" }) }) });
    var duplicate_of3245 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/duplicate_of" }) }) });
    var end_user3246 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/end_user" }) }) });
    var state3247 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3248 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3249 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/reported_for" }) }) });
    var fixed_for3250 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/fixed_for" }) }) });
    var reporter3251 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/reporter" }) }) });
    var waiting_for3252 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3253 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3254 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3255 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3256 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3257 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3258 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3259 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3260 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var user3261 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByReporter/user" }) }) });
    this.before_row_edit = function(record) {
      description3242.refresh();
      reported_for3249.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for3250.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site3240.on('change',Lino.chooser_handler(reported_for3249,'site'));
      site3240.on('change',Lino.chooser_handler(fixed_for3250,'site'));
      Lino.tickets.TicketsByReporter.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3229, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsByReporter.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3230, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.TicketsByReporter.summary) Short summary of the problem.", "width": Lino.chars2width(61) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.TicketsByReporter.workflow_buttons) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 4, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "ref", "editable": true, "editor": ref3234, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority3236, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time3238, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "project", "editable": true, "editor": project3239, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site3240, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.site) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "topic", "editable": true, "editor": topic3241, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description3242, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3243, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3244, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3245, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3246, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "state", "editable": true, "editor": state3247, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline3248, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "reported_for", "editable": true, "editor": reported_for3249, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3250, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "reporter", "editable": true, "editor": reporter3251, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3252, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "user", "editable": true, "editor": user3261, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByReporter.user) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsByReporter.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByReporter.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByReporter.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsByReporter",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByReporter.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByReporter.insert;
    Lino.tickets.TicketsByReporter.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByReporter.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsByReporter.insertPanel(p);
});
Lino.tickets.TicketsByReporter.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByReporter.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsByReporter",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByReporter.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByReporter.insert;
    Lino.tickets.TicketsByReporter.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByReporter.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsByReporter.detailPanel(p);
});
Lino.tickets.TicketsByReporter.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsByReporter.GridPanel(p);
});
Lino.tickets.TicketsByReporter.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsBySite
Lino.tickets.TicketsBySite.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsBySite",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsBySite','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsBySite','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Known problems",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "topic" }, 'topicHidden', { "name": "workflow_buttons" }, { "name": "project" }, 'projectHidden', { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "priority", "type": "int", "useNull": true }, { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "site" }, 'siteHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsBySite.detail;
    this.ls_insert_handler = Lino.tickets.TicketsBySite.insert;
    var ww = this.containing_window;
    var id3263 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3264 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3265 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/user" }) }) });
    var topic3266 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/topic" }) }) });
    var workflow_buttons_disp3267 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project3268 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/project" }) }) });
    var modified3269 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3270 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref3271 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private3272 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3273 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3274 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3275 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var description3276 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3277 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3278 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/ticket_type" }) }) });
    var duplicate_of3279 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/duplicate_of" }) }) });
    var end_user3280 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/end_user" }) }) });
    var state3281 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3282 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3283 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/reported_for" }) }) });
    var fixed_for3284 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/fixed_for" }) }) });
    var reporter3285 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/reporter" }) }) });
    var waiting_for3286 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3287 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3288 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3289 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3290 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp3291 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3292 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3293 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3294 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var site3295 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsBySite/site" }) }) });
    this.before_row_edit = function(record) {
      description3276.refresh();
      var bp = this.get_base_params();
      reported_for3283.setContextValue('mk',bp['mk']);
      reported_for3283.setContextValue('mt',bp['mt']);
      var bp = this.get_base_params();
      fixed_for3284.setContextValue('mk',bp['mk']);
      fixed_for3284.setContextValue('mt',bp['mt']);
    };
    this.onRender = function(ct, position) {
      site3295.on('change',Lino.chooser_handler(reported_for3283,'site'));
      site3295.on('change',Lino.chooser_handler(fixed_for3284,'site'));
      Lino.tickets.TicketsBySite.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3263, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsBySite.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3264, "filter": { "type": "string" }, "header": "Summary", "sortable": true, "tooltip": "(tickets.TicketsBySite.summary) Short summary of the problem.", "width": Lino.chars2width(51) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3265, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic3266, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.TicketsBySite.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "project", "editable": true, "editor": project3268, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.project) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 7, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 8, "dataIndex": "ref", "editable": true, "editor": ref3271, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 9, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 10, "dataIndex": "priority", "editable": true, "editor": priority3273, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "planned_time", "editable": true, "editor": planned_time3275, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description3276, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3277, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3278, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3279, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3280, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "state", "editable": true, "editor": state3281, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline3282, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "reported_for", "editable": true, "editor": reported_for3283, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3284, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "reporter", "editable": true, "editor": reporter3285, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3286, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "site", "editable": true, "editor": site3295, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsBySite.site) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsBySite.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsBySite.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsBySite.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsBySite",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsBySite.detail;
    this.ls_insert_handler = Lino.tickets.TicketsBySite.insert;
    Lino.tickets.TicketsBySite.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsBySite.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsBySite.insertPanel(p);
});
Lino.tickets.TicketsBySite.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsBySite.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsBySite",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsBySite.detail;
    this.ls_insert_handler = Lino.tickets.TicketsBySite.insert;
    Lino.tickets.TicketsBySite.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsBySite.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsBySite.detailPanel(p);
});
Lino.tickets.TicketsBySite.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsBySite.GridPanel(p);
});
Lino.tickets.TicketsBySite.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class tickets.TicketsByProject
Lino.tickets.TicketsByProject.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/tickets/TicketsByProject",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByProject','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByProject','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 45,
  ls_store_fields : [ { "name": "priority", "type": "int", "useNull": true }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "ref" }, { "name": "private", "type": "boolean" }, { "name": "user" }, 'userHidden', { "name": "closed", "type": "boolean" }, { "name": "planned_time" }, { "name": "site" }, 'siteHidden', { "name": "topic" }, 'topicHidden', { "name": "summary" }, { "name": "description" }, { "name": "upgrade_notes" }, { "name": "ticket_type" }, 'ticket_typeHidden', { "name": "duplicate_of" }, 'duplicate_ofHidden', { "name": "end_user" }, 'end_userHidden', { "name": "state" }, 'stateHidden', { "dateFormat": "d.m.Y", "name": "deadline", "type": "date" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "fixed_for" }, 'fixed_forHidden', { "name": "reporter" }, 'reporterHidden', { "name": "waiting_for" }, { "name": "feedback", "type": "boolean" }, { "name": "standby", "type": "boolean" }, { "name": "needed_skills" }, { "name": "suppliers" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "project" }, 'projectHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByProject.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByProject.insert;
    var ww = this.containing_window;
    var priority1366 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 100 });
    var overview_disp1367 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp1368 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id1369 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified1370 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created1371 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var ref1372 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var private1373 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var user1374 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/user" }) }) });
    var closed1375 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time1376 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site1377 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/site" }) }) });
    var topic1378 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/topic" }) }) });
    var summary1379 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description1380 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes1381 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type1382 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipikuliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/ticket_type" }) }) });
    var duplicate_of1383 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/duplicate_of" }) }) });
    var end_user1384 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/end_user" }) }) });
    var state1385 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline1386 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for1387 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/reported_for" }) }) });
    var fixed_for1388 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/fixed_for" }) }) });
    var reporter1389 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/reporter" }) }) });
    var waiting_for1390 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback1391 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby1392 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp1393 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp1394 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp1395 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1396 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp1397 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var project1398 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/tickets/TicketsByProject/project" }) }) });
    this.before_row_edit = function(record) {
      description1380.refresh();
      reported_for1387.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for1388.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site1377.on('change',Lino.chooser_handler(reported_for1387,'site'));
      site1377.on('change',Lino.chooser_handler(fixed_for1388,'site'));
      Lino.tickets.TicketsByProject.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "priority", "editable": true, "editor": priority1366, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "sortable": true, "tooltip": "(tickets.TicketsByProject.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(tickets.TicketsByProject.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(tickets.TicketsByProject.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id1369, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "ref", "editable": true, "editor": ref1372, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.private) Whether this investment is private, i.e. should not be\npublicly visible anywhere.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 8, "dataIndex": "user", "editable": true, "editor": user1374, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.user) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "closed", "editable": true, "filter": { "type": "boolean" }, "header": "L\u00f5petatud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time1376, "header": "Planned time", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.planned_time) The time (in hours) we plan to work on this project or ticket.", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site1377, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('siteHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.site) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "topic", "editable": true, "editor": topic1378, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "summary", "editable": true, "editor": summary1379, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description1380, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes1381, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type1382, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "renderer": Lino.fk_renderer('ticket_typeHidden','Lino.tickets.TicketTypes.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of1383, "filter": { "type": "string" }, "header": "Duplicate of", "hidden": true, "renderer": Lino.fk_renderer('duplicate_ofHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.duplicate_of) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "end_user", "editable": true, "editor": end_user1384, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "state", "editable": true, "editor": state1385, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.state) ", "width": Lino.chars2width(12) }, { "colIndex": 20, "dataIndex": "deadline", "editable": true, "editor": deadline1386, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Deadline", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.deadline) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 21, "dataIndex": "reported_for", "editable": true, "editor": reported_for1387, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "renderer": Lino.fk_renderer('reported_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for1388, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "renderer": Lino.fk_renderer('fixed_forHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "reporter", "editable": true, "editor": reporter1389, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "renderer": Lino.fk_renderer('reporterHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for1390, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByProject.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 25, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByProject.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "project", "editable": true, "editor": project1398, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(tickets.TicketsByProject.project) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketsByProject.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByProject.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByProject.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/tickets/TicketsByProject",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByProject.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByProject.insert;
    Lino.tickets.TicketsByProject.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByProject.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.tickets.TicketsByProject.insertPanel(p);
});
Lino.tickets.TicketsByProject.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.tickets.TicketsByProject.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/tickets/TicketsByProject",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.tickets.TicketsByProject.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByProject.insert;
    Lino.tickets.TicketsByProject.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketsByProject.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketsByProject.detailPanel(p);
});
Lino.tickets.TicketsByProject.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.tickets.TicketsByProject.GridPanel(p);
});
Lino.tickets.TicketsByProject.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByProject.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByProject", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class users.AuthoritiesGiven
Lino.users.AuthoritiesGiven.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/AuthoritiesGiven",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/AuthoritiesGiven','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/AuthoritiesGiven','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Authorities given",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "authorized" }, 'authorizedHidden', { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 11,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var authorized2628 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AuthoritiesGiven/authorized" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      authorized2628.setContextValue('mk',bp['mk']);
      authorized2628.setContextValue('mt',bp['mt']);
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "authorized", "editable": true, "editor": authorized2628, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('authorizedHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(users.AuthoritiesGiven.authorized) ", "width": Lino.chars2width(21) } ];
    Lino.users.AuthoritiesGiven.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.AuthoritiesGiven.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesGiven", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesGiven.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesGiven", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesGiven.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesGiven", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesGiven.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesGiven", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesGiven.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesGiven", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesGiven.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesGiven", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesGiven.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Authorities.ParamsPanel({});
  return new Lino.users.AuthoritiesGiven.GridPanel(p);
});

// js_render_GridPanel_class users.AuthoritiesTaken
Lino.users.AuthoritiesTaken.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/users/AuthoritiesTaken",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/AuthoritiesTaken','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/AuthoritiesTaken','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Authorities taken",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 11,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var user6725 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/AuthoritiesTaken/user" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "user", "editable": true, "editor": user6725, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(users.AuthoritiesTaken.user) ", "width": Lino.chars2width(21) } ];
    Lino.users.AuthoritiesTaken.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.AuthoritiesTaken.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesTaken", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesTaken.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesTaken", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesTaken.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesTaken", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesTaken.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesTaken", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesTaken.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesTaken", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesTaken.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/AuthoritiesTaken", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.AuthoritiesTaken.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Authorities.ParamsPanel({});
  return new Lino.users.AuthoritiesTaken.GridPanel(p);
});

// js_render_GridPanel_class faculties.SkillsByParent
Lino.faculties.SkillsByParent.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/SkillsByParent",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/SkillsByParent','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/SkillsByParent','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Child skills",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 17,
  ls_store_fields : [ { "name": "seqno", "type": "int", "useNull": true }, { "name": "overview" }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "name" }, { "name": "name_et" }, { "name": "skill_type" }, 'skill_typeHidden', { "name": "remarks" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "move_buttons" }, { "name": "parent" }, 'parentHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 49,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillsByParent.detail;
    this.ls_insert_handler = Lino.faculties.SkillsByParent.insert;
    var ww = this.containing_window;
    var seqno1796 = new Ext.form.NumberField({ "selectOnFocus": true });
    var overview_disp1797 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var affinity1798 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var id1799 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name1800 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name_et1801 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var skill_type1802 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/SkillsByParent/skill_type" }) }) });
    var remarks1803 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var mobile_item_disp1804 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1805 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1806 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp1807 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp1808 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var parent1809 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/SkillsByParent/parent" }) }) });
    this.before_row_edit = function(record) {
      remarks1803.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "seqno", "editable": true, "editor": seqno1796, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(faculties.SkillsByParent.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(faculties.SkillsByParent.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 2, "dataIndex": "affinity", "editable": true, "editor": affinity1798, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.SkillsByParent.affinity) How much workers enjoy to get a new ticket requiring this skill.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id1799, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.SkillsByParent.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "name", "editable": true, "editor": name1800, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(faculties.SkillsByParent.name) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "name_et", "editable": true, "editor": name_et1801, "filter": { "type": "string" }, "header": "Nimetus (et)", "hidden": true, "sortable": true, "tooltip": "(faculties.SkillsByParent.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "skill_type", "editable": true, "editor": skill_type1802, "filter": { "type": "string" }, "header": "Oskuseliik", "hidden": true, "renderer": Lino.fk_renderer('skill_typeHidden','Lino.faculties.SkillTypes.detail'), "sortable": false, "tooltip": "(faculties.SkillsByParent.skill_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "remarks", "editable": true, "editor": remarks1803, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByParent.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByParent.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByParent.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByParent.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByParent.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByParent.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "parent", "editable": true, "editor": parent1809, "filter": { "type": "string" }, "header": "Parent skill", "hidden": true, "renderer": Lino.fk_renderer('parentHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.SkillsByParent.parent) ", "width": Lino.chars2width(21) } ];
    Lino.faculties.SkillsByParent.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillsByParent.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.SkillsByParent.insertPanel = Ext.extend(Lino.faculties.Skills.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/SkillsByParent",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillsByParent.detail;
    this.ls_insert_handler = Lino.faculties.SkillsByParent.insert;
    Lino.faculties.SkillsByParent.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillsByParent.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.SkillsByParent.insertPanel(p);
});
Lino.faculties.SkillsByParent.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.SkillsByParent.detailPanel = Ext.extend(Lino.faculties.Skills.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/SkillsByParent",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillsByParent.detail;
    this.ls_insert_handler = Lino.faculties.SkillsByParent.insert;
    Lino.faculties.SkillsByParent.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillsByParent.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.SkillsByParent.detailPanel(p);
});
Lino.faculties.SkillsByParent.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.SkillsByParent.GridPanel(p);
});
Lino.faculties.SkillsByParent.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByParent.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByParent", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.SkillsByType
Lino.faculties.SkillsByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/SkillsByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/SkillsByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/SkillsByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 17,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "parent" }, 'parentHidden', { "name": "name" }, { "name": "name_et" }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "remarks" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "children_summary" }, { "name": "move_buttons" }, { "name": "skill_type" }, 'skill_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 49,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillsByType.detail;
    this.ls_insert_handler = Lino.faculties.SkillsByType.insert;
    var ww = this.containing_window;
    var id1767 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno1768 = new Ext.form.NumberField({ "selectOnFocus": true });
    var parent1769 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/SkillsByType/parent" }) }) });
    var name1770 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et1771 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var affinity1772 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var remarks1773 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var mobile_item_disp1774 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1775 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1776 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1777 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var children_summary_disp1778 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp1779 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var skill_type1780 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/SkillsByType/skill_type" }) }) });
    this.before_row_edit = function(record) {
      remarks1773.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id1767, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(faculties.SkillsByType.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno1768, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(faculties.SkillsByType.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "parent", "editable": true, "editor": parent1769, "filter": { "type": "string" }, "header": "Parent skill", "renderer": Lino.fk_renderer('parentHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.SkillsByType.parent) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "name", "editable": true, "editor": name1770, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(faculties.SkillsByType.name) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "name_et", "editable": true, "editor": name_et1771, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(faculties.SkillsByType.name_et) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 5, "dataIndex": "affinity", "editable": true, "editor": affinity1772, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.SkillsByType.affinity) How much workers enjoy to get a new ticket requiring this skill.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "remarks", "editable": true, "editor": remarks1773, "filter": { "type": "string" }, "header": "M\u00e4rkused", "sortable": false, "tooltip": "(faculties.SkillsByType.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "children_summary", "editable": false, "header": "Children", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByType.children_summary) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.SkillsByType.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 13, "dataIndex": "skill_type", "editable": true, "editor": skill_type1780, "filter": { "type": "string" }, "header": "Oskuseliik", "hidden": true, "renderer": Lino.fk_renderer('skill_typeHidden','Lino.faculties.SkillTypes.detail'), "sortable": false, "tooltip": "(faculties.SkillsByType.skill_type) ", "width": Lino.chars2width(21) } ];
    Lino.faculties.SkillsByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillsByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.SkillsByType.insertPanel = Ext.extend(Lino.faculties.Skills.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/SkillsByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillsByType.detail;
    this.ls_insert_handler = Lino.faculties.SkillsByType.insert;
    Lino.faculties.SkillsByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillsByType.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.SkillsByType.insertPanel(p);
});
Lino.faculties.SkillsByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.SkillsByType.detailPanel = Ext.extend(Lino.faculties.Skills.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/SkillsByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.SkillsByType.detail;
    this.ls_insert_handler = Lino.faculties.SkillsByType.insert;
    Lino.faculties.SkillsByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.SkillsByType.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.SkillsByType.detailPanel(p);
});
Lino.faculties.SkillsByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.SkillsByType.GridPanel(p);
});
Lino.faculties.SkillsByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.SkillsByType.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/SkillsByType", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.OffersByEndUser
Lino.faculties.OffersByEndUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/OffersByEndUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/OffersByEndUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/OffersByEndUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskuse pakkumised",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "faculty" }, 'facultyHidden', { "name": "description" }, { "name": "affinity", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "user" }, 'userHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "end_user" }, 'end_userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 47,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersByEndUser.detail;
    this.ls_insert_handler = Lino.faculties.OffersByEndUser.insert;
    var ww = this.containing_window;
    var faculty514 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersByEndUser/faculty" }) }) });
    var description515 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var affinity516 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var id517 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno518 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var user519 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersByEndUser/user" }) }) });
    var mobile_item_disp520 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp521 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp522 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp523 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp524 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var end_user525 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersByEndUser/end_user" }) }) });
    this.before_row_edit = function(record) {
      description515.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "faculty", "editable": true, "editor": faculty514, "filter": { "type": "string" }, "header": "Oskus", "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.OffersByEndUser.faculty) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "description", "editable": true, "editor": description515, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(faculties.OffersByEndUser.description) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 2, "dataIndex": "affinity", "editable": true, "editor": affinity516, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.OffersByEndUser.affinity) How much this user likes to get a new ticket in this faculty.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id517, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.OffersByEndUser.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 4, "dataIndex": "seqno", "editable": true, "editor": seqno518, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(faculties.OffersByEndUser.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "user", "editable": true, "editor": user519, "filter": { "type": "string" }, "header": "Kasutaja", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(faculties.OffersByEndUser.user) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByEndUser.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByEndUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByEndUser.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByEndUser.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByEndUser.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "end_user", "editable": true, "editor": end_user525, "filter": { "type": "string" }, "header": "End user", "hidden": true, "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(faculties.OffersByEndUser.end_user) ", "width": Lino.chars2width(21) } ];
    Lino.faculties.OffersByEndUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersByEndUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.OffersByEndUser.insertPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/OffersByEndUser",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersByEndUser.detail;
    this.ls_insert_handler = Lino.faculties.OffersByEndUser.insert;
    Lino.faculties.OffersByEndUser.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersByEndUser.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.OffersByEndUser.insertPanel(p);
});
Lino.faculties.OffersByEndUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.OffersByEndUser.detailPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/OffersByEndUser",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersByEndUser.detail;
    this.ls_insert_handler = Lino.faculties.OffersByEndUser.insert;
    Lino.faculties.OffersByEndUser.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersByEndUser.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.OffersByEndUser.detailPanel(p);
});
Lino.faculties.OffersByEndUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.faculties.Offers.ParamsPanel({});
  return new Lino.faculties.OffersByEndUser.GridPanel(p);
});
Lino.faculties.OffersByEndUser.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByEndUser.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByEndUser", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.OffersBySkill
Lino.faculties.OffersBySkill.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/OffersBySkill",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/OffersBySkill','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/OffersBySkill','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskuse pakkumised",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "user" }, 'userHidden', { "name": "end_user" }, 'end_userHidden', { "name": "affinity", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "description" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "faculty" }, 'facultyHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 47,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersBySkill.detail;
    this.ls_insert_handler = Lino.faculties.OffersBySkill.insert;
    var ww = this.containing_window;
    var user1828 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersBySkill/user" }) }) });
    var end_user1829 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersBySkill/end_user" }) }) });
    var affinity1830 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var id1831 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno1832 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var description1833 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var mobile_item_disp1834 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1835 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1836 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1837 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp1838 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var faculty1839 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersBySkill/faculty" }) }) });
    this.before_row_edit = function(record) {
      description1833.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "user", "editable": true, "editor": user1828, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(faculties.OffersBySkill.user) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "end_user", "editable": true, "editor": end_user1829, "filter": { "type": "string" }, "header": "End user", "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(faculties.OffersBySkill.end_user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "affinity", "editable": true, "editor": affinity1830, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.OffersBySkill.affinity) How much this user likes to get a new ticket in this faculty.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id1831, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.OffersBySkill.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 4, "dataIndex": "seqno", "editable": true, "editor": seqno1832, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(faculties.OffersBySkill.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "description", "editable": true, "editor": description1833, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersBySkill.description) ", "width": Lino.chars2width(61) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersBySkill.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersBySkill.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersBySkill.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersBySkill.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersBySkill.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "faculty", "editable": true, "editor": faculty1839, "filter": { "type": "string" }, "header": "Oskus", "hidden": true, "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.OffersBySkill.faculty) ", "width": Lino.chars2width(21) } ];
    Lino.faculties.OffersBySkill.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersBySkill.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.OffersBySkill.insertPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/OffersBySkill",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersBySkill.detail;
    this.ls_insert_handler = Lino.faculties.OffersBySkill.insert;
    Lino.faculties.OffersBySkill.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersBySkill.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.OffersBySkill.insertPanel(p);
});
Lino.faculties.OffersBySkill.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.OffersBySkill.detailPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/OffersBySkill",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersBySkill.detail;
    this.ls_insert_handler = Lino.faculties.OffersBySkill.insert;
    Lino.faculties.OffersBySkill.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersBySkill.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.OffersBySkill.detailPanel(p);
});
Lino.faculties.OffersBySkill.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.faculties.Offers.ParamsPanel({});
  return new Lino.faculties.OffersBySkill.GridPanel(p);
});
Lino.faculties.OffersBySkill.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersBySkill.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersBySkill", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.DemandsBySkill
Lino.faculties.DemandsBySkill.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/DemandsBySkill",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/DemandsBySkill','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/DemandsBySkill','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Oskuste vajadused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "demander" }, 'demanderHidden', { "name": "importance", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "skill" }, 'skillHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 46,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.DemandsBySkill.detail;
    this.ls_insert_handler = Lino.faculties.DemandsBySkill.insert;
    var ww = this.containing_window;
    var demander1842 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/DemandsBySkill/demander" }) }) });
    var importance1843 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var id1844 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp1845 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1846 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1847 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1848 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var skill1849 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/DemandsBySkill/skill" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "demander", "editable": true, "editor": demander1842, "filter": { "type": "string" }, "header": "Demander", "renderer": Lino.fk_renderer('demanderHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(faculties.DemandsBySkill.demander) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 1, "dataIndex": "importance", "editable": true, "editor": importance1843, "filter": { "type": "numeric" }, "format": "0", "header": "Importance", "sortable": true, "tooltip": "(faculties.DemandsBySkill.importance) How important this skill is for this demand. A number between -100 and +100.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id1844, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.DemandsBySkill.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsBySkill.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsBySkill.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsBySkill.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsBySkill.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "skill", "editable": true, "editor": skill1849, "filter": { "type": "string" }, "header": "Oskus", "hidden": true, "renderer": Lino.fk_renderer('skillHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.DemandsBySkill.skill) ", "width": Lino.chars2width(21) } ];
    Lino.faculties.DemandsBySkill.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.DemandsBySkill.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsBySkill.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsBySkill.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.DemandsBySkill.insertPanel = Ext.extend(Lino.faculties.Demands.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/DemandsBySkill",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.DemandsBySkill.detail;
    this.ls_insert_handler = Lino.faculties.DemandsBySkill.insert;
    Lino.faculties.DemandsBySkill.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.DemandsBySkill.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.DemandsBySkill.insertPanel(p);
});
Lino.faculties.DemandsBySkill.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsBySkill.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsBySkill.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.DemandsBySkill.detailPanel = Ext.extend(Lino.faculties.Demands.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/faculties/DemandsBySkill",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.DemandsBySkill.detail;
    this.ls_insert_handler = Lino.faculties.DemandsBySkill.insert;
    Lino.faculties.DemandsBySkill.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.DemandsBySkill.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.DemandsBySkill.detailPanel(p);
});
Lino.faculties.DemandsBySkill.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsBySkill.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.DemandsBySkill.GridPanel(p);
});
Lino.faculties.DemandsBySkill.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsBySkill", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.DemandsByDemander
Lino.faculties.DemandsByDemander.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/DemandsByDemander",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/DemandsByDemander','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/DemandsByDemander','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Wanted skills",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 11,
  ls_store_fields : [ { "name": "skill" }, 'skillHidden', { "name": "importance", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "demander" }, 'demanderHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 46,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.DemandsByDemander.detail;
    this.ls_insert_handler = Lino.faculties.DemandsByDemander.insert;
    var ww = this.containing_window;
    var skill6727 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/DemandsByDemander/skill" }) }) });
    var importance6728 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var id6729 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp6730 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6731 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6732 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6733 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var demander6734 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/DemandsByDemander/demander" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "skill", "editable": true, "editor": skill6727, "filter": { "type": "string" }, "header": "Oskus", "renderer": Lino.fk_renderer('skillHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.DemandsByDemander.skill) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 1, "dataIndex": "importance", "editable": true, "editor": importance6728, "filter": { "type": "numeric" }, "format": "0", "header": "Importance", "sortable": true, "tooltip": "(faculties.DemandsByDemander.importance) How important this skill is for this demand. A number between -100 and +100.", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6729, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.DemandsByDemander.id) ", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsByDemander.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsByDemander.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsByDemander.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.DemandsByDemander.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "demander", "editable": true, "editor": demander6734, "filter": { "type": "string" }, "header": "Demander", "hidden": true, "renderer": Lino.fk_renderer('demanderHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(faculties.DemandsByDemander.demander) ", "width": Lino.chars2width(21) } ];
    Lino.faculties.DemandsByDemander.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.DemandsByDemander.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsByDemander.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsByDemander.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.DemandsByDemander.insertPanel = Ext.extend(Lino.faculties.DemandsByDemander.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/DemandsByDemander",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.DemandsByDemander.detail;
    this.ls_insert_handler = Lino.faculties.DemandsByDemander.insert;
    Lino.faculties.DemandsByDemander.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.DemandsByDemander.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.DemandsByDemander.insertPanel(p);
});
Lino.faculties.DemandsByDemander.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsByDemander.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsByDemander.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.DemandsByDemander.detailPanel = Ext.extend(Lino.faculties.DemandsByDemander.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/faculties/DemandsByDemander",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.DemandsByDemander.detail;
    this.ls_insert_handler = Lino.faculties.DemandsByDemander.insert;
    Lino.faculties.DemandsByDemander.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.DemandsByDemander.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(40) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.DemandsByDemander.detailPanel(p);
});
Lino.faculties.DemandsByDemander.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.DemandsByDemander.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.DemandsByDemander.GridPanel(p);
});
Lino.faculties.DemandsByDemander.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/DemandsByDemander", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.OffersByDemander
Lino.faculties.OffersByDemander.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/OffersByDemander",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/OffersByDemander','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/OffersByDemander','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Oskuse pakkumised",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 16,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "user" }, 'userHidden', { "name": "faculty" }, 'facultyHidden', { "name": "end_user" }, 'end_userHidden', { "name": "affinity", "type": "int", "useNull": true }, { "name": "description" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 47,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersByDemander.detail;
    this.ls_insert_handler = Lino.faculties.OffersByDemander.insert;
    var ww = this.containing_window;
    var id6736 = new Ext.form.NumberField({ "selectOnFocus": true });
    var seqno6737 = new Ext.form.NumberField({ "selectOnFocus": true });
    var user6738 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersByDemander/user" }) }) });
    var faculty6739 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Oskus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersByDemander/faculty" }) }) });
    var end_user6740 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/OffersByDemander/end_user" }) }) });
    var affinity6741 = new Ext.form.NumberField({ "selectOnFocus": true, "value": 100 });
    var description6742 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var mobile_item_disp6743 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6744 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6745 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6746 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp6747 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description6742.refresh();
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id6736, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(faculties.OffersByDemander.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 1, "dataIndex": "seqno", "editable": true, "editor": seqno6737, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(faculties.OffersByDemander.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user6738, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(faculties.OffersByDemander.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "faculty", "editable": true, "editor": faculty6739, "filter": { "type": "string" }, "header": "Oskus", "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(faculties.OffersByDemander.faculty) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "end_user", "editable": true, "editor": end_user6740, "filter": { "type": "string" }, "header": "End user", "renderer": Lino.fk_renderer('end_userHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(faculties.OffersByDemander.end_user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "affinity", "editable": true, "editor": affinity6741, "filter": { "type": "numeric" }, "format": "0", "header": "Affinity", "sortable": true, "tooltip": "(faculties.OffersByDemander.affinity) How much this user likes to get a new ticket in this faculty.A number between -100 and +100.", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "description", "editable": true, "editor": description6742, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(faculties.OffersByDemander.description) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByDemander.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByDemander.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByDemander.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByDemander.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(faculties.OffersByDemander.move_buttons) ", "width": Lino.chars2width(6) } ];
    Lino.faculties.OffersByDemander.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersByDemander.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.OffersByDemander.insertPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/OffersByDemander",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersByDemander.detail;
    this.ls_insert_handler = Lino.faculties.OffersByDemander.insert;
    Lino.faculties.OffersByDemander.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersByDemander.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.OffersByDemander.insertPanel(p);
});
Lino.faculties.OffersByDemander.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.OffersByDemander.detailPanel = Ext.extend(Lino.faculties.Offers.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/faculties/OffersByDemander",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.OffersByDemander.detail;
    this.ls_insert_handler = Lino.faculties.OffersByDemander.insert;
    Lino.faculties.OffersByDemander.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.OffersByDemander.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.OffersByDemander.detailPanel(p);
});
Lino.faculties.OffersByDemander.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.faculties.Offers.ParamsPanel({});
  return new Lino.faculties.OffersByDemander.GridPanel(p);
});
Lino.faculties.OffersByDemander.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.OffersByDemander.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/OffersByDemander", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class faculties.AssignableWorkersByTicket
Lino.faculties.AssignableWorkersByTicket.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/faculties/AssignableWorkersByTicket",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/faculties/AssignableWorkersByTicket','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/faculties/AssignableWorkersByTicket','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  cell_edit : true,
  title : "Assignable workers",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 63,
  ls_store_fields : [ { "name": "username" }, { "name": "id", "type": "int" }, { "name": "email" }, { "name": "language" }, 'languageHidden', { "name": "url" }, { "name": "phone" }, { "name": "gsm" }, { "name": "fax" }, { "name": "country" }, 'countryHidden', { "name": "city" }, 'cityHidden', { "name": "zip_code" }, { "name": "region" }, 'regionHidden', { "name": "addr1" }, { "name": "street_prefix" }, { "name": "street" }, { "name": "street_no" }, { "name": "street_box" }, { "name": "addr2" }, { "name": "name" }, { "name": "remarks" }, { "name": "title" }, { "name": "first_name" }, { "name": "middle_name" }, { "name": "last_name" }, { "name": "gender" }, 'genderHidden', { "name": "birth_date" }, { "name": "private", "type": "boolean" }, { "name": "modified" }, { "name": "created" }, { "name": "password" }, { "name": "last_login" }, { "name": "timezone" }, { "name": "profile" }, 'profileHidden', { "name": "initials" }, { "name": "callme_mode", "type": "boolean" }, { "name": "verification_code" }, { "name": "user_state" }, 'user_stateHidden', { "name": "access_class" }, 'access_classHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "open_session_on_new_ticket", "type": "boolean" }, { "name": "notify_myself", "type": "boolean" }, { "name": "mail_mode" }, 'mail_modeHidden', { "name": "about_me" }, { "name": "name_column" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "created_natural" }, { "name": "age" }, { "name": "mti_navigator" }, { "name": "address_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 1,
  ls_grid_configs : [  ],
  content_type : 8,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.AssignableWorkersByTicket.detail;
    this.ls_insert_handler = Lino.faculties.AssignableWorkersByTicket.insert;
    var ww = this.containing_window;
    var username6749 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var id6750 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email6751 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language6752 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url6753 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone6754 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm6755 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax6756 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country6757 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Riik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AssignableWorkersByTicket/country" }) }) });
    var city6758 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "forceSelection": false, "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AssignableWorkersByTicket/city" }) }) });
    var zip_code6759 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region6760 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Asum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AssignableWorkersByTicket/region" }) }) });
    var addr16761 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix6762 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street6763 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no6764 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box6765 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr26766 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name6767 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks6768 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title6769 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var first_name6770 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name6771 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var last_name6772 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender6773 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date6774 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var private6775 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var modified6776 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created6777 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password6778 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login6779 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone6780 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AssignableWorkersByTicket/timezone" }) }) });
    var profile6781 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var initials6782 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode6783 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code6784 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state6785 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class6786 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type6787 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/faculties/AssignableWorkersByTicket/event_type" }) }) });
    var open_session_on_new_ticket6788 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself6789 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode6790 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox6791 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "about_me", "title": "About me", "value": "<br/>" });
    var name_column_disp6792 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6793 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6794 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6795 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6796 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp6797 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp6798 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp6799 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp6800 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city6758.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city6758.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region6760.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks6768.refresh();
      timezone6780.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox6791.refresh();
    };
    this.onRender = function(ct, position) {
      country6757.on('change',Lino.chooser_handler(city6758,'country'));
      region6760.on('change',Lino.chooser_handler(city6758,'region'));
      country6757.on('change',Lino.chooser_handler(region6760,'country'));
      Lino.faculties.AssignableWorkersByTicket.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username6749, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.username) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 1, "dataIndex": "id", "editable": true, "editor": id6750, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.id) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "email", "editable": true, "editor": email6751, "filter": { "type": "string" }, "header": "e-mail address", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.email) The primary email address.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "language", "editable": true, "editor": language6752, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.language) The language to use when communicating with this partner.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "url", "editable": true, "editor": url6753, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.url) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "phone", "editable": true, "editor": phone6754, "filter": { "type": "string" }, "header": "Phone", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.phone) The primary phone number.  Note that Lino does not ignore\nformatting characters in phone numbers when searching.  For\nexample, if you enter \"087/12.34.56\" as a phone number, then a\nsearch for phone number containing \"1234\" will not find it.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "gsm", "editable": true, "editor": gsm6755, "filter": { "type": "string" }, "header": "GSM", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.gsm) The primary mobile phone number.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "fax", "editable": true, "editor": fax6756, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "country", "editable": true, "editor": country6757, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "renderer": Lino.fk_renderer('countryHidden','Lino.countries.Countries.detail'), "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.country) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "city", "editable": true, "editor": city6758, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "renderer": Lino.fk_renderer('cityHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "zip_code", "editable": true, "editor": zip_code6759, "filter": { "type": "string" }, "header": "Zip code", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.zip_code) ", "width": Lino.chars2width(12) }, { "colIndex": 11, "dataIndex": "region", "editable": true, "editor": region6760, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "renderer": Lino.fk_renderer('regionHidden','Lino.countries.Places.detail'), "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.region) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "addr1", "editable": true, "editor": addr16761, "filter": { "type": "string" }, "header": "Address line before street", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.addr1) Address line before street", "width": Lino.chars2width(22) }, { "colIndex": 13, "dataIndex": "street_prefix", "editable": true, "editor": street_prefix6762, "filter": { "type": "string" }, "header": "Street prefix", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.street_prefix) Text to print before name of street, but to ignore for sorting.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "street", "editable": true, "editor": street6763, "filter": { "type": "string" }, "header": "T\u00e4nav", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.street) Name of street, without house number.", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "street_no", "editable": true, "editor": street_no6764, "filter": { "type": "string" }, "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.street_no) House number.", "width": Lino.chars2width(12) }, { "colIndex": 16, "dataIndex": "street_box", "editable": true, "editor": street_box6765, "filter": { "type": "string" }, "header": "Box", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.street_box) Text to print after street nuber on the same line.", "width": Lino.chars2width(12) }, { "colIndex": 17, "dataIndex": "addr2", "editable": true, "editor": addr26766, "filter": { "type": "string" }, "header": "Address line after street", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.addr2) Address line to print below street line.", "width": Lino.chars2width(22) }, { "colIndex": 18, "dataIndex": "name", "editable": true, "editor": name6767, "filter": { "type": "string" }, "header": "Nimi", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.name) The full name of this partner. Used for alphabetic sorting.\nSubclasses may hide this field and fill it automatically,\ne.g. saving a Person will automatically set her\nname field to \"last_name, first_name\".", "width": Lino.chars2width(22) }, { "colIndex": 19, "dataIndex": "remarks", "editable": true, "editor": remarks6768, "filter": { "type": "string" }, "header": "M\u00e4rkused", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.remarks) ", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "title", "editable": true, "editor": title6769, "filter": { "type": "string" }, "header": "Title", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.title) An optional name prefix like \"Dr.\" or \"PhD\", used to specify a\nprofessional position or academic qualification.", "width": Lino.chars2width(22) }, { "colIndex": 21, "dataIndex": "first_name", "editable": true, "editor": first_name6770, "filter": { "type": "string" }, "header": "Eesnimi", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.first_name) The first name, also known as given name.", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "middle_name", "editable": true, "editor": middle_name6771, "filter": { "type": "string" }, "header": "Middle name", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.middle_name) A space-separated list of all middle names.", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "last_name", "editable": true, "editor": last_name6772, "filter": { "type": "string" }, "header": "Perenimi", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.last_name) The last name, also known as family name.", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "gender", "editable": true, "editor": gender6773, "filter": { "type": "string" }, "header": "Sugu", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.gender) The sex of this person (male or female).", "width": Lino.chars2width(10) }, { "colIndex": 25, "dataIndex": "birth_date", "editable": true, "editor": birth_date6774, "filter": { "type": "string" }, "header": "S\u00fcnnip\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.birth_date) Uncomplete dates are allowed, e.g. \n\"00.00.1980\" means \"some day in 1980\", \n\"00.07.1980\" means \"in July 1980\"\nor \"23.07.0000\" means \"on a 23th of July\".", "width": Lino.chars2width(13) }, { "colIndex": 26, "dataIndex": "private", "editable": true, "filter": { "type": "boolean" }, "header": "Private", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.private) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 27, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 28, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 29, "dataIndex": "password", "editable": true, "editor": password6778, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.password) ", "width": Lino.chars2width(22) }, { "colIndex": 30, "dataIndex": "last_login", "editable": true, "editor": last_login6779, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 31, "dataIndex": "timezone", "editable": true, "editor": timezone6780, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 32, "dataIndex": "profile", "editable": true, "editor": profile6781, "filter": { "type": "string" }, "header": "Kasutajaliik", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.profile) ", "width": Lino.chars2width(25) }, { "colIndex": 33, "dataIndex": "initials", "editable": true, "editor": initials6782, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "callme_mode", "editable": true, "filter": { "type": "boolean" }, "header": "Others may contact me", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.callme_mode) Whether other users can see my contact data.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 35, "dataIndex": "verification_code", "editable": true, "editor": verification_code6784, "filter": { "type": "string" }, "header": "verification code", "hidden": true, "sortable": true, "tooltip": "(faculties.AssignableWorkersByTicket.verification_code) A random string set for every new user. Used for\nonline_registration.", "width": Lino.chars2width(22) }, { "colIndex": 36, "dataIndex": "user_state", "editable": true, "editor": user_state6785, "filter": { "type": "string" }, "header": "Kasutaja olek", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 37, "dataIndex": "access_class", "editable": true, "editor": access_class6786, "filter": { "type": "string" }, "header": "Default access class", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.access_class) The default access class for your calendar events and tasks.", "width": Lino.chars2width(13) }, { "colIndex": 38, "dataIndex": "event_type", "editable": true, "editor": event_type6787, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 39, "dataIndex": "open_session_on_new_ticket", "editable": true, "filter": { "type": "boolean" }, "header": "Open session on new ticket", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.open_session_on_new_ticket) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 40, "dataIndex": "notify_myself", "editable": true, "filter": { "type": "boolean" }, "header": "Notify myself", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.notify_myself) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 41, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode6790, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 42, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 44, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 45, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 46, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.age) ", "width": Lino.chars2width(31) }, { "colIndex": 50, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 51, "dataIndex": "address_column", "editable": false, "header": "Aadres", "hidden": true, "sortable": false, "tooltip": "(faculties.AssignableWorkersByTicket.address_column) ", "width": Lino.chars2width(31) } ];
    Lino.faculties.AssignableWorkersByTicket.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.AssignableWorkersByTicket.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.AssignableWorkersByTicket.insertPanel = Ext.extend(Lino.users.Users.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/faculties/AssignableWorkersByTicket",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.AssignableWorkersByTicket.detail;
    this.ls_insert_handler = Lino.faculties.AssignableWorkersByTicket.insert;
    Lino.faculties.AssignableWorkersByTicket.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.AssignableWorkersByTicket.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.faculties.AssignableWorkersByTicket.insertPanel(p);
});
Lino.faculties.AssignableWorkersByTicket.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.faculties.AssignableWorkersByTicket.detailPanel = Ext.extend(Lino.users.Users.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "update_widgets", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the widgets for this user.") }, "menu_item_text": "Update widgets", "overflowText": "Update widgets", "panel_btn_handler": Lino.row_action_handler('update_widgets','GET',null), "text": "\u00a0\u26a1\u00a0" }, { "auto_save": true, "itemId": "change_password", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Change the password of this user.") }, "menu_item_text": "Muuda salas\u00f5na", "overflowText": "Muuda salas\u00f5na", "panel_btn_handler": Lino.param_action_handler(Lino.users.Users.change_password), "text": " <font size=\"4\">\u2731</font>" } ],
  ls_url: "/faculties/AssignableWorkersByTicket",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.faculties.AssignableWorkersByTicket.detail;
    this.ls_insert_handler = Lino.faculties.AssignableWorkersByTicket.insert;
    Lino.faculties.AssignableWorkersByTicket.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.faculties.AssignableWorkersByTicket.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.faculties.AssignableWorkersByTicket.detailPanel(p);
});
Lino.faculties.AssignableWorkersByTicket.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.users.Users.ParamsPanel({});
  return new Lino.faculties.AssignableWorkersByTicket.GridPanel(p);
});
Lino.faculties.AssignableWorkersByTicket.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.del_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "del_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.ins_company = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "ins_company", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.update_widgets = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "update_widgets", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.ins_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "ins_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.del_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "del_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.ins_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "ins_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.del_partner = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "del_partner", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.ins_person = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "ins_person", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.del_user = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "del_user", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.faculties.AssignableWorkersByTicket.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/faculties/AssignableWorkersByTicket", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.SessionsByTicket
Lino.clocking.SessionsByTicket.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/SessionsByTicket",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/SessionsByTicket','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/SessionsByTicket','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Istungid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 25,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "summary" }, { "name": "start_time" }, { "name": "end_time" }, { "name": "break_time" }, { "name": "duration" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "session_type" }, 'session_typeHidden', { "name": "description" }, { "name": "faculty" }, 'facultyHidden', { "name": "reporting_type" }, 'reporting_typeHidden', { "name": "ticket_no" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "ticket" }, 'ticketHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 52,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.SessionsByTicket.detail;
    this.ls_insert_handler = Lino.clocking.SessionsByTicket.insert;
    var ww = this.containing_window;
    var start_date6802 = new Lino.DateField({ "selectOnFocus": true });
    var summary6803 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var start_time6804 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time6805 = new Lino.TimeField({ "selectOnFocus": true });
    var break_time6806 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "maxLength": 6, "selectOnFocus": true });
    var duration6807 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var user6808 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/SessionsByTicket/user" }) }) });
    var id6809 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var end_date6810 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var session_type6811 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Istungiliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/SessionsByTicket/session_type" }) }) });
    var description6812 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var faculty6813 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Oskus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/SessionsByTicket/faculty" }) }) });
    var reporting_type6814 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.clocking.ReportingTypes) });
    var ticket_no_disp6815 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6816 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6817 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6818 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6819 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var ticket6820 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/SessionsByTicket/ticket" }) }) });
    this.before_row_edit = function(record) {
      description6812.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6802, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.SessionsByTicket.start_date) The date when you started to work.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary6803, "filter": { "type": "string" }, "header": "Kokkuv\u00f5te", "sortable": true, "tooltip": "(clocking.SessionsByTicket.summary) Summary of the session.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "start_time", "editable": true, "editor": start_time6804, "header": "Start time", "sortable": true, "tooltip": "(clocking.SessionsByTicket.start_time) The time (in hh:mm) when you started working on this\nsession.", "width": Lino.chars2width(9) }, { "colIndex": 3, "dataIndex": "end_time", "editable": true, "editor": end_time6805, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(clocking.SessionsByTicket.end_time) The time (in hh:mm) when you stopped to work. This is empty\nas long as you are busy with this session.", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 4, "dataIndex": "break_time", "editable": true, "editor": break_time6806, "filter": { "type": "string" }, "format": "", "header": "Paus", "sortable": true, "tooltip": "(clocking.SessionsByTicket.break_time) The time (in hh:mm) to remove from the duration resulting\nfrom the difference between start_time and\nend_time.", "width": Lino.chars2width(8) }, { "align": "right", "colIndex": 5, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "sortable": false, "tooltip": "(clocking.SessionsByTicket.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 6, "dataIndex": "user", "editable": true, "editor": user6808, "filter": { "type": "string" }, "header": "T\u00f6\u00f6taja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(clocking.SessionsByTicket.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 7, "dataIndex": "id", "editable": true, "editor": id6809, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.SessionsByTicket.id) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date6810, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(clocking.SessionsByTicket.end_date) Leave this field blank if it is the same date as start_date.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "session_type", "editable": true, "editor": session_type6811, "filter": { "type": "string" }, "header": "Istungiliik", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.session_type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "description", "editable": true, "editor": description6812, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.description) ", "width": Lino.chars2width(61) }, { "colIndex": 11, "dataIndex": "faculty", "editable": true, "editor": faculty6813, "filter": { "type": "string" }, "header": "Oskus", "hidden": true, "renderer": Lino.fk_renderer('facultyHidden','Lino.faculties.Skills.detail'), "sortable": false, "tooltip": "(clocking.SessionsByTicket.faculty) The faculty that has been used during this session. On a new\nsession this defaults to the needed faculty currently specified\non the ticket.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "reporting_type", "editable": true, "editor": reporting_type6814, "filter": { "type": "string" }, "header": "Reporting type", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.reporting_type) ", "width": Lino.chars2width(11) }, { "colIndex": 13, "dataIndex": "ticket_no", "editable": false, "header": "Ticket #", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.ticket_no) ", "width": Lino.chars2width(9) }, { "colIndex": 14, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(clocking.SessionsByTicket.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "ticket", "editable": true, "editor": ticket6820, "filter": { "type": "string" }, "header": "Lipik", "hidden": true, "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(clocking.SessionsByTicket.ticket) ", "width": Lino.chars2width(21) } ];
    Lino.clocking.SessionsByTicket.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionsByTicket.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.SessionsByTicket.insertPanel = Ext.extend(Lino.clocking.Sessions.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/SessionsByTicket",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.SessionsByTicket.detail;
    this.ls_insert_handler = Lino.clocking.SessionsByTicket.insert;
    Lino.clocking.SessionsByTicket.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionsByTicket.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.SessionsByTicket.insertPanel(p);
});
Lino.clocking.SessionsByTicket.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.SessionsByTicket.detailPanel = Ext.extend(Lino.clocking.Sessions.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/SessionsByTicket",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.SessionsByTicket.detail;
    this.ls_insert_handler = Lino.clocking.SessionsByTicket.insert;
    Lino.clocking.SessionsByTicket.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionsByTicket.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.SessionsByTicket.detailPanel(p);
});
Lino.clocking.SessionsByTicket.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.Sessions.ParamsPanel({});
  return new Lino.clocking.SessionsByTicket.GridPanel(p);
});
Lino.clocking.SessionsByTicket.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByTicket.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByTicket", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.SessionsByReport
Lino.clocking.SessionsByReport.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/SessionsByReport",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/SessionsByReport','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/SessionsByReport','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Istungid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "name": "end_time" }, { "name": "break_time" }, { "name": "my_description" }, { "name": "vc0" }, { "name": "vc1" }, { "name": "vc2" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 52,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.SessionsByReport.detail;
    this.ls_insert_handler = Lino.clocking.SessionsByReport.insert;
    var ww = this.containing_window;
    var start_date2514 = new Lino.DateField({ "selectOnFocus": true });
    var start_time2515 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time2516 = new Lino.TimeField({ "selectOnFocus": true });
    var break_time2517 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "maxLength": 6, "selectOnFocus": true });
    var my_description_disp2518 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var vc02519 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc12520 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc22521 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date2514, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.SessionsByReport.start_date) The date when you started to work.", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "start_time", "editable": true, "editor": start_time2515, "header": "Start time", "sortable": true, "tooltip": "(clocking.SessionsByReport.start_time) The time (in hh:mm) when you started working on this\nsession.", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "end_time", "editable": true, "editor": end_time2516, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(clocking.SessionsByReport.end_time) The time (in hh:mm) when you stopped to work. This is empty\nas long as you are busy with this session.", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 3, "dataIndex": "break_time", "editable": true, "editor": break_time2517, "filter": { "type": "string" }, "format": "", "header": "Paus", "sortable": true, "tooltip": "(clocking.SessionsByReport.break_time) The time (in hh:mm) to remove from the duration resulting\nfrom the difference between start_time and\nend_time.", "width": Lino.chars2width(8) }, { "colIndex": 4, "dataIndex": "my_description", "editable": false, "header": "Kirjeldus", "sortable": false, "tooltip": "(clocking.SessionsByReport.my_description) ", "width": Lino.chars2width(51) }, { "align": "right", "colIndex": 5, "dataIndex": "vc0", "editable": false, "format": "", "header": "Regular", "sortable": false, "tooltip": "(clocking.SessionsByReport.vc0) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 6, "dataIndex": "vc1", "editable": false, "format": "", "header": "Extra", "sortable": false, "tooltip": "(clocking.SessionsByReport.vc1) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 7, "dataIndex": "vc2", "editable": false, "format": "", "header": "Free", "sortable": false, "tooltip": "(clocking.SessionsByReport.vc2) ", "width": Lino.chars2width(6) } ];
    Lino.clocking.SessionsByReport.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionsByReport.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.SessionsByReport.insertPanel = Ext.extend(Lino.clocking.Sessions.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/SessionsByReport",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.SessionsByReport.detail;
    this.ls_insert_handler = Lino.clocking.SessionsByReport.insert;
    Lino.clocking.SessionsByReport.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionsByReport.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.SessionsByReport.insertPanel(p);
});
Lino.clocking.SessionsByReport.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.SessionsByReport.detailPanel = Ext.extend(Lino.clocking.Sessions.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/SessionsByReport",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.SessionsByReport.detail;
    this.ls_insert_handler = Lino.clocking.SessionsByReport.insert;
    Lino.clocking.SessionsByReport.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.SessionsByReport.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.SessionsByReport.detailPanel(p);
});
Lino.clocking.SessionsByReport.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.Sessions.ParamsPanel({});
  return new Lino.clocking.SessionsByReport.GridPanel(p);
});
Lino.clocking.SessionsByReport.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.SessionsByReport.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/SessionsByReport", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.TicketsByReport
Lino.clocking.TicketsByReport.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/TicketsByReport",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/TicketsByReport','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/TicketsByReport','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "overview" }, { "name": "project" }, 'projectHidden', { "name": "state" }, 'stateHidden', { "name": "vc0" }, { "name": "vc1" }, { "name": "vc2" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 43,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.TicketsByReport.detail;
    this.ls_insert_handler = Lino.clocking.TicketsByReport.insert;
    var ww = this.containing_window;
    var id3297 = new Ext.form.NumberField({ "selectOnFocus": true });
    var overview_disp3298 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project3299 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/TicketsByReport/project" }) }) });
    var state3300 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var vc03301 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc13302 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc23303 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3297, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(clocking.TicketsByReport.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(clocking.TicketsByReport.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "project", "editable": true, "editor": project3299, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "renderer": Lino.fk_renderer('projectHidden','Lino.tickets.Projects.detail'), "sortable": false, "tooltip": "(clocking.TicketsByReport.project) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "state", "editable": true, "editor": state3300, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(clocking.TicketsByReport.state) ", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 4, "dataIndex": "vc0", "editable": false, "format": "", "header": "Regular", "sortable": false, "tooltip": "(clocking.TicketsByReport.vc0) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 5, "dataIndex": "vc1", "editable": false, "format": "", "header": "Extra", "sortable": false, "tooltip": "(clocking.TicketsByReport.vc1) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 6, "dataIndex": "vc2", "editable": false, "format": "", "header": "Free", "sortable": false, "tooltip": "(clocking.TicketsByReport.vc2) ", "width": Lino.chars2width(6) } ];
    Lino.clocking.TicketsByReport.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.TicketsByReport.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.TicketsByReport.insertPanel = Ext.extend(Lino.tickets.Tickets.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/TicketsByReport",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.TicketsByReport.detail;
    this.ls_insert_handler = Lino.clocking.TicketsByReport.insert;
    Lino.clocking.TicketsByReport.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.TicketsByReport.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.TicketsByReport.insertPanel(p);
});
Lino.clocking.TicketsByReport.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.TicketsByReport.detailPanel = Ext.extend(Lino.tickets.Tickets.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/TicketsByReport",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.TicketsByReport.detail;
    this.ls_insert_handler = Lino.clocking.TicketsByReport.insert;
    Lino.clocking.TicketsByReport.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.TicketsByReport.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.TicketsByReport.detailPanel(p);
});
Lino.clocking.TicketsByReport.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Tickets.ParamsPanel({});
  return new Lino.clocking.TicketsByReport.GridPanel(p);
});
Lino.clocking.TicketsByReport.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.spawn_triggered = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "spawn_triggered", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.create_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "create_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.edit_vote = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "edit_vote", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.ProjectsByReport
Lino.clocking.ProjectsByReport.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/ProjectsByReport",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/ProjectsByReport','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/ProjectsByReport','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Eesm\u00e4rgid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "active_tickets" }, { "name": "vc0" }, { "name": "vc1" }, { "name": "vc2" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 41,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ProjectsByReport.detail;
    this.ls_insert_handler = Lino.clocking.ProjectsByReport.insert;
    var ww = this.containing_window;
    var ref6822 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name6823 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var active_tickets_disp6824 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var vc06825 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc16826 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc26827 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref6822, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(clocking.ProjectsByReport.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name6823, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(clocking.ProjectsByReport.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "active_tickets", "editable": false, "header": "Lipikud", "sortable": false, "tooltip": "(clocking.ProjectsByReport.active_tickets) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "vc0", "editable": false, "format": "", "header": "Regular", "sortable": false, "tooltip": "(clocking.ProjectsByReport.vc0) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 4, "dataIndex": "vc1", "editable": false, "format": "", "header": "Extra", "sortable": false, "tooltip": "(clocking.ProjectsByReport.vc1) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 5, "dataIndex": "vc2", "editable": false, "format": "", "header": "Free", "sortable": false, "tooltip": "(clocking.ProjectsByReport.vc2) ", "width": Lino.chars2width(6) } ];
    Lino.clocking.ProjectsByReport.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ProjectsByReport.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ProjectsByReport.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ProjectsByReport.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.ProjectsByReport.insertPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/ProjectsByReport",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ProjectsByReport.detail;
    this.ls_insert_handler = Lino.clocking.ProjectsByReport.insert;
    Lino.clocking.ProjectsByReport.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ProjectsByReport.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.ProjectsByReport.insertPanel(p);
});
Lino.clocking.ProjectsByReport.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ProjectsByReport.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ProjectsByReport.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ProjectsByReport.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.ProjectsByReport.detailPanel = Ext.extend(Lino.tickets.Projects.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/clocking/ProjectsByReport",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ProjectsByReport.detail;
    this.ls_insert_handler = Lino.clocking.ProjectsByReport.insert;
    Lino.clocking.ProjectsByReport.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ProjectsByReport.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.ProjectsByReport.detailPanel(p);
});
Lino.clocking.ProjectsByReport.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ProjectsByReport.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.tickets.Projects.ParamsPanel({});
  return new Lino.clocking.ProjectsByReport.GridPanel(p);
});
Lino.clocking.ProjectsByReport.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ProjectsByReport", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class clocking.ReportsByPartner
Lino.clocking.ReportsByPartner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/clocking/ReportsByPartner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/ReportsByPartner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/ReportsByPartner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Service Report", "overflowText": "Service Report", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Service Reports",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 23,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "interesting_for" }, 'interesting_forHidden', { "name": "ticket_state" }, 'ticket_stateHidden', { "name": "printed" }, { "name": "id", "type": "int" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "printed_by" }, 'printed_byHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 51,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ReportsByPartner.detail;
    this.ls_insert_handler = Lino.clocking.ReportsByPartner.insert;
    var ww = this.containing_window;
    var start_date6829 = new Lino.DateField({ "selectOnFocus": true });
    var end_date6830 = new Lino.DateField({ "selectOnFocus": true });
    var user6831 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ReportsByPartner/user" }) }) });
    var interesting_for6832 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ReportsByPartner/interesting_for" }) }) });
    var ticket_state6833 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var printed_disp6834 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id6835 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var company6836 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ReportsByPartner/company" }) }) });
    var contact_person6837 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ReportsByPartner/contact_person" }) }) });
    var contact_role6838 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/clocking/ReportsByPartner/contact_role" }) }) });
    var printed_by6839 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var mobile_item_disp6840 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6841 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6842 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6843 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person6837.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company6836.on('change',Lino.chooser_handler(contact_person6837,'company'));
      Lino.clocking.ReportsByPartner.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6829, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.ReportsByPartner.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "end_date", "editable": true, "editor": end_date6830, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "sortable": true, "tooltip": "(clocking.ReportsByPartner.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user6831, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(clocking.ReportsByPartner.user) This can be empty and will then show the working time of all\nusers.", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "interesting_for", "editable": true, "editor": interesting_for6832, "filter": { "type": "string" }, "header": "Interesting for", "renderer": Lino.fk_renderer('interesting_forHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(clocking.ReportsByPartner.interesting_for) Only tickets interesting for this partner.", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "ticket_state", "editable": true, "editor": ticket_state6833, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(clocking.ReportsByPartner.ticket_state) Only tickets in this state.", "width": Lino.chars2width(12) }, { "colIndex": 5, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "sortable": false, "tooltip": "(clocking.ReportsByPartner.printed) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id6835, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(clocking.ReportsByPartner.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "company", "editable": true, "editor": company6836, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(clocking.ReportsByPartner.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "contact_person", "editable": true, "editor": contact_person6837, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(clocking.ReportsByPartner.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "contact_role", "editable": true, "editor": contact_role6838, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportsByPartner.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(clocking.ReportsByPartner.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportsByPartner.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportsByPartner.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportsByPartner.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportsByPartner.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.ReportsByPartner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ReportsByPartner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.ReportsByPartner.insertPanel = Ext.extend(Lino.clocking.ServiceReports.DetailFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/clocking/ReportsByPartner",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ReportsByPartner.detail;
    this.ls_insert_handler = Lino.clocking.ReportsByPartner.insert;
    Lino.clocking.ReportsByPartner.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ReportsByPartner.insert = new Lino.WindowAction({  }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.clocking.ReportsByPartner.insertPanel(p);
});
Lino.clocking.ReportsByPartner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.clocking.ReportsByPartner.detailPanel = Ext.extend(Lino.clocking.ServiceReports.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Service Report", "overflowText": "Service Report", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/clocking/ReportsByPartner",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.clocking.ReportsByPartner.detail;
    this.ls_insert_handler = Lino.clocking.ReportsByPartner.insert;
    Lino.clocking.ReportsByPartner.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ReportsByPartner.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.ReportsByPartner.detailPanel(p);
});
Lino.clocking.ReportsByPartner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportsByPartner.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.clocking.ServiceReports.ParamsPanel({});
  return new Lino.clocking.ReportsByPartner.GridPanel(p);
});
Lino.clocking.ReportsByPartner.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportsByPartner", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class lists.MembersByList
Lino.lists.MembersByList.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/lists/MembersByList",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/lists/MembersByList','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/lists/MembersByList','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Members",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "seqno", "type": "int", "useNull": true }, { "name": "partner" }, 'partnerHidden', { "name": "remark" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "list" }, 'listHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 55,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var seqno2552 = new Ext.form.NumberField({ "selectOnFocus": true });
    var partner2553 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/MembersByList/partner" }) }) });
    var remark2554 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp2555 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id2556 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var move_buttons_disp2557 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2558 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2559 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2560 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var list2561 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/MembersByList/list" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "seqno", "editable": true, "editor": seqno2552, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(lists.MembersByList.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "partner", "editable": true, "editor": partner2553, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(lists.MembersByList.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "remark", "editable": true, "editor": remark2554, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(lists.MembersByList.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(lists.MembersByList.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id2556, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(lists.MembersByList.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByList.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByList.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByList.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByList.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "list", "editable": true, "editor": list2561, "filter": { "type": "string" }, "header": "Partnerite nimekiri", "hidden": true, "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(lists.MembersByList.list) ", "width": Lino.chars2width(21) } ];
    Lino.lists.MembersByList.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.MembersByList.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.MembersByList.GridPanel(p);
});
Lino.lists.MembersByList.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByList.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByList", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class lists.MembersByPartner
Lino.lists.MembersByPartner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/lists/MembersByPartner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/lists/MembersByPartner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/lists/MembersByPartner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Listi tellimused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "list" }, 'listHidden', { "name": "remark" }, { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "partner" }, 'partnerHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 55,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var list6845 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/MembersByPartner/list" }) }) });
    var remark6846 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id6847 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno6848 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var move_buttons_disp6849 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6850 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6851 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6852 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6853 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var partner6854 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/lists/MembersByPartner/partner" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "list", "editable": true, "editor": list6845, "filter": { "type": "string" }, "header": "Partnerite nimekiri", "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(lists.MembersByPartner.list) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "remark", "editable": true, "editor": remark6846, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(lists.MembersByPartner.remark) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id6847, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(lists.MembersByPartner.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 3, "dataIndex": "seqno", "editable": true, "editor": seqno6848, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(lists.MembersByPartner.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByPartner.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByPartner.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByPartner.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByPartner.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(lists.MembersByPartner.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "partner", "editable": true, "editor": partner6854, "filter": { "type": "string" }, "header": "Partner", "hidden": true, "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(lists.MembersByPartner.partner) ", "width": Lino.chars2width(21) } ];
    Lino.lists.MembersByPartner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.lists.MembersByPartner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.lists.MembersByPartner.GridPanel(p);
});
Lino.lists.MembersByPartner.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.lists.MembersByPartner.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/lists/MembersByPartner", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.EntriesByType
Lino.blogs.EntriesByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/EntriesByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "pub_date", "type": "date" }, { "name": "title" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "body" }, { "name": "pub_time" }, { "name": "language" }, 'languageHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "entry_type" }, 'entry_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 57,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntriesByType.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByType.insert;
    var ww = this.containing_window;
    var pub_date641 = new Lino.DateField({ "selectOnFocus": true });
    var title642 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user643 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByType/user" }) }) });
    var id644 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type645 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByType/owner_type" }) }) });
    var owner_id646 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByType/owner_id" }) }) });
    var body647 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var pub_time648 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var language649 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp650 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp651 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp652 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp653 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp654 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var entry_type655 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Blog Entry Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByType/entry_type" }) }) });
    this.before_row_edit = function(record) {
      owner_id646.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body647.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type645.on('change',Lino.chooser_handler(owner_id646,'owner_type'));
      Lino.blogs.EntriesByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "pub_date", "editable": true, "editor": pub_date641, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Publication date", "sortable": true, "tooltip": "(blogs.EntriesByType.pub_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "title", "editable": true, "editor": title642, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.EntriesByType.title) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user643, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(blogs.EntriesByType.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id644, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(blogs.EntriesByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type645, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(blogs.EntriesByType.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id646, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "body", "editable": true, "editor": body647, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.body) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "pub_time", "editable": true, "editor": pub_time648, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.EntriesByType.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "language", "editable": true, "editor": language649, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.language) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "entry_type", "editable": true, "editor": entry_type655, "filter": { "type": "string" }, "header": "Blog Entry Type", "hidden": true, "renderer": Lino.fk_renderer('entry_typeHidden','Lino.blogs.EntryTypes.detail'), "sortable": false, "tooltip": "(blogs.EntriesByType.entry_type) ", "width": Lino.chars2width(21) } ];
    Lino.blogs.EntriesByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntriesByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.EntriesByType.insertPanel = Ext.extend(Lino.blogs.Entries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/EntriesByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntriesByType.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByType.insert;
    Lino.blogs.EntriesByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntriesByType.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.EntriesByType.insertPanel(p);
});
Lino.blogs.EntriesByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.EntriesByType.detailPanel = Ext.extend(Lino.blogs.Entries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/EntriesByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntriesByType.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByType.insert;
    Lino.blogs.EntriesByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntriesByType.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.EntriesByType.detailPanel(p);
});
Lino.blogs.EntriesByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.blogs.Entries.ParamsPanel({});
  return new Lino.blogs.EntriesByType.GridPanel(p);
});
Lino.blogs.EntriesByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.TaggingsByEntry
Lino.blogs.TaggingsByEntry.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/TaggingsByEntry",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/TaggingsByEntry','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/TaggingsByEntry','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Taggings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "topic" }, 'topicHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "entry" }, 'entryHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 59,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var topic676 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/TaggingsByEntry/topic" }) }) });
    var id677 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp678 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp679 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp680 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp681 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var entry682 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Blog Entry...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/TaggingsByEntry/entry" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "topic", "editable": true, "editor": topic676, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(blogs.TaggingsByEntry.topic) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 1, "dataIndex": "id", "editable": true, "editor": id677, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(blogs.TaggingsByEntry.id) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByEntry.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByEntry.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByEntry.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByEntry.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "entry", "editable": true, "editor": entry682, "filter": { "type": "string" }, "header": "Blog Entry", "hidden": true, "renderer": Lino.fk_renderer('entryHidden','Lino.blogs.Entries.detail'), "sortable": false, "tooltip": "(blogs.TaggingsByEntry.entry) ", "width": Lino.chars2width(21) } ];
    Lino.blogs.TaggingsByEntry.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.TaggingsByEntry.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByEntry", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByEntry.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByEntry", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByEntry.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByEntry", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByEntry.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByEntry", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByEntry.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByEntry", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByEntry.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByEntry", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByEntry.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.TaggingsByEntry.GridPanel(p);
});

// js_render_GridPanel_class blogs.TaggingsByTopic
Lino.blogs.TaggingsByTopic.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/TaggingsByTopic",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/TaggingsByTopic','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/TaggingsByTopic','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Taggings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 10,
  ls_store_fields : [ { "name": "entry" }, 'entryHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "topic" }, 'topicHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 2,
  ls_grid_configs : [  ],
  content_type : 59,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var entry6856 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Blog Entry...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/TaggingsByTopic/entry" }) }) });
    var id6857 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp6858 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6859 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6860 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6861 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var topic6862 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Teema...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/TaggingsByTopic/topic" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "entry", "editable": true, "editor": entry6856, "filter": { "type": "string" }, "header": "Blog Entry", "renderer": Lino.fk_renderer('entryHidden','Lino.blogs.Entries.detail'), "sortable": false, "tooltip": "(blogs.TaggingsByTopic.entry) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 1, "dataIndex": "id", "editable": true, "editor": id6857, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(blogs.TaggingsByTopic.id) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByTopic.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByTopic.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByTopic.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.TaggingsByTopic.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "topic", "editable": true, "editor": topic6862, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "renderer": Lino.fk_renderer('topicHidden','Lino.topics.Topics.detail'), "sortable": false, "tooltip": "(blogs.TaggingsByTopic.topic) ", "width": Lino.chars2width(21) } ];
    Lino.blogs.TaggingsByTopic.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.TaggingsByTopic.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByTopic", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByTopic.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByTopic", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByTopic.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByTopic", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByTopic.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByTopic", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByTopic.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByTopic", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByTopic.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/TaggingsByTopic", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.TaggingsByTopic.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.TaggingsByTopic.GridPanel(p);
});

// js_render_GridPanel_class uploads.UploadsByType
Lino.uploads.UploadsByType.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/UploadsByType",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadsByType','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadsByType','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Uploads",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "file" }, { "name": "description" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "mimetype" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "upload_area" }, 'upload_areaHidden', { "name": "owner" }, { "name": "description_link" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "type" }, 'typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 62,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadsByType.detail;
    this.ls_insert_handler = Lino.uploads.UploadsByType.insert;
    var ww = this.containing_window;
    var file783 = Lino.file_field_handler(this,{ "maxLength": 100, "selectOnFocus": true });
    var description784 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user785 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByType/user" }) }) });
    var id786 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mimetype787 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": 255 });
    var owner_type788 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByType/owner_type" }) }) });
    var owner_id789 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByType/owner_id" }) }) });
    var upload_area790 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var owner_disp791 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var description_link_disp792 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp793 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp794 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp795 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp796 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type797 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Upload Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByType/type" }) }) });
    this.before_row_edit = function(record) {
      owner_id789.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      type797.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type788.on('change',Lino.chooser_handler(owner_id789,'owner_type'));
      upload_area790.on('change',Lino.chooser_handler(type797,'upload_area'));
      Lino.uploads.UploadsByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "file", "editable": true, "editor": file783, "filter": { "type": "string" }, "header": "Fail", "sortable": true, "tooltip": "(uploads.UploadsByType.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "description", "editable": true, "editor": description784, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": true, "tooltip": "(uploads.UploadsByType.description) A short description entered manually by the user.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user785, "filter": { "type": "string" }, "header": "Uploaded by", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(uploads.UploadsByType.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id786, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.UploadsByType.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "mimetype", "editable": false, "filter": { "type": "string" }, "header": "MIME type", "hidden": true, "sortable": true, "tooltip": "(uploads.UploadsByType.mimetype) The Media type\nof the file.  See also this thread\nabout length of MIME type field.", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type788, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(uploads.UploadsByType.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id789, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "upload_area", "editable": true, "editor": upload_area790, "filter": { "type": "string" }, "header": "Upload Area", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "description_link", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.description_link) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "type", "editable": true, "editor": type797, "filter": { "type": "string" }, "header": "Upload Type", "hidden": true, "renderer": Lino.fk_renderer('typeHidden','Lino.uploads.UploadTypes.detail'), "sortable": false, "tooltip": "(uploads.UploadsByType.type) ", "width": Lino.chars2width(21) } ];
    Lino.uploads.UploadsByType.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadsByType.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByType.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByType.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.UploadsByType.insertPanel = Ext.extend(Lino.uploads.Uploads.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/UploadsByType",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadsByType.detail;
    this.ls_insert_handler = Lino.uploads.UploadsByType.insert;
    Lino.uploads.UploadsByType.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadsByType.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.UploadsByType.insertPanel(p);
});
Lino.uploads.UploadsByType.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByType.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByType.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.UploadsByType.detailPanel = Ext.extend(Lino.uploads.Uploads.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/UploadsByType",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadsByType.detail;
    this.ls_insert_handler = Lino.uploads.UploadsByType.insert;
    Lino.uploads.UploadsByType.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadsByType.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.UploadsByType.detailPanel(p);
});
Lino.uploads.UploadsByType.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByType.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.uploads.Uploads.ParamsPanel({});
  return new Lino.uploads.UploadsByType.GridPanel(p);
});
Lino.uploads.UploadsByType.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByType", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.RecipientsByMail
Lino.outbox.RecipientsByMail.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/RecipientsByMail",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/RecipientsByMail','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/RecipientsByMail','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Recipients",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 14,
  ls_store_fields : [ { "name": "partner" }, 'partnerHidden', { "name": "address" }, { "name": "name" }, { "name": "type" }, 'typeHidden', { "name": "id", "type": "int" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mail" }, 'mailHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 64,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var partner580 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/RecipientsByMail/partner" }) }) });
    var address581 = new Ext.form.TextField({ "maxLength": 254, "selectOnFocus": true });
    var name582 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var type583 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.outbox.RecipientTypes });
    var id584 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mobile_item_disp585 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp586 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp587 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp588 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mail589 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Outgoing Mail...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/RecipientsByMail/mail" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "partner", "editable": true, "editor": partner580, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(outbox.RecipientsByMail.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "address", "editable": true, "editor": address581, "filter": { "type": "string" }, "header": "Aadres", "sortable": true, "tooltip": "(outbox.RecipientsByMail.address) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "name", "editable": true, "editor": name582, "filter": { "type": "string" }, "header": "Nimi", "sortable": true, "tooltip": "(outbox.RecipientsByMail.name) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "type", "editable": true, "editor": type583, "filter": { "type": "string" }, "header": "Recipient Type", "sortable": false, "tooltip": "(outbox.RecipientsByMail.type) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id584, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(outbox.RecipientsByMail.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.RecipientsByMail.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.RecipientsByMail.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.RecipientsByMail.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.RecipientsByMail.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "mail", "editable": true, "editor": mail589, "filter": { "type": "string" }, "header": "Outgoing Mail", "hidden": true, "renderer": Lino.fk_renderer('mailHidden','Lino.outbox.Mails.detail'), "sortable": false, "tooltip": "(outbox.RecipientsByMail.mail) ", "width": Lino.chars2width(21) } ];
    Lino.outbox.RecipientsByMail.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.RecipientsByMail.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientsByMail", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientsByMail.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientsByMail", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientsByMail.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientsByMail", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientsByMail.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientsByMail", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientsByMail.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientsByMail", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientsByMail.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientsByMail", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientsByMail.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.RecipientsByMail.GridPanel(p);
});

// js_render_GridPanel_class outbox.MyOutbox
Lino.outbox.MyOutbox.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/MyOutbox",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/MyOutbox','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/MyOutbox','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  cell_edit : true,
  title : "My Outbox",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 18,
  ls_store_fields : [ { "name": "sent" }, { "name": "recipients" }, { "name": "subject" }, { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "dateFormat": "d.m.Y", "name": "date", "type": "date" }, { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "body" }, { "name": "user" }, 'userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 63,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MyOutbox.detail;
    this.ls_insert_handler = Lino.outbox.MyOutbox.insert;
    var ww = this.containing_window;
    var sent6864 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var recipients_htmlbox6865 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "recipients", "title": "Recipients", "value": "<br/>" });
    var subject6866 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id6867 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type6868 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/MyOutbox/owner_type" }) }) });
    var owner_id6869 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/MyOutbox/owner_id" }) }) });
    var date6870 = new Lino.DateField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var owner_disp6871 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var mobile_item_disp6872 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6873 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6874 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6875 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var body6876 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var user6877 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/MyOutbox/user" }) }) });
    this.before_row_edit = function(record) {
      recipients_htmlbox6865.refresh();
      owner_id6869.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body6876.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type6868.on('change',Lino.chooser_handler(owner_id6869,'owner_type'));
      Lino.outbox.MyOutbox.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(outbox.MyOutbox.sent) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "recipients", "editable": false, "header": "Recipients", "sortable": false, "tooltip": "(outbox.MyOutbox.recipients) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "subject", "editable": true, "editor": subject6866, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(outbox.MyOutbox.subject) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id6867, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(outbox.MyOutbox.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type6868, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(outbox.MyOutbox.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id6869, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "date", "editable": true, "editor": date6870, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Kuup\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(outbox.MyOutbox.date) \n        The official date to be printed on the document.\n        ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "body", "editable": true, "editor": body6876, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(outbox.MyOutbox.body) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "user", "editable": true, "editor": user6877, "filter": { "type": "string" }, "header": "Sender", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(outbox.MyOutbox.user) ", "width": Lino.chars2width(21) } ];
    Lino.outbox.MyOutbox.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MyOutbox.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.MyOutbox.insertPanel = Ext.extend(Lino.outbox.Mails.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/outbox/MyOutbox",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MyOutbox.detail;
    this.ls_insert_handler = Lino.outbox.MyOutbox.insert;
    Lino.outbox.MyOutbox.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MyOutbox.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.outbox.MyOutbox.insertPanel(p);
});
Lino.outbox.MyOutbox.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.MyOutbox.detailPanel = Ext.extend(Lino.outbox.Mails.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  ls_url: "/outbox/MyOutbox",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MyOutbox.detail;
    this.ls_insert_handler = Lino.outbox.MyOutbox.insert;
    Lino.outbox.MyOutbox.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MyOutbox.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.MyOutbox.detailPanel(p);
});
Lino.outbox.MyOutbox.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.outbox.Mails.ParamsPanel({});
  return new Lino.outbox.MyOutbox.GridPanel(p);
});
Lino.outbox.MyOutbox.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MyOutbox.send_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MyOutbox", "GET", pk, "send_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.MailsByUser
Lino.outbox.MailsByUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/MailsByUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/MailsByUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/MailsByUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  cell_edit : true,
  title : "Outbox",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 5,
  ls_store_fields : [ { "name": "sent" }, { "name": "subject" }, { "name": "recipients" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 63,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MailsByUser.detail;
    this.ls_insert_handler = Lino.outbox.MailsByUser.insert;
    var ww = this.containing_window;
    var sent6879 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var subject6880 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var recipients_htmlbox6881 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "recipients", "title": "Recipients", "value": "<br/>" });
    this.before_row_edit = function(record) {
      recipients_htmlbox6881.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(outbox.MailsByUser.sent) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "subject", "editable": true, "editor": subject6880, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(outbox.MailsByUser.subject) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "recipients", "editable": false, "header": "Recipients", "sortable": false, "tooltip": "(outbox.MailsByUser.recipients) ", "width": Lino.chars2width(31) } ];
    Lino.outbox.MailsByUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MailsByUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.MailsByUser.insertPanel = Ext.extend(Lino.outbox.Mails.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/outbox/MailsByUser",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MailsByUser.detail;
    this.ls_insert_handler = Lino.outbox.MailsByUser.insert;
    Lino.outbox.MailsByUser.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MailsByUser.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.outbox.MailsByUser.insertPanel(p);
});
Lino.outbox.MailsByUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.MailsByUser.detailPanel = Ext.extend(Lino.outbox.Mails.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  ls_url: "/outbox/MailsByUser",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MailsByUser.detail;
    this.ls_insert_handler = Lino.outbox.MailsByUser.insert;
    Lino.outbox.MailsByUser.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MailsByUser.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.MailsByUser.detailPanel(p);
});
Lino.outbox.MailsByUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.outbox.Mails.ParamsPanel({});
  return new Lino.outbox.MailsByUser.GridPanel(p);
});
Lino.outbox.MailsByUser.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByUser.send_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByUser", "GET", pk, "send_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.SentByPartner
Lino.outbox.SentByPartner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/SentByPartner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/SentByPartner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/SentByPartner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  cell_edit : true,
  title : "Outbox",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "sent" }, { "name": "subject" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 63,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.SentByPartner.detail;
    this.ls_insert_handler = Lino.outbox.SentByPartner.insert;
    var ww = this.containing_window;
    var sent6883 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var subject6884 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user6885 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/SentByPartner/user" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(outbox.SentByPartner.sent) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "subject", "editable": true, "editor": subject6884, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(outbox.SentByPartner.subject) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user6885, "filter": { "type": "string" }, "header": "Sender", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(outbox.SentByPartner.user) ", "width": Lino.chars2width(21) } ];
    Lino.outbox.SentByPartner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.SentByPartner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.SentByPartner.insertPanel = Ext.extend(Lino.outbox.Mails.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/outbox/SentByPartner",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.SentByPartner.detail;
    this.ls_insert_handler = Lino.outbox.SentByPartner.insert;
    Lino.outbox.SentByPartner.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.SentByPartner.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.outbox.SentByPartner.insertPanel(p);
});
Lino.outbox.SentByPartner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.SentByPartner.detailPanel = Ext.extend(Lino.outbox.Mails.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  ls_url: "/outbox/SentByPartner",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.SentByPartner.detail;
    this.ls_insert_handler = Lino.outbox.SentByPartner.insert;
    Lino.outbox.SentByPartner.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.SentByPartner.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.SentByPartner.detailPanel(p);
});
Lino.outbox.SentByPartner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.outbox.Mails.ParamsPanel({});
  return new Lino.outbox.SentByPartner.GridPanel(p);
});
Lino.outbox.SentByPartner.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.SentByPartner.send_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/SentByPartner", "GET", pk, "send_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.AttachmentsByMail
Lino.outbox.AttachmentsByMail.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/AttachmentsByMail",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/AttachmentsByMail','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/AttachmentsByMail','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Attachments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "owner" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "mail" }, 'mailHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 65,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id6887 = new Ext.form.NumberField({ "selectOnFocus": true });
    var owner_type6888 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/AttachmentsByMail/owner_type" }) }) });
    var owner_id6889 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/AttachmentsByMail/owner_id" }) }) });
    var owner_disp6890 = new Ext.form.DisplayField({ "disabled": true });
    var mobile_item_disp6891 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6892 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6893 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6894 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mail6895 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Outgoing Mail...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/AttachmentsByMail/mail" }) }) });
    this.before_row_edit = function(record) {
      owner_id6889.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type6888.on('change',Lino.chooser_handler(owner_id6889,'owner_type'));
      Lino.outbox.AttachmentsByMail.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id6887, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(outbox.AttachmentsByMail.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "owner_type", "editable": true, "editor": owner_type6888, "filter": { "type": "string" }, "header": "Controlled by (type)", "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(outbox.AttachmentsByMail.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "owner_id", "editable": true, "editor": owner_id6889, "filter": { "type": "string" }, "header": "Controlled by (object)", "sortable": false, "tooltip": "(outbox.AttachmentsByMail.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(outbox.AttachmentsByMail.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByMail.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByMail.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByMail.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByMail.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "mail", "editable": true, "editor": mail6895, "filter": { "type": "string" }, "header": "Outgoing Mail", "hidden": true, "renderer": Lino.fk_renderer('mailHidden','Lino.outbox.Mails.detail'), "sortable": false, "tooltip": "(outbox.AttachmentsByMail.mail) ", "width": Lino.chars2width(21) } ];
    Lino.outbox.AttachmentsByMail.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.AttachmentsByMail.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByMail", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByMail.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByMail", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByMail.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByMail", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByMail.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByMail", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByMail.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByMail", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByMail.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByMail", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByMail.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.AttachmentsByMail.GridPanel(p);
});

// js_render_GridPanel_class dashboard.WidgetsByUser
Lino.dashboard.WidgetsByUser.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/dashboard/WidgetsByUser",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/dashboard/WidgetsByUser','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/dashboard/WidgetsByUser','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Dashboard",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "seqno", "type": "int", "useNull": true }, { "name": "move_buttons" }, { "name": "title" }, { "name": "visible", "type": "boolean" }, { "name": "id", "type": "int" }, { "name": "item_name" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "user" }, 'userHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 67,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var seqno6897 = new Ext.form.NumberField({ "selectOnFocus": true });
    var move_buttons_disp6898 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var title_disp6899 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var visible6900 = new Ext.form.Checkbox({ "checked": true, "selectOnFocus": true });
    var id6901 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var item_name6902 = new Lino.SimpleRemoteComboFieldElement({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/WidgetsByUser/item_name" }) }) });
    var mobile_item_disp6903 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6904 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6905 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6906 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var user6907 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/dashboard/WidgetsByUser/user" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      item_name6902.setContextValue('mk',bp['mk']);
      item_name6902.setContextValue('mt',bp['mt']);
    };
    this.onRender = function(ct, position) {
      user6907.on('change',Lino.chooser_handler(item_name6902,'user'));
      Lino.dashboard.WidgetsByUser.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "seqno", "editable": true, "editor": seqno6897, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(dashboard.WidgetsByUser.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "move_buttons", "editable": false, "header": "Move", "sortable": false, "tooltip": "(dashboard.WidgetsByUser.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "title", "editable": false, "header": "Label", "sortable": false, "tooltip": "(dashboard.WidgetsByUser.title) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "visible", "editable": true, "filter": { "type": "boolean" }, "header": "Visible", "sortable": false, "tooltip": "(dashboard.WidgetsByUser.visible) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id6901, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(dashboard.WidgetsByUser.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "item_name", "editable": true, "editor": item_name6902, "filter": { "type": "string" }, "header": "Resource", "hidden": true, "sortable": false, "tooltip": "(dashboard.WidgetsByUser.item_name) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(dashboard.WidgetsByUser.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(dashboard.WidgetsByUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(dashboard.WidgetsByUser.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(dashboard.WidgetsByUser.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "user", "editable": true, "editor": user6907, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(dashboard.WidgetsByUser.user) ", "width": Lino.chars2width(21) } ];
    Lino.dashboard.WidgetsByUser.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.dashboard.WidgetsByUser.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.dashboard.Widgets.ParamsPanel({});
  return new Lino.dashboard.WidgetsByUser.GridPanel(p);
});
Lino.dashboard.WidgetsByUser.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.dashboard.WidgetsByUser.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/dashboard/WidgetsByUser", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.LinesByTopic
Lino.courses.LinesByTopic.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/LinesByTopic",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/LinesByTopic','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/LinesByTopic','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Tegevuste sarjad",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 31,
  ls_store_fields : [ { "name": "ref" }, { "name": "name" }, { "name": "name_et" }, { "name": "topic" }, 'topicHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "event_type" }, 'event_typeHidden', { "name": "guest_role" }, 'guest_roleHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "excerpt_title" }, { "name": "excerpt_title_et" }, { "name": "description" }, { "name": "description_et" }, { "name": "body_template" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 14,
  ls_grid_configs : [  ],
  content_type : 27,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.LinesByTopic.detail;
    this.ls_insert_handler = Lino.courses.LinesByTopic.insert;
    var ww = this.containing_window;
    var ref2147 = new Ext.form.TextField({ "maxLength": 40, "selectOnFocus": true });
    var name2148 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et2149 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var topic2150 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Teema...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/topic" }) }) });
    var course_area2151 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.courses.CourseAreas });
    var event_type2152 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/event_type" }) }) });
    var guest_role2153 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Guest Role...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/guest_role" }) }) });
    var every_unit2154 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every2155 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 1 });
    var id2156 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var company2157 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/company" }) }) });
    var contact_person2158 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/contact_person" }) }) });
    var contact_role2159 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/contact_role" }) }) });
    var excerpt_title2160 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var excerpt_title_et2161 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description2162 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et2163 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var body_template2164 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/LinesByTopic/body_template" }) }) });
    var mobile_item_disp2165 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2166 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2167 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2168 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person2158.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2162.refresh();
      description_et2163.refresh();
    };
    this.onRender = function(ct, position) {
      company2157.on('change',Lino.chooser_handler(contact_person2158,'company'));
      Lino.courses.LinesByTopic.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "ref", "editable": true, "editor": ref2147, "filter": { "type": "string" }, "header": "Reference", "sortable": true, "tooltip": "(courses.LinesByTopic.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name2148, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.LinesByTopic.name) The designation of this activity line as seen by the user\ne.g. when selecting the line.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et2149, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(courses.LinesByTopic.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic2150, "filter": { "type": "string" }, "header": "Teema", "renderer": Lino.fk_renderer('topicHidden','Lino.courses.Topics.detail'), "sortable": false, "tooltip": "(courses.LinesByTopic.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "course_area", "editable": true, "editor": course_area2151, "filter": { "type": "string" }, "header": "Layout", "sortable": false, "tooltip": "(courses.LinesByTopic.course_area) Pointer to CourseAreas.  This is used only when an\napplication defines several variants of\nEnrolmentsByPupil.", "width": Lino.chars2width(14) }, { "colIndex": 5, "dataIndex": "event_type", "editable": true, "editor": event_type2152, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(courses.LinesByTopic.event_type) The type of calendar entries to be generated. If this is empty, no calendar entries will be generated.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "guest_role", "editable": true, "editor": guest_role2153, "filter": { "type": "string" }, "header": "Manage presences as", "renderer": Lino.fk_renderer('guest_roleHidden','Lino.cal.GuestRoles.detail'), "sortable": false, "tooltip": "(courses.LinesByTopic.guest_role) The default guest role for particpants of calendar entries for activities in this series. Leave empty if you don't want any presences management.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "every_unit", "editable": true, "editor": every_unit2154, "filter": { "type": "string" }, "header": "Korduvus", "sortable": false, "tooltip": "(courses.LinesByTopic.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 8, "dataIndex": "every", "editable": true, "editor": every2155, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "sortable": true, "tooltip": "(courses.LinesByTopic.every) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 9, "dataIndex": "id", "editable": true, "editor": id2156, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.LinesByTopic.id) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "company", "editable": true, "editor": company2157, "filter": { "type": "string" }, "header": "Organisatsioon", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(courses.LinesByTopic.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "contact_person", "editable": true, "editor": contact_person2158, "filter": { "type": "string" }, "header": "represented by", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.LinesByTopic.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "contact_role", "editable": true, "editor": contact_role2159, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "excerpt_title", "editable": true, "editor": excerpt_title2160, "filter": { "type": "string" }, "header": "Excerpt title", "hidden": true, "sortable": true, "tooltip": "(courses.LinesByTopic.excerpt_title) The title to be used when printing an excerpt.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "excerpt_title_et", "editable": true, "editor": excerpt_title_et2161, "filter": { "type": "string" }, "header": "Excerpt title (et)", "hidden": true, "sortable": true, "tooltip": "(courses.LinesByTopic.excerpt_title_et) ", "width": Lino.chars2width(22) }, { "colIndex": 15, "dataIndex": "description", "editable": true, "editor": description2162, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.description) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "description_et", "editable": true, "editor": description_et2163, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 17, "dataIndex": "body_template", "editable": true, "editor": body_template2164, "filter": { "type": "string" }, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.body_template) The body template to use when printing a course of this series. Leave empty to use the site's default.", "width": Lino.chars2width(11) }, { "colIndex": 18, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 20, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 21, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.LinesByTopic.workflow_buttons) ", "width": Lino.chars2width(31) } ];
    Lino.courses.LinesByTopic.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.LinesByTopic.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.LinesByTopic.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.LinesByTopic.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.LinesByTopic.insertPanel = Ext.extend(Lino.courses.Lines.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/LinesByTopic",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.LinesByTopic.detail;
    this.ls_insert_handler = Lino.courses.LinesByTopic.insert;
    Lino.courses.LinesByTopic.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.LinesByTopic.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(16), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(70) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.LinesByTopic.insertPanel(p);
});
Lino.courses.LinesByTopic.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.LinesByTopic.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.LinesByTopic.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.LinesByTopic.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.LinesByTopic.detailPanel = Ext.extend(Lino.courses.Lines.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/courses/LinesByTopic",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.LinesByTopic.detail;
    this.ls_insert_handler = Lino.courses.LinesByTopic.insert;
    Lino.courses.LinesByTopic.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.LinesByTopic.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.LinesByTopic.detailPanel(p);
});
Lino.courses.LinesByTopic.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.LinesByTopic.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.LinesByTopic.GridPanel(p);
});
Lino.courses.LinesByTopic.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/LinesByTopic", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.EntriesByTeacher
Lino.courses.EntriesByTeacher.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/EntriesByTeacher",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/EntriesByTeacher','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/EntriesByTeacher','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "when_text" }, { "name": "owner" }, { "name": "room" }, 'roomHidden', { "name": "state" }, 'stateHidden', { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EntriesByTeacher.detail;
    this.ls_insert_handler = Lino.courses.EntriesByTeacher.insert;
    var ww = this.containing_window;
    var when_text_disp6909 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var owner_disp6910 = new Ext.form.DisplayField({ "disabled": true });
    var room6911 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EntriesByTeacher/room" }) }) });
    var state6912 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(courses.EntriesByTeacher.when_text) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "owner", "editable": false, "header": "Controlled by", "sortable": false, "tooltip": "(courses.EntriesByTeacher.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "room", "editable": true, "editor": room6911, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.EntriesByTeacher.room) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "state", "editable": true, "editor": state6912, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(courses.EntriesByTeacher.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) } ];
    Lino.courses.EntriesByTeacher.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EntriesByTeacher.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.EntriesByTeacher.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/EntriesByTeacher",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EntriesByTeacher.detail;
    this.ls_insert_handler = Lino.courses.EntriesByTeacher.insert;
    Lino.courses.EntriesByTeacher.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EntriesByTeacher.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.EntriesByTeacher.insertPanel(p);
});
Lino.courses.EntriesByTeacher.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.EntriesByTeacher.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/EntriesByTeacher",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EntriesByTeacher.detail;
    this.ls_insert_handler = Lino.courses.EntriesByTeacher.insert;
    Lino.courses.EntriesByTeacher.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EntriesByTeacher.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.EntriesByTeacher.detailPanel(p);
});
Lino.courses.EntriesByTeacher.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.courses.EntriesByTeacher.GridPanel(p);
});
Lino.courses.EntriesByTeacher.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EntriesByTeacher.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EntriesByTeacher", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.CoursesByTeacher
Lino.courses.CoursesByTeacher.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/CoursesByTeacher",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesByTeacher','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesByTeacher','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "name": "end_time" }, { "name": "line" }, 'lineHidden', { "name": "room" }, 'roomHidden', { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "teacher" }, 'teacherHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByTeacher.detail;
    this.ls_insert_handler = Lino.courses.CoursesByTeacher.insert;
    var ww = this.containing_window;
    var start_date6914 = new Lino.DateField({ "selectOnFocus": true });
    var start_time6915 = new Lino.TimeField({ "selectOnFocus": true });
    var end_time6916 = new Lino.TimeField({ "selectOnFocus": true });
    var line6917 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTeacher/line" }) }) });
    var room6918 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTeacher/room" }) }) });
    var id6919 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6920 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var end_date6921 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var user6922 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTeacher/user" }) }) });
    var every_unit6923 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6924 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6925 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6926 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6927 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6928 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6929 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6930 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6931 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6932 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6933 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var slot6934 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTeacher/slot" }) }) });
    var description6935 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6936 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6937 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6938 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6939 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name6940 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until6941 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6942 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments6943 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp6944 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6945 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6946 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6947 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6948 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places6949 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp6950 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp6951 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp6952 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp6953 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp6954 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp6955 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp6956 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration6957 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    var teacher6958 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTeacher/teacher" }) }) });
    this.before_row_edit = function(record) {
      description6935.refresh();
      description_et6936.refresh();
      remark6937.refresh();
      presences_box_htmlbox6947.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date6914, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.CoursesByTeacher.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "start_time", "editable": true, "editor": start_time6915, "header": "Start time", "sortable": true, "tooltip": "(courses.CoursesByTeacher.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 2, "dataIndex": "end_time", "editable": true, "editor": end_time6916, "header": "L\u00f5peb (aeg)", "sortable": true, "tooltip": "(courses.CoursesByTeacher.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 3, "dataIndex": "line", "editable": true, "editor": line6917, "filter": { "type": "string" }, "header": "Tegevuste sari", "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.CoursesByTeacher.line) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "room", "editable": true, "editor": room6918, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.CoursesByTeacher.room) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6919, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "ref", "editable": true, "editor": ref6920, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date6921, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "user", "editable": true, "editor": user6922, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.CoursesByTeacher.user) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "every_unit", "editable": true, "editor": every_unit6923, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 10, "dataIndex": "every", "editable": true, "editor": every6924, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.every) ", "width": Lino.chars2width(6) }, { "colIndex": 11, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 12, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 13, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 14, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 18, "dataIndex": "max_events", "editable": true, "editor": max_events6932, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 19, "dataIndex": "max_date", "editable": true, "editor": max_date6933, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 20, "dataIndex": "slot", "editable": true, "editor": slot6934, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.CoursesByTeacher.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "description", "editable": true, "editor": description6935, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.description) ", "width": Lino.chars2width(61) }, { "colIndex": 22, "dataIndex": "description_et", "editable": true, "editor": description_et6936, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 23, "dataIndex": "remark", "editable": true, "editor": remark6937, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 24, "dataIndex": "state", "editable": true, "editor": state6938, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 25, "dataIndex": "max_places", "editable": true, "editor": max_places6939, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 26, "dataIndex": "name", "editable": true, "editor": name6940, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.name) ", "width": Lino.chars2width(22) }, { "colIndex": 27, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6941, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTeacher.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 28, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 29, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 30, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 31, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 32, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 33, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 34, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 35, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 36, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 37, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 38, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 43, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTeacher.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 44, "dataIndex": "teacher", "editable": true, "editor": teacher6958, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "hidden": true, "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.CoursesByTeacher.teacher) ", "width": Lino.chars2width(21) } ];
    Lino.courses.CoursesByTeacher.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByTeacher.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesByTeacher.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/CoursesByTeacher",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByTeacher.detail;
    this.ls_insert_handler = Lino.courses.CoursesByTeacher.insert;
    Lino.courses.CoursesByTeacher.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByTeacher.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.CoursesByTeacher.insertPanel(p);
});
Lino.courses.CoursesByTeacher.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesByTeacher.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/CoursesByTeacher",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByTeacher.detail;
    this.ls_insert_handler = Lino.courses.CoursesByTeacher.insert;
    Lino.courses.CoursesByTeacher.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByTeacher.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.CoursesByTeacher.detailPanel(p);
});
Lino.courses.CoursesByTeacher.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.CoursesByTeacher.GridPanel(p);
});
Lino.courses.CoursesByTeacher.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTeacher.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTeacher", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.CoursesByLine
Lino.courses.CoursesByLine.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/CoursesByLine",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesByLine','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesByLine','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "weekdays_text" }, { "name": "room" }, 'roomHidden', { "name": "times_text" }, { "name": "teacher" }, 'teacherHidden', { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "line" }, 'lineHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByLine.detail;
    this.ls_insert_handler = Lino.courses.CoursesByLine.insert;
    var ww = this.containing_window;
    var overview_disp6960 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var weekdays_text_disp6961 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var room6962 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByLine/room" }) }) });
    var times_text_disp6963 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var teacher6964 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByLine/teacher" }) }) });
    var id6965 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref6966 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_date6967 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time6968 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date6969 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time6970 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user6971 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByLine/user" }) }) });
    var every_unit6972 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every6973 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday6974 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday6975 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday6976 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday6977 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday6978 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday6979 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday6980 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events6981 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date6982 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var slot6983 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByLine/slot" }) }) });
    var description6984 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et6985 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark6986 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state6987 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places6988 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var name6989 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until6990 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp6991 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments6992 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp6993 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested6994 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed6995 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox6996 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying6997 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places6998 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var what_text_disp6999 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp7000 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7001 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7002 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration7003 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    var line7004 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByLine/line" }) }) });
    this.before_row_edit = function(record) {
      description6984.refresh();
      description_et6985.refresh();
      remark6986.refresh();
      presences_box_htmlbox6996.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(courses.CoursesByLine.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(courses.CoursesByLine.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "room", "editable": true, "editor": room6962, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.CoursesByLine.room) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "times_text", "editable": false, "header": "Times", "sortable": false, "tooltip": "(courses.CoursesByLine.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "teacher", "editable": true, "editor": teacher6964, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.CoursesByLine.teacher) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id6965, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "ref", "editable": true, "editor": ref6966, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 7, "dataIndex": "start_date", "editable": true, "editor": start_date6967, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time6968, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date6969, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time6970, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "user", "editable": true, "editor": user6971, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.CoursesByLine.user) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "every_unit", "editable": true, "editor": every_unit6972, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 13, "dataIndex": "every", "editable": true, "editor": every6973, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.every) ", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 20, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 21, "dataIndex": "max_events", "editable": true, "editor": max_events6981, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 22, "dataIndex": "max_date", "editable": true, "editor": max_date6982, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "slot", "editable": true, "editor": slot6983, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.CoursesByLine.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "description", "editable": true, "editor": description6984, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.description) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "description_et", "editable": true, "editor": description_et6985, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "remark", "editable": true, "editor": remark6986, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state6987, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 28, "dataIndex": "max_places", "editable": true, "editor": max_places6988, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 29, "dataIndex": "name", "editable": true, "editor": name6989, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.name) ", "width": Lino.chars2width(22) }, { "colIndex": 30, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until6990, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByLine.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 31, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 32, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 33, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 34, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 35, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 36, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 38, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 39, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 43, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByLine.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 44, "dataIndex": "line", "editable": true, "editor": line7004, "filter": { "type": "string" }, "header": "Tegevuste sari", "hidden": true, "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.CoursesByLine.line) ", "width": Lino.chars2width(21) } ];
    Lino.courses.CoursesByLine.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByLine.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesByLine.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/CoursesByLine",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByLine.detail;
    this.ls_insert_handler = Lino.courses.CoursesByLine.insert;
    Lino.courses.CoursesByLine.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByLine.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.CoursesByLine.insertPanel(p);
});
Lino.courses.CoursesByLine.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesByLine.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/CoursesByLine",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByLine.detail;
    this.ls_insert_handler = Lino.courses.CoursesByLine.insert;
    Lino.courses.CoursesByLine.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByLine.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.CoursesByLine.detailPanel(p);
});
Lino.courses.CoursesByLine.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.CoursesByLine.GridPanel(p);
});
Lino.courses.CoursesByLine.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByLine.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByLine", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.CoursesByTopic
Lino.courses.CoursesByTopic.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/CoursesByTopic",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesByTopic','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesByTopic','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "max_places", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "requested", "type": "int", "useNull": true }, { "name": "trying", "type": "int", "useNull": true }, { "name": "id", "type": "int" }, { "name": "ref" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "name": "room" }, 'roomHidden', { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "slot" }, 'slotHidden', { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "name" }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "presences_box" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "workflow_buttons" }, { "name": "duration" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 8,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByTopic.detail;
    this.ls_insert_handler = Lino.courses.Activities.insert;
    var ww = this.containing_window;
    var overview_disp2210 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var weekdays_text_disp2211 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var times_text_disp2212 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var max_places2213 = new Ext.form.NumberField({ "selectOnFocus": true });
    var confirmed2214 = new Ext.form.NumberField({ "disabled": true });
    var free_places2215 = new Ext.form.NumberField({ "disabled": true });
    var requested2216 = new Ext.form.NumberField({ "disabled": true });
    var trying2217 = new Ext.form.NumberField({ "disabled": true });
    var id2218 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref2219 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_date2220 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time2221 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date2222 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time2223 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user2224 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/user" }) }) });
    var every_unit2225 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every2226 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday2227 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday2228 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday2229 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday2230 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday2231 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday2232 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday2233 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events2234 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var room2235 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/room" }) }) });
    var max_date2236 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var line2237 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/line" }) }) });
    var teacher2238 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/teacher" }) }) });
    var slot2239 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesByTopic/slot" }) }) });
    var description2240 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et2241 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark2242 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state2243 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var name2244 = new Ext.form.TextField({ "hidden": true, "maxLength": 100, "selectOnFocus": true });
    var enrolments_until2245 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp2246 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments2247 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp2248 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var presences_box_htmlbox2249 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var what_text_disp2250 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2251 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2252 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2253 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration2254 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      description2240.refresh();
      description_et2241.refresh();
      remark2242.refresh();
      presences_box_htmlbox2249.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "overview", "sortable": false, "tooltip": "(courses.CoursesByTopic.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(courses.CoursesByTopic.weekdays_text) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "times_text", "editable": false, "header": "Times", "sortable": false, "tooltip": "(courses.CoursesByTopic.times_text) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 3, "dataIndex": "max_places", "editable": true, "editor": max_places2213, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "sortable": true, "tooltip": "(courses.CoursesByTopic.max_places) Maximum number of participants", "width": Lino.chars2width(9) }, { "align": "right", "colIndex": 4, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "sortable": false, "tooltip": "(courses.CoursesByTopic.confirmed) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 5, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "sortable": false, "tooltip": "(courses.CoursesByTopic.free_places) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 6, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "sortable": false, "tooltip": "(courses.CoursesByTopic.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 7, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "sortable": false, "tooltip": "(courses.CoursesByTopic.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 8, "dataIndex": "id", "editable": true, "editor": id2218, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.id) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "ref", "editable": true, "editor": ref2219, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 10, "dataIndex": "start_date", "editable": true, "editor": start_date2220, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 11, "dataIndex": "start_time", "editable": true, "editor": start_time2221, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 12, "dataIndex": "end_date", "editable": true, "editor": end_date2222, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 13, "dataIndex": "end_time", "editable": true, "editor": end_time2223, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 14, "dataIndex": "user", "editable": true, "editor": user2224, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.CoursesByTopic.user) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "every_unit", "editable": true, "editor": every_unit2225, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 16, "dataIndex": "every", "editable": true, "editor": every2226, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.every) ", "width": Lino.chars2width(6) }, { "colIndex": 17, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 20, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 21, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 22, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 23, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 24, "dataIndex": "max_events", "editable": true, "editor": max_events2234, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 25, "dataIndex": "room", "editable": true, "editor": room2235, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.CoursesByTopic.room) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "max_date", "editable": true, "editor": max_date2236, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 27, "dataIndex": "line", "editable": true, "editor": line2237, "filter": { "type": "string" }, "header": "Tegevuste sari", "hidden": true, "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.CoursesByTopic.line) ", "width": Lino.chars2width(21) }, { "colIndex": 28, "dataIndex": "teacher", "editable": true, "editor": teacher2238, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "hidden": true, "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.CoursesByTopic.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "slot", "editable": true, "editor": slot2239, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.CoursesByTopic.slot) ", "width": Lino.chars2width(21) }, { "colIndex": 30, "dataIndex": "description", "editable": true, "editor": description2240, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.description) ", "width": Lino.chars2width(61) }, { "colIndex": 31, "dataIndex": "description_et", "editable": true, "editor": description_et2241, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 32, "dataIndex": "remark", "editable": true, "editor": remark2242, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 33, "dataIndex": "state", "editable": true, "editor": state2243, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "colIndex": 34, "dataIndex": "name", "editable": true, "editor": name2244, "filter": { "type": "string" }, "header": "Nimetus", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.name) ", "width": Lino.chars2width(22) }, { "colIndex": 35, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until2245, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesByTopic.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 36, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 38, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.print_actions) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.presences_box) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 43, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 44, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesByTopic.duration) ", "width": Lino.chars2width(8) } ];
    Lino.courses.CoursesByTopic.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByTopic.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesByTopic.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/CoursesByTopic",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesByTopic.detail;
    this.ls_insert_handler = Lino.courses.Activities.insert;
    Lino.courses.CoursesByTopic.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesByTopic.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.CoursesByTopic.detailPanel(p);
});
Lino.courses.CoursesByTopic.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.CoursesByTopic.ParamsPanel({});
  return new Lino.courses.CoursesByTopic.GridPanel(p);
});
Lino.courses.CoursesByTopic.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesByTopic.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesByTopic", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.CoursesBySlot
Lino.courses.CoursesBySlot.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/CoursesBySlot",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesBySlot','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/CoursesBySlot','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "Tegevused",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 53,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "name" }, { "name": "line" }, 'lineHidden', { "name": "teacher" }, 'teacherHidden', { "name": "room" }, 'roomHidden', { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "ref" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "user" }, 'userHidden', { "name": "every_unit" }, 'every_unitHidden', { "name": "every", "type": "int", "useNull": true }, { "name": "monday", "type": "boolean" }, { "name": "tuesday", "type": "boolean" }, { "name": "wednesday", "type": "boolean" }, { "name": "thursday", "type": "boolean" }, { "name": "friday", "type": "boolean" }, { "name": "saturday", "type": "boolean" }, { "name": "sunday", "type": "boolean" }, { "name": "max_events", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "max_date", "type": "date" }, { "name": "description" }, { "name": "description_et" }, { "name": "remark" }, { "name": "state" }, 'stateHidden', { "name": "max_places", "type": "int", "useNull": true }, { "dateFormat": "d.m.Y", "name": "enrolments_until", "type": "date" }, { "name": "events_text" }, { "name": "enrolments" }, { "name": "print_actions" }, { "name": "requested", "type": "int", "useNull": true }, { "name": "confirmed", "type": "int", "useNull": true }, { "name": "presences_box" }, { "name": "trying", "type": "int", "useNull": true }, { "name": "free_places", "type": "int", "useNull": true }, { "name": "weekdays_text" }, { "name": "times_text" }, { "name": "what_text" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "duration" }, { "name": "slot" }, 'slotHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 9,
  ls_grid_configs : [  ],
  content_type : 29,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesBySlot.detail;
    this.ls_insert_handler = Lino.courses.CoursesBySlot.insert;
    var ww = this.containing_window;
    var start_date2690 = new Lino.DateField({ "selectOnFocus": true });
    var name2691 = new Ext.form.TextField({ "maxLength": 100, "selectOnFocus": true });
    var line2692 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevuste sari...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesBySlot/line" }) }) });
    var teacher2693 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesBySlot/teacher" }) }) });
    var room2694 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesBySlot/room" }) }) });
    var workflow_buttons_disp2695 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id2696 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var ref2697 = new Ext.form.TextField({ "hidden": true, "maxLength": 40, "selectOnFocus": true });
    var start_time2698 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date2699 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time2700 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var user2701 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesBySlot/user" }) }) });
    var every_unit2702 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every2703 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var monday2704 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var tuesday2705 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var wednesday2706 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var thursday2707 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var friday2708 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var saturday2709 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var sunday2710 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var max_events2711 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var max_date2712 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var description2713 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et2714 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var remark2715 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkus" });
    var state2716 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.CourseStates });
    var max_places2717 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var enrolments_until2718 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var events_text_disp2719 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var enrolments2720 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var print_actions_disp2721 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var requested2722 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var confirmed2723 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var presences_box_htmlbox2724 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "presences_box", "title": "Kohalolekud", "value": "<br/>" });
    var trying2725 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var free_places2726 = new Ext.form.NumberField({ "disabled": true, "hidden": true });
    var weekdays_text_disp2727 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var times_text_disp2728 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var what_text_disp2729 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2730 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2731 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2732 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration2733 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    var slot2734 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Timetable Slot...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/CoursesBySlot/slot" }) }) });
    this.before_row_edit = function(record) {
      description2713.refresh();
      description_et2714.refresh();
      remark2715.refresh();
      presences_box_htmlbox2724.refresh();
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date2690, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(courses.CoursesBySlot.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name2691, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.CoursesBySlot.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "line", "editable": true, "editor": line2692, "filter": { "type": "string" }, "header": "Tegevuste sari", "renderer": Lino.fk_renderer('lineHidden','Lino.courses.Lines.detail'), "sortable": false, "tooltip": "(courses.CoursesBySlot.line) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "teacher", "editable": true, "editor": teacher2693, "filter": { "type": "string" }, "header": "\u00dcrituse juht", "renderer": Lino.fk_renderer('teacherHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.CoursesBySlot.teacher) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "room", "editable": true, "editor": room2694, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(courses.CoursesBySlot.room) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.CoursesBySlot.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 6, "dataIndex": "id", "editable": true, "editor": id2696, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.id) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "ref", "editable": true, "editor": ref2697, "filter": { "type": "string" }, "header": "Reference", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.ref) The reference. This must be either empty or unique.", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "start_time", "editable": true, "editor": start_time2698, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 9, "dataIndex": "end_date", "editable": true, "editor": end_date2699, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "end_time", "editable": true, "editor": end_time2700, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.end_time) ", "width": Lino.chars2width(9) }, { "colIndex": 11, "dataIndex": "user", "editable": true, "editor": user2701, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.CoursesBySlot.user) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "every_unit", "editable": true, "editor": every_unit2702, "filter": { "type": "string" }, "header": "Korduvus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.every_unit) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 13, "dataIndex": "every", "editable": true, "editor": every2703, "filter": { "type": "numeric" }, "format": "0", "header": "Korda iga", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.every) ", "width": Lino.chars2width(6) }, { "colIndex": 14, "dataIndex": "monday", "editable": true, "filter": { "type": "boolean" }, "header": "esmasp\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.monday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 15, "dataIndex": "tuesday", "editable": true, "filter": { "type": "boolean" }, "header": "teisip\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.tuesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 16, "dataIndex": "wednesday", "editable": true, "filter": { "type": "boolean" }, "header": "kolmap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.wednesday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 17, "dataIndex": "thursday", "editable": true, "filter": { "type": "boolean" }, "header": "neljap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.thursday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 18, "dataIndex": "friday", "editable": true, "filter": { "type": "boolean" }, "header": "reede", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.friday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 19, "dataIndex": "saturday", "editable": true, "filter": { "type": "boolean" }, "header": "laup\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.saturday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 20, "dataIndex": "sunday", "editable": true, "filter": { "type": "boolean" }, "header": "p\u00fchap\u00e4ev", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.sunday) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "align": "right", "colIndex": 21, "dataIndex": "max_events", "editable": true, "editor": max_events2711, "filter": { "type": "numeric" }, "format": "0", "header": "S\u00fcndmuste arv", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.max_events) ", "width": Lino.chars2width(6) }, { "colIndex": 22, "dataIndex": "max_date", "editable": true, "editor": max_date2712, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Genereeri s\u00fcndmusi kuni", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.max_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 23, "dataIndex": "description", "editable": true, "editor": description2713, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.description) ", "width": Lino.chars2width(61) }, { "colIndex": 24, "dataIndex": "description_et", "editable": true, "editor": description_et2714, "filter": { "type": "string" }, "header": "Kirjeldus (et)", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.description_et) ", "width": Lino.chars2width(61) }, { "colIndex": 25, "dataIndex": "remark", "editable": true, "editor": remark2715, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.remark) ", "width": Lino.chars2width(61) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state2716, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.state) The ChoiceList of the state field must have at least two items\nnamed \"draft\" and \"registered\".\nThere may be additional states.\nEvery state must have an extra attribute \"editable\".", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 27, "dataIndex": "max_places", "editable": true, "editor": max_places2717, "filter": { "type": "numeric" }, "format": "0", "header": "Available places", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.max_places) Maximum number of participants", "width": Lino.chars2width(6) }, { "colIndex": 28, "dataIndex": "enrolments_until", "editable": true, "editor": enrolments_until2718, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Enrolments until", "hidden": true, "sortable": true, "tooltip": "(courses.CoursesBySlot.enrolments_until) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 29, "dataIndex": "events_text", "editable": false, "header": "Calendar entries", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.events_text) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 30, "dataIndex": "enrolments", "editable": false, "format": "0", "header": "Osav\u00f5tud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.enrolments) ", "width": Lino.chars2width(6) }, { "colIndex": 31, "dataIndex": "print_actions", "editable": false, "header": "Tr\u00fcki", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.print_actions) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 32, "dataIndex": "requested", "editable": false, "format": "0", "header": "Taotlus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.requested) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 33, "dataIndex": "confirmed", "editable": false, "format": "0", "header": "Kinnitatud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.confirmed) ", "width": Lino.chars2width(6) }, { "colIndex": 34, "dataIndex": "presences_box", "editable": false, "header": "Kohalolekud", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.presences_box) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 35, "dataIndex": "trying", "editable": false, "format": "0", "header": "Katseaeg", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.trying) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 36, "dataIndex": "free_places", "editable": false, "format": "0", "header": "Free places", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.free_places) ", "width": Lino.chars2width(6) }, { "colIndex": 37, "dataIndex": "weekdays_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.weekdays_text) ", "width": Lino.chars2width(31) }, { "colIndex": 38, "dataIndex": "times_text", "editable": false, "header": "Times", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.times_text) ", "width": Lino.chars2width(31) }, { "colIndex": 39, "dataIndex": "what_text", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.what_text) ", "width": Lino.chars2width(31) }, { "colIndex": 40, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 41, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.overview) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 43, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(courses.CoursesBySlot.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 44, "dataIndex": "slot", "editable": true, "editor": slot2734, "filter": { "type": "string" }, "header": "Timetable Slot", "hidden": true, "renderer": Lino.fk_renderer('slotHidden','Lino.courses.Slots.detail'), "sortable": false, "tooltip": "(courses.CoursesBySlot.slot) ", "width": Lino.chars2width(21) } ];
    Lino.courses.CoursesBySlot.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesBySlot.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesBySlot.insertPanel = Ext.extend(Lino.courses.Activities.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/CoursesBySlot",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesBySlot.detail;
    this.ls_insert_handler = Lino.courses.CoursesBySlot.insert;
    Lino.courses.CoursesBySlot.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesBySlot.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.CoursesBySlot.insertPanel(p);
});
Lino.courses.CoursesBySlot.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.CoursesBySlot.detailPanel = Ext.extend(Lino.courses.Activities.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "iconCls": null, "menu": [ { "auto_save": true, "itemId": "print_presence_sheet_html", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht (HTML)", "overflowText": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)" }, { "auto_save": true, "itemId": "print_presence_sheet", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Print using a hard-coded template and without cache.") }, "menu_item_text": "Kohalolekuteleht", "overflowText": "Kohalolekuteleht", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet), "text": "Kohalolekuteleht" } ], "menu_item_text": "Kohalolekuteleht (HTML)", "panel_btn_handler": Lino.param_action_handler(Lino.courses.Activities.print_presence_sheet_html), "text": "Kohalolekuteleht (HTML)", "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "do_update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('do_update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/courses/CoursesBySlot",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.CoursesBySlot.detail;
    this.ls_insert_handler = Lino.courses.CoursesBySlot.insert;
    Lino.courses.CoursesBySlot.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CoursesBySlot.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.CoursesBySlot.detailPanel(p);
});
Lino.courses.CoursesBySlot.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Activities.ParamsPanel({});
  return new Lino.courses.CoursesBySlot.GridPanel(p);
});
Lino.courses.CoursesBySlot.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CoursesBySlot.do_update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CoursesBySlot", "GET", pk, "do_update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.EnrolmentsByPupil
Lino.courses.EnrolmentsByPupil.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/EnrolmentsByPupil",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/EnrolmentsByPupil','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/EnrolmentsByPupil','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Osav\u00f5tud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 26,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "name": "course" }, 'courseHidden', { "name": "user" }, 'userHidden', { "name": "remark" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "printed_by" }, 'printed_byHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "state" }, 'stateHidden', { "name": "places", "type": "int", "useNull": true }, { "name": "confirmation_details" }, { "name": "pupil_info" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "printed" }, { "name": "pupil" }, 'pupilHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EnrolmentsByPupil.detail;
    this.ls_insert_handler = Lino.courses.EnrolmentsByPupil.insert;
    var ww = this.containing_window;
    var request_date7006 = new Lino.DateField({ "allowBlank": false, "selectOnFocus": true });
    var course7007 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByPupil/course" }) }) });
    var user7008 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByPupil/user" }) }) });
    var remark7009 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp7010 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id7011 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date7012 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date7013 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var printed_by7014 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var course_area7015 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "hidden": true, "store": [['','<br>']].concat(Lino.courses.CourseAreas) });
    var state7016 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.EnrolmentStates });
    var places7017 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var confirmation_details7018 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Confirmation details" });
    var pupil_info_htmlbox7019 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "pupil_info", "title": "Participant", "value": "<br/>" });
    var mobile_item_disp7020 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7021 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7022 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var printed_disp7023 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var pupil7024 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByPupil/pupil" }) }) });
    this.before_row_edit = function(record) {
      course7007.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course7007.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      confirmation_details7018.refresh();
      pupil_info_htmlbox7019.refresh();
      pupil7024.setContextValue('course', record ? record.data['courseHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      course_area7015.on('change',Lino.chooser_handler(course7007,'course_area'));
      request_date7006.on('change',Lino.chooser_handler(course7007,'request_date'));
      course7007.on('change',Lino.chooser_handler(pupil7024,'course'));
      Lino.courses.EnrolmentsByPupil.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "request_date", "editable": true, "editor": request_date7006, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "sortable": true, "tooltip": "(courses.EnrolmentsByPupil.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "course", "editable": true, "editor": course7007, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.course) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user7008, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark7009, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(courses.EnrolmentsByPupil.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id7011, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByPupil.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date7012, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByPupil.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date7013, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByPupil.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "course_area", "editable": false, "filter": { "type": "string" }, "header": "Layout", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.course_area) ", "width": Lino.chars2width(14) }, { "colIndex": 10, "dataIndex": "state", "editable": true, "editor": state7016, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.state) One of lino_xl.lib.courses.choicelists.EnrolmentStates.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 11, "dataIndex": "places", "editable": true, "editor": places7017, "filter": { "type": "numeric" }, "format": "0", "header": "Places used", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByPupil.places) The number of participants in this enrolment.", "width": Lino.chars2width(6) }, { "colIndex": 12, "dataIndex": "confirmation_details", "editable": true, "editor": confirmation_details7018, "filter": { "type": "string" }, "header": "Confirmation details", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.confirmation_details) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "pupil_info", "editable": false, "header": "Participant", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.pupil_info) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.printed) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "pupil", "editable": true, "editor": pupil7024, "filter": { "type": "string" }, "header": "Inimene", "hidden": true, "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByPupil.pupil) ", "width": Lino.chars2width(21) } ];
    Lino.courses.EnrolmentsByPupil.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentsByPupil.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.EnrolmentsByPupil.insertPanel = Ext.extend(Lino.courses.EnrolmentsByPupil.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/EnrolmentsByPupil",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EnrolmentsByPupil.detail;
    this.ls_insert_handler = Lino.courses.EnrolmentsByPupil.insert;
    Lino.courses.EnrolmentsByPupil.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentsByPupil.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.EnrolmentsByPupil.insertPanel(p);
});
Lino.courses.EnrolmentsByPupil.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.EnrolmentsByPupil.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/EnrolmentsByPupil",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EnrolmentsByPupil.detail;
    this.ls_insert_handler = Lino.courses.EnrolmentsByPupil.insert;
    Lino.courses.EnrolmentsByPupil.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentsByPupil.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.EnrolmentsByPupil.detailPanel(p);
});
Lino.courses.EnrolmentsByPupil.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByPupil.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Enrolments.ParamsPanel({});
  return new Lino.courses.EnrolmentsByPupil.GridPanel(p);
});
Lino.courses.EnrolmentsByPupil.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByPupil", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.EnrolmentsByCourse
Lino.courses.EnrolmentsByCourse.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/EnrolmentsByCourse",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/EnrolmentsByCourse','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/EnrolmentsByCourse','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "Osav\u00f5tud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 26,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "name": "pupil" }, 'pupilHidden', { "name": "places", "type": "int", "useNull": true }, { "name": "remark" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "printed_by" }, 'printed_byHidden', { "name": "course_area" }, 'course_areaHidden', { "name": "state" }, 'stateHidden', { "name": "confirmation_details" }, { "name": "pupil_info" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "printed" }, { "name": "course" }, 'courseHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EnrolmentsByCourse.detail;
    this.ls_insert_handler = Lino.courses.EnrolmentsByCourse.insert;
    var ww = this.containing_window;
    var request_date7026 = new Lino.DateField({ "allowBlank": false, "selectOnFocus": true });
    var pupil7027 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByCourse/pupil" }) }) });
    var places7028 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 1 });
    var remark7029 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp7030 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id7031 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date7032 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date7033 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var user7034 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByCourse/user" }) }) });
    var printed_by7035 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var course_area7036 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "hidden": true, "store": [['','<br>']].concat(Lino.courses.CourseAreas) });
    var state7037 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.EnrolmentStates });
    var confirmation_details7038 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Confirmation details" });
    var pupil_info_htmlbox7039 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "pupil_info", "title": "Participant", "value": "<br/>" });
    var mobile_item_disp7040 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7041 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7042 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var printed_disp7043 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var course7044 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/EnrolmentsByCourse/course" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      pupil7027.setContextValue('mk',bp['mk']);
      pupil7027.setContextValue('mt',bp['mt']);
      confirmation_details7038.refresh();
      pupil_info_htmlbox7039.refresh();
      course7044.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course7044.setContextValue('request_date', record ? record.data['request_date'] : undefined);
    };
    this.onRender = function(ct, position) {
      course7044.on('change',Lino.chooser_handler(pupil7027,'course'));
      course_area7036.on('change',Lino.chooser_handler(course7044,'course_area'));
      request_date7026.on('change',Lino.chooser_handler(course7044,'request_date'));
      Lino.courses.EnrolmentsByCourse.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "request_date", "editable": true, "editor": request_date7026, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "sortable": true, "tooltip": "(courses.EnrolmentsByCourse.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "pupil", "editable": true, "editor": pupil7027, "filter": { "type": "string" }, "header": "Inimene", "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.pupil) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 2, "dataIndex": "places", "editable": true, "editor": places7028, "filter": { "type": "numeric" }, "format": "0", "header": "Places used", "sortable": true, "tooltip": "(courses.EnrolmentsByCourse.places) The number of participants in this enrolment.", "width": Lino.chars2width(6) }, { "colIndex": 3, "dataIndex": "remark", "editable": true, "editor": remark7029, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(courses.EnrolmentsByCourse.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id7031, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByCourse.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date7032, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByCourse.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "end_date", "editable": true, "editor": end_date7033, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.EnrolmentsByCourse.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "user", "editable": true, "editor": user7034, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.user) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "course_area", "editable": false, "filter": { "type": "string" }, "header": "Layout", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.course_area) ", "width": Lino.chars2width(14) }, { "colIndex": 11, "dataIndex": "state", "editable": true, "editor": state7037, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.state) One of lino_xl.lib.courses.choicelists.EnrolmentStates.", "width": Lino.chars2width(13) }, { "colIndex": 12, "dataIndex": "confirmation_details", "editable": true, "editor": confirmation_details7038, "filter": { "type": "string" }, "header": "Confirmation details", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.confirmation_details) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "pupil_info", "editable": false, "header": "Participant", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.pupil_info) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.printed) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "course", "editable": true, "editor": course7044, "filter": { "type": "string" }, "header": "Tegevus", "hidden": true, "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.EnrolmentsByCourse.course) ", "width": Lino.chars2width(21) } ];
    Lino.courses.EnrolmentsByCourse.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentsByCourse.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.EnrolmentsByCourse.insertPanel = Ext.extend(Lino.courses.EnrolmentsByCourse.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/EnrolmentsByCourse",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EnrolmentsByCourse.detail;
    this.ls_insert_handler = Lino.courses.EnrolmentsByCourse.insert;
    Lino.courses.EnrolmentsByCourse.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentsByCourse.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.EnrolmentsByCourse.insertPanel(p);
});
Lino.courses.EnrolmentsByCourse.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.EnrolmentsByCourse.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/EnrolmentsByCourse",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.EnrolmentsByCourse.detail;
    this.ls_insert_handler = Lino.courses.EnrolmentsByCourse.insert;
    Lino.courses.EnrolmentsByCourse.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentsByCourse.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.EnrolmentsByCourse.detailPanel(p);
});
Lino.courses.EnrolmentsByCourse.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentsByCourse.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.Enrolments.ParamsPanel({});
  return new Lino.courses.EnrolmentsByCourse.GridPanel(p);
});
Lino.courses.EnrolmentsByCourse.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentsByCourse", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class courses.MyEnrolments
Lino.courses.MyEnrolments.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/courses/MyEnrolments",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/MyEnrolments','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/MyEnrolments','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  cell_edit : true,
  title : "My enrolments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 27,
  ls_store_fields : [ { "name": "course" }, 'courseHidden', { "name": "course__name" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "user" }, 'userHidden', { "name": "printed_by" }, 'printed_byHidden', { "name": "course_area" }, 'course_areaHidden', { "dateFormat": "d.m.Y", "name": "request_date", "type": "date" }, { "name": "state" }, 'stateHidden', { "name": "places", "type": "int", "useNull": true }, { "name": "remark" }, { "name": "confirmation_details" }, { "name": "pupil_info" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "printed" }, { "name": "pupil" }, 'pupilHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 28,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.MyEnrolments.detail;
    this.ls_insert_handler = Lino.courses.MyEnrolments.insert;
    var ww = this.containing_window;
    var course7046 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyEnrolments/course" }) }) });
    var course__name7047 = new Ext.form.TextField({ "disabled": true, "maxLength": 100, "sortable": false });
    var workflow_buttons_disp7048 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id7049 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var start_date7050 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_date7051 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var user7052 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyEnrolments/user" }) }) });
    var printed_by7053 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5te...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var course_area7054 = new Lino.ChoicesFieldElement({ "disabled": true, "forceSelection": true, "hidden": true, "store": [['','<br>']].concat(Lino.courses.CourseAreas) });
    var request_date7055 = new Lino.DateField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var state7056 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.courses.EnrolmentStates });
    var places7057 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 1 });
    var remark7058 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var confirmation_details7059 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Confirmation details" });
    var pupil_info_htmlbox7060 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "pupil_info", "title": "Participant", "value": "<br/>" });
    var mobile_item_disp7061 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7062 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7063 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var printed_disp7064 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var pupil7065 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Inimene...", "forceSelection": false, "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/courses/MyEnrolments/pupil" }) }) });
    this.before_row_edit = function(record) {
      course7046.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course7046.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      confirmation_details7059.refresh();
      pupil_info_htmlbox7060.refresh();
      pupil7065.setContextValue('course', record ? record.data['courseHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      course_area7054.on('change',Lino.chooser_handler(course7046,'course_area'));
      request_date7055.on('change',Lino.chooser_handler(course7046,'request_date'));
      course7046.on('change',Lino.chooser_handler(pupil7065,'course'));
      Lino.courses.MyEnrolments.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "course", "editable": true, "editor": course7046, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('courseHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(courses.MyEnrolments.course) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "course__name", "editable": false, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(courses.MyEnrolments.course__name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(courses.MyEnrolments.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7049, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(courses.MyEnrolments.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "start_date", "editable": true, "editor": start_date7050, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.MyEnrolments.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 5, "dataIndex": "end_date", "editable": true, "editor": end_date7051, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "L\u00f5peb (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(courses.MyEnrolments.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 6, "dataIndex": "user", "editable": true, "editor": user7052, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(courses.MyEnrolments.user) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "printed_by", "editable": false, "filter": { "type": "string" }, "header": "Tr\u00fckitud", "hidden": true, "renderer": Lino.fk_renderer('printed_byHidden','Lino.excerpts.Excerpts.detail'), "sortable": false, "tooltip": "(courses.MyEnrolments.printed_by) ForeignKey to the Excerpt which certifies this instance.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "course_area", "editable": false, "filter": { "type": "string" }, "header": "Layout", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.course_area) ", "width": Lino.chars2width(14) }, { "colIndex": 9, "dataIndex": "request_date", "editable": true, "editor": request_date7055, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Date of request", "hidden": true, "sortable": true, "tooltip": "(courses.MyEnrolments.request_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 10, "dataIndex": "state", "editable": true, "editor": state7056, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.state) One of lino_xl.lib.courses.choicelists.EnrolmentStates.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 11, "dataIndex": "places", "editable": true, "editor": places7057, "filter": { "type": "numeric" }, "format": "0", "header": "Places used", "hidden": true, "sortable": true, "tooltip": "(courses.MyEnrolments.places) The number of participants in this enrolment.", "width": Lino.chars2width(6) }, { "colIndex": 12, "dataIndex": "remark", "editable": true, "editor": remark7058, "filter": { "type": "string" }, "header": "M\u00e4rkus", "hidden": true, "sortable": true, "tooltip": "(courses.MyEnrolments.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 13, "dataIndex": "confirmation_details", "editable": true, "editor": confirmation_details7059, "filter": { "type": "string" }, "header": "Confirmation details", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.confirmation_details) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "pupil_info", "editable": false, "header": "Participant", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.pupil_info) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 18, "dataIndex": "printed", "editable": false, "header": "Tr\u00fckitud", "hidden": true, "sortable": false, "tooltip": "(courses.MyEnrolments.printed) ", "width": Lino.chars2width(31) }, { "colIndex": 19, "dataIndex": "pupil", "editable": true, "editor": pupil7065, "filter": { "type": "string" }, "header": "Inimene", "hidden": true, "renderer": Lino.fk_renderer('pupilHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(courses.MyEnrolments.pupil) ", "width": Lino.chars2width(21) } ];
    Lino.courses.MyEnrolments.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.MyEnrolments.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.MyEnrolments.insertPanel = Ext.extend(Lino.courses.Enrolments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/courses/MyEnrolments",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.MyEnrolments.detail;
    this.ls_insert_handler = Lino.courses.MyEnrolments.insert;
    Lino.courses.MyEnrolments.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.MyEnrolments.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.courses.MyEnrolments.insertPanel(p);
});
Lino.courses.MyEnrolments.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.courses.MyEnrolments.detailPanel = Ext.extend(Lino.courses.Enrolments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Enrolment", "overflowText": "Enrolment", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Create an excerpt in order to print this data record." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "clear_printed", "menu_item_text": "Clear print cache", "overflowText": "Clear print cache", "panel_btn_handler": Lino.row_action_handler('clear_printed','GET',null), "tooltip": "Mark this object as not printed. A subsequent call to print will generate a new cache file." } ],
  ls_url: "/courses/MyEnrolments",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.MyEnrolments.detail;
    this.ls_insert_handler = Lino.courses.MyEnrolments.insert;
    Lino.courses.MyEnrolments.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.MyEnrolments.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.MyEnrolments.detailPanel(p);
});
Lino.courses.MyEnrolments.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.clear_printed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "clear_printed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.MyEnrolments.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.courses.MyEnrolments.ParamsPanel({});
  return new Lino.courses.MyEnrolments.GridPanel(p);
});
Lino.courses.MyEnrolments.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/MyEnrolments", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class deploy.DeploymentsByMilestone
Lino.deploy.DeploymentsByMilestone.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/deploy/DeploymentsByMilestone",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/deploy/DeploymentsByMilestone','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/deploy/DeploymentsByMilestone','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Wishes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "seqno", "type": "int", "useNull": true }, { "name": "move_buttons" }, { "name": "ticket" }, 'ticketHidden', { "name": "old_ticket_state" }, 'old_ticket_stateHidden', { "name": "new_ticket_state" }, 'new_ticket_stateHidden', { "name": "wish_type" }, 'wish_typeHidden', { "name": "remark" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "deferred_to" }, 'deferred_toHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "milestone" }, 'milestoneHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 12,
  ls_grid_configs : [  ],
  content_type : 50,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.DeploymentsByMilestone.detail;
    this.ls_insert_handler = Lino.deploy.DeploymentsByMilestone.insert;
    var ww = this.containing_window;
    var seqno2028 = new Ext.form.NumberField({ "selectOnFocus": true });
    var move_buttons_disp2029 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var ticket2030 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByMilestone/ticket" }) }) });
    var old_ticket_state2031 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var new_ticket_state2032 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var wish_type2033 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.deploy.WishTypes) });
    var remark2034 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var workflow_buttons_disp2035 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id2036 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var deferred_to2037 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByMilestone/deferred_to" }) }) });
    var mobile_item_disp2038 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2039 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2040 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var milestone2041 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByMilestone/milestone" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "seqno", "editable": true, "editor": seqno2028, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(deploy.DeploymentsByMilestone.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "move_buttons", "editable": false, "header": "Move", "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 2, "dataIndex": "ticket", "editable": true, "editor": ticket2030, "filter": { "type": "string" }, "header": "Lipik", "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.ticket) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "old_ticket_state", "editable": true, "editor": old_ticket_state2031, "filter": { "type": "string" }, "header": "", "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.old_ticket_state) ", "width": Lino.chars2width(12) }, { "colIndex": 4, "dataIndex": "new_ticket_state", "editable": true, "editor": new_ticket_state2032, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.new_ticket_state) ", "width": Lino.chars2width(12) }, { "colIndex": 5, "dataIndex": "wish_type", "editable": true, "editor": wish_type2033, "filter": { "type": "string" }, "header": "Wish type", "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.wish_type) ", "width": Lino.chars2width(16) }, { "colIndex": 6, "dataIndex": "remark", "editable": true, "editor": remark2034, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 8, "dataIndex": "id", "editable": true, "editor": id2036, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(deploy.DeploymentsByMilestone.id) ", "width": Lino.chars2width(6) }, { "colIndex": 9, "dataIndex": "deferred_to", "editable": true, "editor": deferred_to2037, "filter": { "type": "string" }, "header": "Deferred to", "hidden": true, "renderer": Lino.fk_renderer('deferred_toHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.deferred_to) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "milestone", "editable": true, "editor": milestone2041, "filter": { "type": "string" }, "header": "Tegevus", "hidden": true, "renderer": Lino.fk_renderer('milestoneHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(deploy.DeploymentsByMilestone.milestone) ", "width": Lino.chars2width(21) } ];
    Lino.deploy.DeploymentsByMilestone.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.DeploymentsByMilestone.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.deploy.DeploymentsByMilestone.insertPanel = Ext.extend(Lino.deploy.DeploymentsByMilestone.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/deploy/DeploymentsByMilestone",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.DeploymentsByMilestone.detail;
    this.ls_insert_handler = Lino.deploy.DeploymentsByMilestone.insert;
    Lino.deploy.DeploymentsByMilestone.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.DeploymentsByMilestone.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.deploy.DeploymentsByMilestone.insertPanel(p);
});
Lino.deploy.DeploymentsByMilestone.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.deploy.DeploymentsByMilestone.detailPanel = Ext.extend(Lino.deploy.Deployments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/deploy/DeploymentsByMilestone",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.DeploymentsByMilestone.detail;
    this.ls_insert_handler = Lino.deploy.DeploymentsByMilestone.insert;
    Lino.deploy.DeploymentsByMilestone.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.DeploymentsByMilestone.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "is_main_window": true };
  return new Lino.deploy.DeploymentsByMilestone.detailPanel(p);
});
Lino.deploy.DeploymentsByMilestone.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.deploy.Deployments.ParamsPanel({});
  return new Lino.deploy.DeploymentsByMilestone.GridPanel(p);
});
Lino.deploy.DeploymentsByMilestone.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByMilestone.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByMilestone", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class deploy.DeploymentsByTicket
Lino.deploy.DeploymentsByTicket.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/deploy/DeploymentsByTicket",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/deploy/DeploymentsByTicket','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/deploy/DeploymentsByTicket','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Wishes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "milestone" }, 'milestoneHidden', { "name": "wish_type" }, 'wish_typeHidden', { "name": "remark" }, { "name": "id", "type": "int" }, { "name": "seqno", "type": "int", "useNull": true }, { "name": "old_ticket_state" }, 'old_ticket_stateHidden', { "name": "new_ticket_state" }, 'new_ticket_stateHidden', { "name": "deferred_to" }, 'deferred_toHidden', { "name": "workflow_buttons" }, { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "ticket" }, 'ticketHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 50,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.DeploymentsByTicket.detail;
    this.ls_insert_handler = Lino.deploy.DeploymentsByTicket.insert;
    var ww = this.containing_window;
    var milestone7067 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Tegevus...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByTicket/milestone" }) }) });
    var wish_type7068 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.deploy.WishTypes) });
    var remark7069 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var id7070 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var seqno7071 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var old_ticket_state7072 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var new_ticket_state7073 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var deferred_to7074 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Tegevus...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByTicket/deferred_to" }) }) });
    var workflow_buttons_disp7075 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var move_buttons_disp7076 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp7077 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7078 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7079 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var ticket7080 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Lipik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/deploy/DeploymentsByTicket/ticket" }) }) });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "milestone", "editable": true, "editor": milestone7067, "filter": { "type": "string" }, "header": "Tegevus", "renderer": Lino.fk_renderer('milestoneHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.milestone) ", "width": Lino.chars2width(21) }, { "colIndex": 1, "dataIndex": "wish_type", "editable": true, "editor": wish_type7068, "filter": { "type": "string" }, "header": "Wish type", "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.wish_type) ", "width": Lino.chars2width(16) }, { "colIndex": 2, "dataIndex": "remark", "editable": true, "editor": remark7069, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.remark) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7070, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(deploy.DeploymentsByTicket.id) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 4, "dataIndex": "seqno", "editable": true, "editor": seqno7071, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(deploy.DeploymentsByTicket.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "old_ticket_state", "editable": true, "editor": old_ticket_state7072, "filter": { "type": "string" }, "header": "", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.old_ticket_state) ", "width": Lino.chars2width(12) }, { "colIndex": 6, "dataIndex": "new_ticket_state", "editable": true, "editor": new_ticket_state7073, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.new_ticket_state) ", "width": Lino.chars2width(12) }, { "colIndex": 7, "dataIndex": "deferred_to", "editable": true, "editor": deferred_to7074, "filter": { "type": "string" }, "header": "Deferred to", "hidden": true, "renderer": Lino.fk_renderer('deferred_toHidden','Lino.courses.Activities.detail'), "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.deferred_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "ticket", "editable": true, "editor": ticket7080, "filter": { "type": "string" }, "header": "Lipik", "hidden": true, "renderer": Lino.fk_renderer('ticketHidden','Lino.tickets.Tickets.detail'), "sortable": false, "tooltip": "(deploy.DeploymentsByTicket.ticket) ", "width": Lino.chars2width(21) } ];
    Lino.deploy.DeploymentsByTicket.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.DeploymentsByTicket.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.deploy.DeploymentsByTicket.insertPanel = Ext.extend(Lino.deploy.DeploymentsByTicket.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/deploy/DeploymentsByTicket",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.DeploymentsByTicket.detail;
    this.ls_insert_handler = Lino.deploy.DeploymentsByTicket.insert;
    Lino.deploy.DeploymentsByTicket.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.DeploymentsByTicket.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.deploy.DeploymentsByTicket.insertPanel(p);
});
Lino.deploy.DeploymentsByTicket.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.deploy.DeploymentsByTicket.detailPanel = Ext.extend(Lino.deploy.Deployments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  ls_url: "/deploy/DeploymentsByTicket",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.deploy.DeploymentsByTicket.detail;
    this.ls_insert_handler = Lino.deploy.DeploymentsByTicket.insert;
    Lino.deploy.DeploymentsByTicket.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.DeploymentsByTicket.detail = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(15), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "is_main_window": true };
  return new Lino.deploy.DeploymentsByTicket.detailPanel(p);
});
Lino.deploy.DeploymentsByTicket.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.deploy.Deployments.ParamsPanel({});
  return new Lino.deploy.DeploymentsByTicket.GridPanel(p);
});
Lino.deploy.DeploymentsByTicket.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.start_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "start_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.DeploymentsByTicket.end_session = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/DeploymentsByTicket", "GET", pk, "end_session", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class meetings.MembersByMeeting
Lino.meetings.MembersByMeeting.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/meetings/MembersByMeeting",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/MembersByMeeting','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/MembersByMeeting','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "itemId": "move_up", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row upwards.") }, "menu_item_text": "\u25b2", "overflowText": "\u25b2", "panel_btn_handler": Lino.row_action_handler('move_up','GET',null), "text": " <font size=\"4\">\u25b2</font>" }, { "auto_save": true, "itemId": "move_down", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Move this row one row downwards.") }, "menu_item_text": "\u25bc", "overflowText": "\u25bc", "panel_btn_handler": Lino.row_action_handler('move_down','GET',null), "text": " <font size=\"4\">\u25bc</font>" } ],
  cell_edit : true,
  title : "Members",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "seqno", "type": "int", "useNull": true }, { "name": "partner" }, 'partnerHidden', { "name": "remark" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "list" }, 'listHidden', { "name": "move_buttons" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 55,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var seqno2056 = new Ext.form.NumberField({ "selectOnFocus": true });
    var partner2057 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partner...", "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/MembersByMeeting/partner" }) }) });
    var remark2058 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp2059 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id2060 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var list2061 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Partnerite nimekiri...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/meetings/MembersByMeeting/list" }) }) });
    var move_buttons_disp2062 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp2063 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2064 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2065 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "seqno", "editable": true, "editor": seqno2056, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "sortable": true, "tooltip": "(meetings.MembersByMeeting.seqno) The sequence number of this item with its parent.", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "partner", "editable": true, "editor": partner2057, "filter": { "type": "string" }, "header": "Partner", "renderer": Lino.fk_renderer('partnerHidden','Lino.contacts.Partners.detail'), "sortable": false, "tooltip": "(meetings.MembersByMeeting.partner) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "remark", "editable": true, "editor": remark2058, "filter": { "type": "string" }, "header": "M\u00e4rkus", "sortable": true, "tooltip": "(meetings.MembersByMeeting.remark) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(meetings.MembersByMeeting.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id2060, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(meetings.MembersByMeeting.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "list", "editable": true, "editor": list2061, "filter": { "type": "string" }, "header": "Partnerite nimekiri", "hidden": true, "renderer": Lino.fk_renderer('listHidden','Lino.lists.Lists.detail'), "sortable": false, "tooltip": "(meetings.MembersByMeeting.list) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "move_buttons", "editable": false, "header": "Move", "hidden": true, "sortable": false, "tooltip": "(meetings.MembersByMeeting.move_buttons) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.MembersByMeeting.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(meetings.MembersByMeeting.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(meetings.MembersByMeeting.overview) ", "width": Lino.chars2width(31) } ];
    Lino.meetings.MembersByMeeting.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.MembersByMeeting.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.MembersByMeeting.GridPanel(p);
});
Lino.meetings.MembersByMeeting.move_up = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "move_up", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MembersByMeeting.move_down = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MembersByMeeting", "GET", pk, "move_down", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class uploads.UploadsByController
Lino.uploads.UploadsByController.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/uploads/UploadsByController",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadsByController','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadsByController','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Uploads",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "name": "file" }, { "name": "type" }, 'typeHidden', { "name": "description" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "mimetype" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "upload_area" }, 'upload_areaHidden', { "name": "description_link" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 62,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadsByController.detail;
    this.ls_insert_handler = Lino.uploads.UploadsByController.insert;
    var ww = this.containing_window;
    var file7082 = Lino.file_field_handler(this,{ "maxLength": 100, "selectOnFocus": true });
    var type7083 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Upload Type...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByController/type" }) }) });
    var description7084 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user7085 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByController/user" }) }) });
    var id7086 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var mimetype7087 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": 255 });
    var owner_type7088 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByController/owner_type" }) }) });
    var owner_id7089 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/uploads/UploadsByController/owner_id" }) }) });
    var upload_area7090 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.uploads.UploadAreas });
    var description_link_disp7091 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp7092 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7093 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7094 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7095 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var owner_disp7096 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      type7083.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
      owner_id7089.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      upload_area7090.on('change',Lino.chooser_handler(type7083,'upload_area'));
      owner_type7088.on('change',Lino.chooser_handler(owner_id7089,'owner_type'));
      Lino.uploads.UploadsByController.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "file", "editable": true, "editor": file7082, "filter": { "type": "string" }, "header": "Fail", "sortable": true, "tooltip": "(uploads.UploadsByController.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "type", "editable": true, "editor": type7083, "filter": { "type": "string" }, "header": "Upload Type", "renderer": Lino.fk_renderer('typeHidden','Lino.uploads.UploadTypes.detail'), "sortable": false, "tooltip": "(uploads.UploadsByController.type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "description", "editable": true, "editor": description7084, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": true, "tooltip": "(uploads.UploadsByController.description) A short description entered manually by the user.", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "user", "editable": true, "editor": user7085, "filter": { "type": "string" }, "header": "Uploaded by", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(uploads.UploadsByController.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 4, "dataIndex": "id", "editable": true, "editor": id7086, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(uploads.UploadsByController.id) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "mimetype", "editable": false, "filter": { "type": "string" }, "header": "MIME type", "hidden": true, "sortable": true, "tooltip": "(uploads.UploadsByController.mimetype) The Media type\nof the file.  See also this thread\nabout length of MIME type field.", "width": Lino.chars2width(22) }, { "colIndex": 6, "dataIndex": "owner_type", "editable": true, "editor": owner_type7088, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(uploads.UploadsByController.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "owner_id", "editable": true, "editor": owner_id7089, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "upload_area", "editable": true, "editor": upload_area7090, "filter": { "type": "string" }, "header": "Upload Area", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.upload_area) ", "width": Lino.chars2width(11) }, { "colIndex": 9, "dataIndex": "description_link", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.description_link) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadsByController.owner) ", "width": Lino.chars2width(11) } ];
    Lino.uploads.UploadsByController.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadsByController.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByController.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByController.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.UploadsByController.insertPanel = Ext.extend(Lino.uploads.UploadsByController.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/uploads/UploadsByController",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadsByController.detail;
    this.ls_insert_handler = Lino.uploads.UploadsByController.insert;
    Lino.uploads.UploadsByController.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadsByController.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.uploads.UploadsByController.insertPanel(p);
});
Lino.uploads.UploadsByController.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByController.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByController.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.uploads.UploadsByController.detailPanel = Ext.extend(Lino.uploads.Uploads.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/uploads/UploadsByController",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.uploads.UploadsByController.detail;
    this.ls_insert_handler = Lino.uploads.UploadsByController.insert;
    Lino.uploads.UploadsByController.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadsByController.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.UploadsByController.detailPanel(p);
});
Lino.uploads.UploadsByController.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadsByController.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.uploads.Uploads.ParamsPanel({});
  return new Lino.uploads.UploadsByController.GridPanel(p);
});
Lino.uploads.UploadsByController.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadsByController", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class cal.EntriesByController
Lino.cal.EntriesByController.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/EntriesByController",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByController','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EntriesByController','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  cell_edit : true,
  title : "events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 54,
  ls_store_fields : [ { "name": "when_html" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "start_time" }, { "dateFormat": "d.m.Y", "name": "end_date", "type": "date" }, { "name": "end_time" }, { "name": "build_time" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "user" }, 'userHidden', { "name": "assigned_to" }, 'assigned_toHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "description" }, { "name": "access_class" }, 'access_classHidden', { "name": "sequence", "type": "int", "useNull": true }, { "name": "auto_type", "type": "int", "useNull": true }, { "name": "event_type" }, 'event_typeHidden', { "name": "transparent", "type": "boolean" }, { "name": "room" }, 'roomHidden', { "name": "priority" }, 'priorityHidden', { "name": "state" }, 'stateHidden', { "name": "calendar" }, 'calendarHidden', { "name": "reminder" }, { "name": "when_text" }, { "name": "all_day", "type": "boolean" }, { "name": "url" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "created_natural" }, { "name": "duration" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 16,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByController.detail;
    this.ls_insert_handler = Lino.cal.EntriesByController.insert;
    var ww = this.containing_window;
    var when_html_disp7098 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var summary7099 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp7100 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id7101 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified7102 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created7103 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date7104 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time7105 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date7106 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time7107 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time7108 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method7109 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company7110 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/company" }) }) });
    var contact_person7111 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/contact_person" }) }) });
    var contact_role7112 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/contact_role" }) }) });
    var user7113 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/user" }) }) });
    var assigned_to7114 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/assigned_to" }) }) });
    var owner_type7115 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/owner_type" }) }) });
    var owner_id7116 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/owner_id" }) }) });
    var description7117 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class7118 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence7119 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type7120 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var event_type7121 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/event_type" }) }) });
    var transparent7122 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var room7123 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Ruum...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/room" }) }) });
    var priority7124 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Priority...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/EntriesByController/priority" }) }) });
    var state7125 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var calendar7126 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var reminder_disp7127 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp7128 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day7129 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp7130 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp7131 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7132 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7133 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp7134 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration7135 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    var owner_disp7136 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      contact_person7111.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id7116.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company7110.on('change',Lino.chooser_handler(contact_person7111,'company'));
      owner_type7115.on('change',Lino.chooser_handler(owner_id7116,'owner_type'));
      Lino.cal.EntriesByController.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "when_html", "editable": false, "header": "Millal", "sortable": false, "tooltip": "(cal.EntriesByController.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary7099, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.EntriesByController.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.EntriesByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7101, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date7104, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "start_time", "editable": true, "editor": start_time7105, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date7106, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "end_time", "editable": true, "editor": end_time7107, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.end_time) These four fields define the duration of this entry.\nOnly start_date is mandatory.", "width": Lino.chars2width(9) }, { "colIndex": 10, "dataIndex": "build_time", "editable": false, "header": "build time", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 11, "dataIndex": "build_method", "editable": true, "editor": build_method7109, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 12, "dataIndex": "company", "editable": true, "editor": company7110, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_person", "editable": true, "editor": contact_person7111, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_role", "editable": true, "editor": contact_role7112, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "user", "editable": true, "editor": user7113, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to7114, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "renderer": Lino.fk_renderer('assigned_toHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.assigned_to) Another user who is expected to take responsibility for this\nentry.", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "owner_type", "editable": true, "editor": owner_type7115, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id7116, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "description", "editable": true, "editor": description7117, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 20, "dataIndex": "access_class", "editable": true, "editor": access_class7118, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 21, "dataIndex": "sequence", "editable": true, "editor": sequence7119, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 22, "dataIndex": "auto_type", "editable": true, "editor": auto_type7120, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.EntriesByController.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 23, "dataIndex": "event_type", "editable": true, "editor": event_type7121, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "hidden": true, "renderer": Lino.fk_renderer('event_typeHidden','Lino.cal.EventTypes.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.event_type) The type of this entry. Every calendar entry should have this\nfield pointing to a given EventType, which holds\nextended configurable information about this entry.", "width": Lino.chars2width(21) }, { "colIndex": 24, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "room", "editable": true, "editor": room7123, "filter": { "type": "string" }, "header": "Ruum", "hidden": true, "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.room) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "priority", "editable": true, "editor": priority7124, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 27, "dataIndex": "state", "editable": true, "editor": state7125, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.state) The state of this entry. The state can change according to\nrules defined by the workflow, that's why we sometimes refer\nto it as the life cycle.", "width": Lino.chars2width(14) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "renderer": Lino.fk_renderer('calendarHidden','Lino.cal.Calendars.detail'), "sortable": false, "tooltip": "(cal.EntriesByController.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 32, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.url) ", "width": Lino.chars2width(31) }, { "colIndex": 33, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.duration) ", "width": Lino.chars2width(8) }, { "colIndex": 38, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(cal.EntriesByController.owner) ", "width": Lino.chars2width(11) } ];
    Lino.cal.EntriesByController.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByController.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByController.insertPanel = Ext.extend(Lino.cal.Events.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/EntriesByController",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByController.detail;
    this.ls_insert_handler = Lino.cal.EntriesByController.insert;
    Lino.cal.EntriesByController.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByController.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.EntriesByController.insertPanel(p);
});
Lino.cal.EntriesByController.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.EntriesByController.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "itemId": "show_conflicting", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Show events conflicting with this one.") }, "menu_item_text": "\u00a0\u2694\u00a0", "overflowText": "\u00a0\u2694\u00a0", "panel_btn_handler": Lino.row_action_handler('show_conflicting','GET',null), "text": "\u00a0\u2694\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-calendar", "itemId": "show_today", "menu_item_text": "T\u00e4na", "overflowText": "T\u00e4na", "panel_btn_handler": Lino.row_action_handler('show_today','GET',null), "tooltip": "Show all calendar events of the same day." }, { "auto_save": true, "itemId": "update_guests", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Populate or update the list of participants for this entry\naccording to the suggestions.") }, "menu_item_text": "Update Guests", "overflowText": "Update Guests", "panel_btn_handler": Lino.row_action_handler('update_guests','GET',null), "text": "\u00a0\u2637\u00a0" }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" }, { "auto_save": true, "itemId": "update_events", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create or update the automatic events controlled by this generator.") }, "menu_item_text": "Update Events", "overflowText": "Update Events", "panel_btn_handler": Lino.row_action_handler('update_events','GET',null), "text": "\u00a0\u26a1\u00a0" } ],
  ls_url: "/cal/EntriesByController",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.EntriesByController.detail;
    this.ls_insert_handler = Lino.cal.EntriesByController.insert;
    Lino.cal.EntriesByController.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntriesByController.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EntriesByController.detailPanel(p);
});
Lino.cal.EntriesByController.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.EntriesByController.GridPanel(p);
});
Lino.cal.EntriesByController.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntriesByController.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntriesByController", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class changes.ChangesByObject
Lino.changes.ChangesByObject.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/changes/ChangesByObject",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/changes/ChangesByObject','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/changes/ChangesByObject','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" } ],
  cell_edit : true,
  title : "Changes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "time" }, { "name": "user" }, 'userHidden', { "name": "type" }, 'typeHidden', { "name": "changed_fields" }, { "name": "master" }, { "name": "master_type" }, 'master_typeHidden', { "name": "master_id" }, 'master_idHidden', { "name": "id", "type": "int" }, { "name": "object_type" }, 'object_typeHidden', { "name": "object_id" }, 'object_idHidden', { "name": "diff" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "object" }, { "name": "disabled_actions" } ],
  pk_index : 11,
  ls_grid_configs : [  ],
  content_type : 40,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.changes.ChangesByObject.detail;
    var ww = this.containing_window;
    var time7138 = new Ext.form.DisplayField({ "allowBlank": false, "selectOnFocus": true, "value": "<br>" });
    var user7139 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByObject/user" }) }) });
    var type7140 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.changes.ChangeTypes });
    var changed_fields7141 = new Ext.form.TextField({ "maxLength": 250, "selectOnFocus": true });
    var master_disp7142 = new Ext.form.DisplayField({ "disabled": true });
    var master_type7143 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByObject/master_type" }) }) });
    var master_id7144 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByObject/master_id" }) }) });
    var id7145 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var object_type7146 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByObject/object_type" }) }) });
    var object_id7147 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByObject/object_id" }) }) });
    var diff7148 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var mobile_item_disp7149 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7150 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7151 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7152 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var object_disp7153 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
    };
    this.onRender = function(ct, position) {
      master_type7143.on('change',Lino.chooser_handler(master_id7144,'master_type'));
      object_type7146.on('change',Lino.chooser_handler(object_id7147,'object_type'));
      Lino.changes.ChangesByObject.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "time", "editable": true, "editor": time7138, "header": "time", "sortable": true, "tooltip": "(changes.ChangesByObject.time) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user7139, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(changes.ChangesByObject.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "type", "editable": true, "editor": type7140, "filter": { "type": "string" }, "header": "Change Type", "sortable": false, "tooltip": "(changes.ChangesByObject.type) ", "width": Lino.chars2width(16) }, { "colIndex": 3, "dataIndex": "changed_fields", "editable": true, "editor": changed_fields7141, "filter": { "type": "string" }, "header": "Fields", "sortable": true, "tooltip": "(changes.ChangesByObject.changed_fields) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "master", "editable": false, "header": "Master", "sortable": false, "tooltip": "(changes.ChangesByObject.master) The database object which acts as \"master\".", "width": Lino.chars2width(11) }, { "colIndex": 5, "dataIndex": "master_type", "editable": true, "editor": master_type7143, "filter": { "type": "string" }, "header": "Master type", "renderer": Lino.fk_renderer('master_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(changes.ChangesByObject.master_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "master_id", "editable": true, "editor": master_id7144, "filter": { "type": "string" }, "header": "master id", "sortable": false, "tooltip": "(changes.ChangesByObject.master_id) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 7, "dataIndex": "id", "editable": true, "editor": id7145, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(changes.ChangesByObject.id) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "dataIndex": "object_type", "editable": true, "editor": object_type7146, "filter": { "type": "string" }, "header": "Object type", "hidden": true, "renderer": Lino.fk_renderer('object_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(changes.ChangesByObject.object_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "object_id", "editable": true, "editor": object_id7147, "filter": { "type": "string" }, "header": "object id", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.object_id) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "diff", "editable": true, "editor": diff7148, "filter": { "type": "string" }, "header": "Changes", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.diff) ", "width": Lino.chars2width(61) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "object", "editable": false, "header": "Object", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByObject.object) The database object which has been modified.", "width": Lino.chars2width(11) } ];
    Lino.changes.ChangesByObject.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.ChangesByObject.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByObject", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangesByObject.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByObject", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangesByObject.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByObject", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangesByObject.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByObject", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.changes.ChangesByObject.detailPanel = Ext.extend(Lino.changes.Changes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/changes/ChangesByObject",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.changes.ChangesByObject.detail;
    Lino.changes.ChangesByObject.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.ChangesByObject.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.changes.ChangesByObject.detailPanel(p);
});
Lino.changes.ChangesByObject.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.changes.Changes.ParamsPanel({});
  return new Lino.changes.ChangesByObject.GridPanel(p);
});

// js_render_GridPanel_class cal.TasksByController
Lino.cal.TasksByController.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/TasksByController",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/TasksByController','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/TasksByController','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Tasks",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 5,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "start_date", "type": "date" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 12,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.TasksByController.detail;
    this.ls_insert_handler = Lino.cal.TasksByController.insert;
    var ww = this.containing_window;
    var start_date7155 = new Lino.DateField({ "selectOnFocus": true });
    var summary7156 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp7157 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id7158 = new Ext.form.NumberField({ "selectOnFocus": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "start_date", "editable": true, "editor": start_date7155, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "sortable": true, "tooltip": "(cal.TasksByController.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary7156, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "sortable": true, "tooltip": "(cal.TasksByController.summary) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "sortable": false, "tooltip": "(cal.TasksByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7158, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.TasksByController.id) ", "width": Lino.chars2width(6) } ];
    Lino.cal.TasksByController.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TasksByController.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.TasksByController.insertPanel = Ext.extend(Lino.cal.Tasks.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/cal/TasksByController",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.TasksByController.detail;
    this.ls_insert_handler = Lino.cal.TasksByController.insert;
    Lino.cal.TasksByController.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TasksByController.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(50) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.cal.TasksByController.insertPanel(p);
});
Lino.cal.TasksByController.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.TasksByController.detailPanel = Ext.extend(Lino.cal.Tasks.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/cal/TasksByController",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.TasksByController.detail;
    this.ls_insert_handler = Lino.cal.TasksByController.insert;
    Lino.cal.TasksByController.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TasksByController.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.TasksByController.detailPanel(p);
});
Lino.cal.TasksByController.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Tasks.ParamsPanel({});
  return new Lino.cal.TasksByController.GridPanel(p);
});
Lino.cal.TasksByController.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "wf3", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TasksByController.wf4 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TasksByController", "GET", pk, "wf4", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class gfks.HelpTextsByModel
Lino.gfks.HelpTextsByModel.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/gfks/HelpTextsByModel",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/gfks/HelpTextsByModel','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/gfks/HelpTextsByModel','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Help Texts",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "field" }, { "name": "verbose_name" }, { "name": "help_text" }, { "name": "id", "type": "int" }, { "name": "content_type" }, 'content_typeHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 35,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var field1560 = new Lino.SimpleRemoteComboFieldElement({ "allowBlank": false, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/gfks/HelpTextsByModel/field" }) }) });
    var verbose_name1561 = new Ext.form.TextField({ "disabled": true, "maxLength": 200 });
    var help_text1562 = new Ext.form.TextArea({ "growMax": 2000, "selectOnFocus": true });
    var id1563 = new Ext.form.NumberField({ "selectOnFocus": true });
    var content_type1564 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/gfks/HelpTextsByModel/content_type" }) }) });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      field1560.setContextValue('mk',bp['mk']);
      field1560.setContextValue('mt',bp['mt']);
    };
    this.onRender = function(ct, position) {
      content_type1564.on('change',Lino.chooser_handler(field1560,'content_type'));
      Lino.gfks.HelpTextsByModel.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "field", "editable": true, "editor": field1560, "filter": { "type": "string" }, "header": "Field", "sortable": false, "tooltip": "(gfks.HelpTextsByModel.field) ", "width": Lino.chars2width(11) }, { "colIndex": 1, "dataIndex": "verbose_name", "editable": false, "header": "Verbose name", "sortable": false, "tooltip": "(gfks.HelpTextsByModel.verbose_name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "help_text", "editable": true, "editor": help_text1562, "filter": { "type": "string" }, "header": "HelpText", "sortable": false, "tooltip": "(gfks.HelpTextsByModel.help_text) ", "width": Lino.chars2width(61) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id1563, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(gfks.HelpTextsByModel.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "content_type", "editable": true, "editor": content_type1564, "filter": { "type": "string" }, "header": "Model", "renderer": Lino.fk_renderer('content_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(gfks.HelpTextsByModel.content_type) ", "width": Lino.chars2width(21) } ];
    Lino.gfks.HelpTextsByModel.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.HelpTextsByModel.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTextsByModel", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTextsByModel.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTextsByModel", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTextsByModel.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTextsByModel", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTextsByModel.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTextsByModel", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTextsByModel.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTextsByModel", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTextsByModel.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/HelpTextsByModel", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.HelpTextsByModel.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.gfks.HelpTextsByModel.GridPanel(p);
});

// js_render_GridPanel_class outbox.MailsByController
Lino.outbox.MailsByController.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/MailsByController",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/MailsByController','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/MailsByController','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  cell_edit : true,
  title : "Outgoing Mails",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 18,
  ls_store_fields : [ { "name": "sent" }, { "name": "recipients" }, { "name": "subject" }, { "name": "id", "type": "int" }, { "name": "user" }, 'userHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "dateFormat": "d.m.Y", "name": "date", "type": "date" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "body" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 63,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MailsByController.detail;
    this.ls_insert_handler = Lino.outbox.MailsByController.insert;
    var ww = this.containing_window;
    var sent7160 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var recipients_htmlbox7161 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "recipients", "title": "Recipients", "value": "<br/>" });
    var subject7162 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id7163 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var user7164 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "hidden": true, "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/MailsByController/user" }) }) });
    var owner_type7165 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/MailsByController/owner_type" }) }) });
    var owner_id7166 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/MailsByController/owner_id" }) }) });
    var date7167 = new Lino.DateField({ "allowBlank": false, "hidden": true, "selectOnFocus": true });
    var mobile_item_disp7168 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7169 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7170 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7171 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var body7172 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var owner_disp7173 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      recipients_htmlbox7161.refresh();
      owner_id7166.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body7172.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type7165.on('change',Lino.chooser_handler(owner_id7166,'owner_type'));
      Lino.outbox.MailsByController.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "sent", "editable": false, "header": "sent", "sortable": true, "tooltip": "(outbox.MailsByController.sent) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "recipients", "editable": false, "header": "Recipients", "sortable": false, "tooltip": "(outbox.MailsByController.recipients) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "subject", "editable": true, "editor": subject7162, "filter": { "type": "string" }, "header": "Teema", "sortable": true, "tooltip": "(outbox.MailsByController.subject) ", "width": Lino.chars2width(22) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7163, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(outbox.MailsByController.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "user", "editable": true, "editor": user7164, "filter": { "type": "string" }, "header": "Sender", "hidden": true, "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(outbox.MailsByController.user) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type7165, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(outbox.MailsByController.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id7166, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "date", "editable": true, "editor": date7167, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Kuup\u00e4ev", "hidden": true, "sortable": true, "tooltip": "(outbox.MailsByController.date) \n        The official date to be printed on the document.\n        ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 8, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 10, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "body", "editable": true, "editor": body7172, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.body) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(outbox.MailsByController.owner) ", "width": Lino.chars2width(11) } ];
    Lino.outbox.MailsByController.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MailsByController.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.MailsByController.insertPanel = Ext.extend(Lino.outbox.Mails.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/outbox/MailsByController",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MailsByController.detail;
    this.ls_insert_handler = Lino.outbox.MailsByController.insert;
    Lino.outbox.MailsByController.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MailsByController.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.outbox.MailsByController.insertPanel(p);
});
Lino.outbox.MailsByController.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.outbox.MailsByController.detailPanel = Ext.extend(Lino.outbox.Mails.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." }, { "auto_save": true, "iconCls": "x-tbar-email_go", "itemId": "send_mail", "menu_item_text": "Send email", "overflowText": "Send email", "panel_btn_handler": Lino.row_action_handler('send_mail','GET',null), "tooltip": "Sends an outbox.Mail as an email." } ],
  ls_url: "/outbox/MailsByController",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.outbox.MailsByController.detail;
    this.ls_insert_handler = Lino.outbox.MailsByController.insert;
    Lino.outbox.MailsByController.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.MailsByController.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.MailsByController.detailPanel(p);
});
Lino.outbox.MailsByController.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.outbox.Mails.ParamsPanel({});
  return new Lino.outbox.MailsByController.GridPanel(p);
});
Lino.outbox.MailsByController.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.MailsByController.send_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/MailsByController", "GET", pk, "send_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class changes.ChangesByMaster
Lino.changes.ChangesByMaster.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/changes/ChangesByMaster",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/changes/ChangesByMaster','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/changes/ChangesByMaster','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" } ],
  cell_edit : true,
  title : "Changes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "time" }, { "name": "user" }, 'userHidden', { "name": "type" }, 'typeHidden', { "name": "changed_fields" }, { "name": "object" }, { "name": "id", "type": "int" }, { "name": "object_type" }, 'object_typeHidden', { "name": "object_id" }, 'object_idHidden', { "name": "master_type" }, 'master_typeHidden', { "name": "master_id" }, 'master_idHidden', { "name": "diff" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "master" }, { "name": "disabled_actions" } ],
  pk_index : 7,
  ls_grid_configs : [  ],
  content_type : 40,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.changes.ChangesByMaster.detail;
    var ww = this.containing_window;
    var time985 = new Ext.form.DisplayField({ "allowBlank": false, "selectOnFocus": true, "value": "<br>" });
    var user986 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByMaster/user" }) }) });
    var type987 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.changes.ChangeTypes });
    var changed_fields988 = new Ext.form.TextField({ "maxLength": 250, "selectOnFocus": true });
    var object_disp989 = new Ext.form.DisplayField({ "disabled": true });
    var id990 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var object_type991 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByMaster/object_type" }) }) });
    var object_id992 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByMaster/object_id" }) }) });
    var master_type993 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByMaster/master_type" }) }) });
    var master_id994 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/changes/ChangesByMaster/master_id" }) }) });
    var diff995 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var mobile_item_disp996 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp997 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp998 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp999 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var master_disp1000 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
    };
    this.onRender = function(ct, position) {
      object_type991.on('change',Lino.chooser_handler(object_id992,'object_type'));
      master_type993.on('change',Lino.chooser_handler(master_id994,'master_type'));
      Lino.changes.ChangesByMaster.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "time", "editable": true, "editor": time985, "header": "time", "sortable": true, "tooltip": "(changes.ChangesByMaster.time) ", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "user", "editable": true, "editor": user986, "filter": { "type": "string" }, "header": "Kasutaja", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(changes.ChangesByMaster.user) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "type", "editable": true, "editor": type987, "filter": { "type": "string" }, "header": "Change Type", "sortable": false, "tooltip": "(changes.ChangesByMaster.type) ", "width": Lino.chars2width(16) }, { "colIndex": 3, "dataIndex": "changed_fields", "editable": true, "editor": changed_fields988, "filter": { "type": "string" }, "header": "Fields", "sortable": true, "tooltip": "(changes.ChangesByMaster.changed_fields) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "object", "editable": false, "header": "Object", "sortable": false, "tooltip": "(changes.ChangesByMaster.object) The database object which has been modified.", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 5, "dataIndex": "id", "editable": true, "editor": id990, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(changes.ChangesByMaster.id) ", "width": Lino.chars2width(6) }, { "colIndex": 6, "dataIndex": "object_type", "editable": true, "editor": object_type991, "filter": { "type": "string" }, "header": "Object type", "hidden": true, "renderer": Lino.fk_renderer('object_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(changes.ChangesByMaster.object_type) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "object_id", "editable": true, "editor": object_id992, "filter": { "type": "string" }, "header": "object id", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.object_id) ", "width": Lino.chars2width(11) }, { "colIndex": 8, "dataIndex": "master_type", "editable": true, "editor": master_type993, "filter": { "type": "string" }, "header": "Master type", "hidden": true, "renderer": Lino.fk_renderer('master_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(changes.ChangesByMaster.master_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "master_id", "editable": true, "editor": master_id994, "filter": { "type": "string" }, "header": "master id", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.master_id) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "diff", "editable": true, "editor": diff995, "filter": { "type": "string" }, "header": "Changes", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.diff) ", "width": Lino.chars2width(61) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "master", "editable": false, "header": "Master", "hidden": true, "sortable": false, "tooltip": "(changes.ChangesByMaster.master) The database object which acts as \"master\".", "width": Lino.chars2width(11) } ];
    Lino.changes.ChangesByMaster.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.ChangesByMaster.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByMaster", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangesByMaster.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByMaster", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangesByMaster.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByMaster", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangesByMaster.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangesByMaster", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.changes.ChangesByMaster.detailPanel = Ext.extend(Lino.changes.Changes.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/changes/ChangesByMaster",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.changes.ChangesByMaster.detail;
    Lino.changes.ChangesByMaster.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.ChangesByMaster.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.changes.ChangesByMaster.detailPanel(p);
});
Lino.changes.ChangesByMaster.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.changes.Changes.ParamsPanel({});
  return new Lino.changes.ChangesByMaster.GridPanel(p);
});

// js_render_GridPanel_class comments.CommentsByRFC
Lino.comments.CommentsByRFC.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/comments/CommentsByRFC",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/comments/CommentsByRFC','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/comments/CommentsByRFC','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Comments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 22,
  ls_store_fields : [ { "name": "short_text" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "reply_to" }, 'reply_toHidden', { "name": "more_text" }, { "name": "comment_type" }, 'comment_typeHidden', { "name": "created_natural" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 38,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByRFC.detail;
    this.ls_insert_handler = Lino.comments.CommentsByRFC.insert;
    var ww = this.containing_window;
    var short_text7175 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "selectOnFocus": true, "title": "Short text" });
    var created7176 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var user7177 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "store": new Lino.ComplexRemoteComboStore({  }) });
    var id7178 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified7179 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var owner_type7180 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByRFC/owner_type" }) }) });
    var owner_id7181 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByRFC/owner_id" }) }) });
    var reply_to7182 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByRFC/reply_to" }) }) });
    var more_text7183 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "More text" });
    var comment_type7184 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Comment Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/comments/CommentsByRFC/comment_type" }) }) });
    var created_natural_disp7185 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mobile_item_disp7186 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7187 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7188 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7189 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var owner_disp7190 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      short_text7175.refresh();
      owner_id7181.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      more_text7183.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type7180.on('change',Lino.chooser_handler(owner_id7181,'owner_type'));
      Lino.comments.CommentsByRFC.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "short_text", "editable": true, "editor": short_text7175, "filter": { "type": "string" }, "header": "Short text", "sortable": false, "tooltip": "(comments.CommentsByRFC.short_text) A short \"abstract\" of your comment. This should not be more\nthan one paragraph.", "width": Lino.chars2width(61) }, { "colIndex": 1, "dataIndex": "created", "editable": false, "header": "Loodud", "sortable": true, "tooltip": "(comments.CommentsByRFC.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 2, "dataIndex": "user", "editable": false, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(comments.CommentsByRFC.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7178, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(comments.CommentsByRFC.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(comments.CommentsByRFC.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type7180, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(comments.CommentsByRFC.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id7181, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 7, "dataIndex": "reply_to", "editable": true, "editor": reply_to7182, "filter": { "type": "string" }, "header": "Reply to", "hidden": true, "renderer": Lino.fk_renderer('reply_toHidden','Lino.comments.Comments.detail'), "sortable": false, "tooltip": "(comments.CommentsByRFC.reply_to) ", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "more_text", "editable": true, "editor": more_text7183, "filter": { "type": "string" }, "header": "More text", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.more_text) ", "width": Lino.chars2width(61) }, { "colIndex": 9, "dataIndex": "comment_type", "editable": true, "editor": comment_type7184, "filter": { "type": "string" }, "header": "Comment Type", "hidden": true, "renderer": Lino.fk_renderer('comment_typeHidden','Lino.comments.CommentTypes.detail'), "sortable": false, "tooltip": "(comments.CommentsByRFC.comment_type) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(comments.CommentsByRFC.owner) ", "width": Lino.chars2width(11) } ];
    Lino.comments.CommentsByRFC.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByRFC.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByRFC.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByRFC.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentsByRFC.insertPanel = Ext.extend(Lino.comments.Comments.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/comments/CommentsByRFC",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByRFC.detail;
    this.ls_insert_handler = Lino.comments.CommentsByRFC.insert;
    Lino.comments.CommentsByRFC.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByRFC.insert = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(10), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.comments.CommentsByRFC.insertPanel(p);
});
Lino.comments.CommentsByRFC.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByRFC.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByRFC.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.comments.CommentsByRFC.detailPanel = Ext.extend(Lino.comments.Comments.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/comments/CommentsByRFC",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.comments.CommentsByRFC.detail;
    this.ls_insert_handler = Lino.comments.CommentsByRFC.insert;
    Lino.comments.CommentsByRFC.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.comments.CommentsByRFC.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.comments.CommentsByRFC.detailPanel(p);
});
Lino.comments.CommentsByRFC.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.comments.CommentsByRFC.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.comments.Comments.ParamsPanel({});
  return new Lino.comments.CommentsByRFC.GridPanel(p);
});
Lino.comments.CommentsByRFC.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/comments/CommentsByRFC", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class outbox.AttachmentsByController
Lino.outbox.AttachmentsByController.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/outbox/AttachmentsByController",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/AttachmentsByController','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/AttachmentsByController','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Attachments",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 13,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "mail" }, 'mailHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 65,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var id7192 = new Ext.form.NumberField({ "selectOnFocus": true });
    var owner_type7193 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/AttachmentsByController/owner_type" }) }) });
    var owner_id7194 = new Lino.RemoteComboFieldElement({ "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/AttachmentsByController/owner_id" }) }) });
    var mail7195 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni Outgoing Mail...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/outbox/AttachmentsByController/mail" }) }) });
    var mobile_item_disp7196 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7197 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7198 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7199 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var owner_disp7200 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      owner_id7194.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      owner_type7193.on('change',Lino.chooser_handler(owner_id7194,'owner_type'));
      Lino.outbox.AttachmentsByController.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id7192, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(outbox.AttachmentsByController.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "owner_type", "editable": true, "editor": owner_type7193, "filter": { "type": "string" }, "header": "Controlled by (type)", "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(outbox.AttachmentsByController.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "owner_id", "editable": true, "editor": owner_id7194, "filter": { "type": "string" }, "header": "Controlled by (object)", "sortable": false, "tooltip": "(outbox.AttachmentsByController.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "mail", "editable": true, "editor": mail7195, "filter": { "type": "string" }, "header": "Outgoing Mail", "renderer": Lino.fk_renderer('mailHidden','Lino.outbox.Mails.detail'), "sortable": false, "tooltip": "(outbox.AttachmentsByController.mail) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByController.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByController.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByController.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(outbox.AttachmentsByController.owner) ", "width": Lino.chars2width(11) } ];
    Lino.outbox.AttachmentsByController.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.AttachmentsByController.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByController", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByController.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByController", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByController.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByController", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByController.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByController", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByController.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByController", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByController.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/AttachmentsByController", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.AttachmentsByController.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.AttachmentsByController.GridPanel(p);
});

// js_render_GridPanel_class excerpts.ExcerptsByOwner
Lino.excerpts.ExcerptsByOwner.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/excerpts/ExcerptsByOwner",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/ExcerptsByOwner','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/ExcerptsByOwner','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  cell_edit : true,
  title : "Tehtud v\u00e4ljav\u00f5ted",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 28,
  ls_store_fields : [ { "name": "build_time" }, { "name": "excerpt_type" }, 'excerpt_typeHidden', { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "build_method" }, 'build_methodHidden', { "name": "company" }, 'companyHidden', { "name": "contact_person" }, 'contact_personHidden', { "name": "contact_role" }, 'contact_roleHidden', { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "language" }, 'languageHidden', { "name": "body_template_content" }, { "name": "preview" }, { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 5,
  ls_grid_configs : [  ],
  content_type : 37,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptsByOwner.detail;
    var ww = this.containing_window;
    var build_time7202 = new Ext.form.DisplayField({ "disabled": true, "value": "<br>" });
    var excerpt_type7203 = new Lino.RemoteComboFieldElement({ "allowBlank": false, "emptyText": "Vali m\u00f5ni V\u00e4ljav\u00f5teliik...", "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/excerpt_type" }) }) });
    var user7204 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/user" }) }) });
    var id7205 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var build_method7206 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company7207 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organisatsioon...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/company" }) }) });
    var contact_person7208 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Inimene...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/contact_person" }) }) });
    var contact_role7209 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Function...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/contact_role" }) }) });
    var owner_type7210 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/owner_type" }) }) });
    var owner_id7211 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/excerpts/ExcerptsByOwner/owner_id" }) }) });
    var language7212 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var body_template_content7213 = new Lino.RichTextPanel({ "containing_panel": this, "disabled": true, "hidden": true, "title": "Body template" });
    var preview_htmlbox7214 = new Lino.HtmlBoxPanel({ "always_enabled": true, "bodyStyle": "overflow-x:hidden;", "containing_panel": this, "hidden": true, "items": new Ext.BoxComponent({autoScroll:true}), "layout": "fit", "name": "preview", "title": "Eelvaade", "value": "<br/>" });
    var mobile_item_disp7215 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp7216 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp7217 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp7218 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var owner_disp7219 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      excerpt_type7203.setContextValue('mk',bp['mk']);
      excerpt_type7203.setContextValue('mt',bp['mt']);
      contact_person7208.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id7211.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body_template_content7213.refresh();
      preview_htmlbox7214.refresh();
    };
    this.onRender = function(ct, position) {
      owner_disp7219.on('change',Lino.chooser_handler(excerpt_type7203,'owner'));
      company7207.on('change',Lino.chooser_handler(contact_person7208,'company'));
      owner_type7210.on('change',Lino.chooser_handler(owner_id7211,'owner_type'));
      Lino.excerpts.ExcerptsByOwner.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "build_time", "editable": false, "header": "build time", "sortable": true, "tooltip": "(excerpts.ExcerptsByOwner.build_time) Timestamp of the built target file. Contains None\nif no build hasn't been called yet.", "width": Lino.chars2width(17) }, { "colIndex": 1, "dataIndex": "excerpt_type", "editable": true, "editor": excerpt_type7203, "filter": { "type": "string" }, "header": "V\u00e4ljav\u00f5teliik", "renderer": Lino.fk_renderer('excerpt_typeHidden','Lino.excerpts.ExcerptTypes.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.excerpt_type) The type of this excerpt (ForeignKey to ExcerptType).", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user7204, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id7205, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(excerpts.ExcerptsByOwner.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "build_method", "editable": true, "editor": build_method7206, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 5, "dataIndex": "company", "editable": true, "editor": company7207, "filter": { "type": "string" }, "header": "Saaja (Firma)", "hidden": true, "renderer": Lino.fk_renderer('companyHidden','Lino.contacts.Companies.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.company) The optional company of the recipient of this\nexcerpt.  See ContactRelated.company.", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "contact_person", "editable": true, "editor": contact_person7208, "filter": { "type": "string" }, "header": "Saaja (Isik)", "hidden": true, "renderer": Lino.fk_renderer('contact_personHidden','Lino.contacts.Persons.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.contact_person) The optional contact person of the recipient of this\nexcerpt.  See ContactRelated.contact_person.", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "contact_role", "editable": true, "editor": contact_role7209, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 8, "dataIndex": "owner_type", "editable": true, "editor": owner_type7210, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "owner_id", "editable": true, "editor": owner_id7211, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 10, "dataIndex": "language", "editable": true, "editor": language7212, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.language) The language used for printing this excerpt.", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "body_template_content", "editable": false, "header": "Body template", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.body_template_content) ", "width": Lino.chars2width(61) }, { "colIndex": 12, "dataIndex": "preview", "editable": false, "header": "Eelvaade", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.preview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 15, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 16, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 17, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(excerpts.ExcerptsByOwner.owner) The object being printed by this excerpt.\nSee Controllable.owner.", "width": Lino.chars2width(11) } ];
    Lino.excerpts.ExcerptsByOwner.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptsByOwner.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.excerpts.ExcerptsByOwner.detailPanel = Ext.extend(Lino.excerpts.Excerpts.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "itemId": "duplicate", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Duplicate the selected row.") }, "menu_item_text": "\u2687", "overflowText": "\u2687", "panel_btn_handler": Lino.row_action_handler('duplicate','GET',null), "text": " <font size=\"4\">\u2687</font>" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" }, { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','POST',null), "tooltip": "A print action which uses a cache for the generated printable\ndocument and builds is only when it doesn't yet exist." }, { "auto_save": true, "iconCls": "x-tbar-printer_delete", "itemId": "do_clear_cache", "menu_item_text": "Clear cache", "overflowText": "Clear cache", "panel_btn_handler": Lino.row_action_handler('do_clear_cache','GET',null), "tooltip": "Defines the Clear cache button on a Printable record." }, { "auto_save": true, "iconCls": "x-tbar-script_add", "itemId": "create_postings", "menu_item_text": "Create posting", "overflowText": "Create posting", "panel_btn_handler": Lino.row_action_handler('create_postings','GET',null), "tooltip": "Create classical mail postings from this" }, { "auto_save": true, "iconCls": "x-tbar-email_add", "itemId": "create_mail", "menu_item_text": "Create email", "overflowText": "Create email", "panel_btn_handler": Lino.row_action_handler('create_mail','GET',null), "tooltip": "Create an email from this" } ],
  ls_url: "/excerpts/ExcerptsByOwner",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.excerpts.ExcerptsByOwner.detail;
    Lino.excerpts.ExcerptsByOwner.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.ExcerptsByOwner.detail = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(80) }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.ExcerptsByOwner.detailPanel(p);
});
Lino.excerpts.ExcerptsByOwner.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.excerpts.Excerpts.ParamsPanel({});
  return new Lino.excerpts.ExcerptsByOwner.GridPanel(p);
});
Lino.excerpts.ExcerptsByOwner.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.ExcerptsByOwner.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/ExcerptsByOwner", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class blogs.EntriesByController
Lino.blogs.EntriesByController.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/blogs/EntriesByController",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByController','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByController','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  cell_edit : true,
  title : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 21,
  ls_store_fields : [ { "dateFormat": "d.m.Y", "name": "pub_date", "type": "date" }, { "name": "title" }, { "name": "user" }, 'userHidden', { "name": "id", "type": "int" }, { "name": "owner_type" }, 'owner_typeHidden', { "name": "owner_id" }, 'owner_idHidden', { "name": "body" }, { "name": "pub_time" }, { "name": "entry_type" }, 'entry_typeHidden', { "name": "language" }, 'languageHidden', { "name": "mobile_item" }, { "name": "description_column" }, { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "owner" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 4,
  ls_grid_configs : [  ],
  content_type : 57,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntriesByController.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByController.insert;
    var ww = this.containing_window;
    var pub_date3305 = new Lino.DateField({ "selectOnFocus": true });
    var title3306 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3307 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Kasutaja...", "pageSize": 20, "preferred_width": 15, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByController/user" }) }) });
    var id3308 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type3309 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni sisut\u00fc\u00fcp...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByController/owner_type" }) }) });
    var owner_id3310 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByController/owner_id" }) }) });
    var body3311 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var pub_time3312 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var entry_type3313 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Blog Entry Type...", "hidden": true, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/blogs/EntriesByController/entry_type" }) }) });
    var language3314 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var mobile_item_disp3315 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3316 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3317 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3318 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var owner_disp3319 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      owner_id3310.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body3311.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type3309.on('change',Lino.chooser_handler(owner_id3310,'owner_type'));
      Lino.blogs.EntriesByController.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "pub_date", "editable": true, "editor": pub_date3305, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Publication date", "sortable": true, "tooltip": "(blogs.EntriesByController.pub_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 1, "dataIndex": "title", "editable": true, "editor": title3306, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.EntriesByController.title) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3307, "filter": { "type": "string" }, "header": "Autor", "renderer": Lino.fk_renderer('userHidden','Lino.users.Users.detail'), "sortable": false, "tooltip": "(blogs.EntriesByController.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id3308, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(blogs.EntriesByController.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "owner_type", "editable": true, "editor": owner_type3309, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "renderer": Lino.fk_renderer('owner_typeHidden','Lino.gfks.ContentTypes.detail'), "sortable": false, "tooltip": "(blogs.EntriesByController.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id3310, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 6, "dataIndex": "body", "editable": true, "editor": body3311, "filter": { "type": "string" }, "header": "Body", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.body) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "pub_time", "editable": true, "editor": pub_time3312, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.EntriesByController.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "entry_type", "editable": true, "editor": entry_type3313, "filter": { "type": "string" }, "header": "Blog Entry Type", "hidden": true, "renderer": Lino.fk_renderer('entry_typeHidden','Lino.blogs.EntryTypes.detail'), "sortable": false, "tooltip": "(blogs.EntriesByController.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "language", "editable": true, "editor": language3314, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.language) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "mobile_item", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.mobile_item) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "overview", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 14, "dataIndex": "owner", "editable": false, "header": "Controlled by", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.owner) ", "width": Lino.chars2width(11) } ];
    Lino.blogs.EntriesByController.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntriesByController.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByController.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByController.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.EntriesByController.insertPanel = Ext.extend(Lino.blogs.Entries.InsertFormPanel,{
  empty_title: "Uus",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_insert",
  ls_bbar_actions: [ { "auto_save": false, "itemId": "submit_insert", "listeners": { "render": Lino.quicktip_renderer('a2btn',"Create the record and open a detail window on it") }, "menu_item_text": "Loo", "overflowText": "Loo", "panel_btn_handler": function(panel){panel.save()}, "text": "Loo" } ],
  ls_url: "/blogs/EntriesByController",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntriesByController.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByController.insert;
    Lino.blogs.EntriesByController.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntriesByController.insert = new Lino.WindowAction({ "autoHeight": true, "draggable": true, "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.blogs.EntriesByController.insertPanel(p);
});
Lino.blogs.EntriesByController.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByController.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByController.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.blogs.EntriesByController.detailPanel = Ext.extend(Lino.blogs.Entries.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": false, "iconCls": "x-tbar-disk", "itemId": "submit_detail", "menu_item_text": "Salvesta", "overflowText": "Salvesta", "panel_btn_handler": function(panel){panel.save()}, "tooltip": "Save changes in this form" }, { "auto_save": true, "iconCls": "x-tbar-add", "itemId": "insert", "keycode": 44, "menu_item_text": "Uus", "overflowText": "Uus", "panel_btn_handler": Lino.show_insert, "tooltip": "Insert a new record" }, { "auto_save": false, "iconCls": "x-tbar-delete", "itemId": "delete_selected", "keycode": 46, "menu_item_text": "Kustuta", "overflowText": "Kustuta", "panel_btn_handler": Lino.row_action_handler('delete_selected','GET',null), "tooltip": "Delete this record" } ],
  ls_url: "/blogs/EntriesByController",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.blogs.EntriesByController.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByController.insert;
    Lino.blogs.EntriesByController.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.blogs.EntriesByController.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.blogs.EntriesByController.detailPanel(p);
});
Lino.blogs.EntriesByController.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByController.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.blogs.Entries.ParamsPanel({});
  return new Lino.blogs.EntriesByController.GridPanel(p);
});
Lino.blogs.EntriesByController.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class about.Models
Lino.about.Models.GridPanel = Ext.extend(Lino.GridPanel,{
  ls_url : "/about/Models",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/about/Models','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/about/Models','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" }, { "auto_save": true, "iconCls": "x-tbar-application_form", "itemId": "detail", "menu_item_text": "Detail", "overflowText": "Detail", "panel_btn_handler": Lino.show_detail, "tooltip": "Open a detail window on this record" } ],
  cell_edit : true,
  title : "Models",
  page_length : 20,
  params_panel_hidden : true,
  gc_name : 0,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "app" }, { "name": "name" }, { "name": "fields" }, { "name": "tables" }, { "name": "rows" }, { "name": "detail_action" }, { "name": "disabled_actions" } ],
  stripeRows : true,
  ls_grid_configs : [  ],
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  initComponent : function() {
    this.ls_detail_handler = Lino.about.Models.detail;
    var ww = this.containing_window;
    var app_disp7221 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var name_disp7222 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var fields_disp7223 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var tables_disp7224 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var rows7225 = new Ext.form.NumberField({ "disabled": true });
    var detail_action_disp7226 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "app", "editable": false, "header": "app_label", "sortable": false, "tooltip": "(about.Models.app) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(about.Models.name) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "fields", "editable": false, "header": "Fields", "sortable": false, "tooltip": "(about.Models.fields) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "tables", "editable": false, "header": "Tables", "sortable": false, "tooltip": "(about.Models.tables) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 4, "dataIndex": "rows", "editable": false, "format": "0", "header": "Rows", "sortable": false, "tooltip": "(about.Models.rows) ", "width": Lino.chars2width(6) }, { "colIndex": 5, "dataIndex": "detail_action", "editable": false, "header": "Detail Action", "sortable": false, "tooltip": "(about.Models.detail_action) ", "width": Lino.chars2width(31) } ];
    Lino.about.Models.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.about.Models.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/Models", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.Models.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/Models", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.about.Models.detailPanel = Ext.extend(Lino.about.Models.DetailFormPanel,{
  empty_title: "Detail",
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/about/Models",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.about.Models.detail;
    Lino.about.Models.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.about.Models.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.about.Models.detailPanel(p);
});
Lino.about.Models.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.about.Models.GridPanel(p);
});

// js_render_GridPanel_class about.FieldsByModel
Lino.about.FieldsByModel.GridPanel = Ext.extend(Lino.GridPanel,{
  ls_url : "/about/FieldsByModel",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/about/FieldsByModel','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/about/FieldsByModel','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Fields",
  page_length : 20,
  params_panel_hidden : true,
  gc_name : 0,
  disable_editing : true,
  disabled_actions_index : 3,
  ls_store_fields : [ { "name": "name" }, { "name": "verbose_name" }, { "name": "help_text_column" }, { "name": "disabled_actions" } ],
  stripeRows : true,
  ls_grid_configs : [  ],
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  initComponent : function() {
    var ww = this.containing_window;
    var name_disp2852 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var verbose_name_disp2853 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var help_text_column_disp2854 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(about.FieldsByModel.name) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "verbose_name", "editable": false, "header": "verbose name", "sortable": false, "tooltip": "(about.FieldsByModel.verbose_name) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "help_text_column", "editable": false, "header": "help text", "sortable": false, "tooltip": "(about.FieldsByModel.help_text_column) ", "width": Lino.chars2width(31) } ];
    Lino.about.FieldsByModel.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.about.FieldsByModel.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/FieldsByModel", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.FieldsByModel.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/FieldsByModel", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.FieldsByModel.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.about.FieldsByModel.GridPanel(p);
});

// js_render_GridPanel_class about.Inspector
Lino.about.Inspector.GridPanel = Ext.extend(Lino.GridPanel,{
  ls_url : "/about/Inspector",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/about/Inspector','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/about/Inspector','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Inspector",
  page_length : 20,
  params_panel_hidden : true,
  gc_name : 0,
  disable_editing : true,
  disabled_actions_index : 3,
  ls_store_fields : [ { "name": "i_name" }, { "name": "i_type" }, { "name": "i_value" }, { "name": "disabled_actions" } ],
  stripeRows : true,
  ls_grid_configs : [  ],
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  initComponent : function() {
    var ww = this.containing_window;
    var i_name_disp7228 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var i_type_disp7229 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var i_value_disp7230 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "i_name", "editable": false, "header": "Nimi", "sortable": false, "tooltip": "(about.Inspector.i_name) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "i_type", "editable": false, "header": "Type", "sortable": false, "tooltip": "(about.Inspector.i_type) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "i_value", "editable": false, "header": "Value", "sortable": false, "tooltip": "(about.Inspector.i_value) ", "width": Lino.chars2width(31) } ];
    Lino.about.Inspector.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.about.Inspector.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/Inspector", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.Inspector.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/Inspector", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.Inspector.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.about.Inspector.ParamsPanel({});
  return new Lino.about.Inspector.GridPanel(p);
});

// js_render_GridPanel_class about.SourceFiles
Lino.about.SourceFiles.GridPanel = Ext.extend(Lino.GridPanel,{
  ls_url : "/about/SourceFiles",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/about/SourceFiles','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/about/SourceFiles','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Source files",
  page_length : 20,
  params_panel_hidden : true,
  gc_name : 0,
  disable_editing : true,
  disabled_actions_index : 3,
  ls_store_fields : [ { "name": "module_name" }, { "name": "code_lines", "type": "int", "useNull": true }, { "name": "doc_lines", "type": "int", "useNull": true }, { "name": "disabled_actions" } ],
  stripeRows : true,
  ls_grid_configs : [  ],
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  initComponent : function() {
    var ww = this.containing_window;
    var module_name7232 = new Ext.form.TextField({ "disabled": true, "maxLength": null });
    var code_lines7233 = new Ext.form.NumberField({ "disabled": true });
    var doc_lines7234 = new Ext.form.NumberField({ "disabled": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "module_name", "editable": false, "header": "module name", "sortable": false, "tooltip": "(about.SourceFiles.module_name) ", "width": Lino.chars2width(5) }, { "align": "right", "colIndex": 1, "dataIndex": "code_lines", "editable": false, "format": "0", "header": "Code", "sortable": false, "tooltip": "(about.SourceFiles.code_lines) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 2, "dataIndex": "doc_lines", "editable": false, "format": "0", "header": "doc", "sortable": false, "tooltip": "(about.SourceFiles.doc_lines) ", "width": Lino.chars2width(6) } ];
    Lino.about.SourceFiles.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.about.SourceFiles.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/SourceFiles", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.SourceFiles.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/about/SourceFiles", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.about.SourceFiles.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.about.SourceFiles.GridPanel(p);
});

// js_render_GridPanel_class gfks.BrokenGFKs
Lino.gfks.BrokenGFKs.GridPanel = Ext.extend(Lino.GridPanel,{
  ls_url : "/gfks/BrokenGFKs",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/gfks/BrokenGFKs','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/gfks/BrokenGFKs','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Broken GFKs",
  page_length : 20,
  params_panel_hidden : true,
  gc_name : 0,
  disable_editing : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "database_model" }, { "name": "database_object" }, { "name": "message" }, { "name": "todo" }, { "name": "disabled_actions" } ],
  stripeRows : true,
  ls_grid_configs : [  ],
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  initComponent : function() {
    var ww = this.containing_window;
    var database_model_disp7236 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var database_object_disp7237 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var message_disp7238 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var todo_disp7239 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "database_model", "editable": false, "header": "Database model", "sortable": false, "tooltip": "(gfks.BrokenGFKs.database_model) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "database_object", "editable": false, "header": "Database object", "sortable": false, "tooltip": "(gfks.BrokenGFKs.database_object) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "message", "editable": false, "header": "Message", "sortable": false, "tooltip": "(gfks.BrokenGFKs.message) ", "width": Lino.chars2width(31) }, { "colIndex": 3, "dataIndex": "todo", "editable": false, "header": "Action", "sortable": false, "tooltip": "(gfks.BrokenGFKs.todo) ", "width": Lino.chars2width(31) } ];
    Lino.gfks.BrokenGFKs.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.BrokenGFKs.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/BrokenGFKs", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.BrokenGFKs.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/BrokenGFKs", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.BrokenGFKs.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.gfks.BrokenGFKs.GridPanel(p);
});

// js_render_GridPanel_class gfks.BrokenGFKsByModel
Lino.gfks.BrokenGFKsByModel.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/gfks/BrokenGFKsByModel",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/gfks/BrokenGFKsByModel','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/gfks/BrokenGFKsByModel','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Broken GFKs",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 4,
  ls_store_fields : [ { "name": "database_object" }, { "name": "message" }, { "name": "todo" }, { "name": "id", "type": "int" }, { "name": "disabled_actions" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 3,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var database_object_disp1567 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var message_disp1568 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var todo_disp1569 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "database_object", "editable": false, "header": "Database object", "sortable": false, "tooltip": "(gfks.BrokenGFKsByModel.database_object) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "message", "editable": false, "header": "Message", "sortable": false, "tooltip": "(gfks.BrokenGFKsByModel.message) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "todo", "editable": false, "header": "Action", "sortable": false, "tooltip": "(gfks.BrokenGFKsByModel.todo) ", "width": Lino.chars2width(31) } ];
    Lino.gfks.BrokenGFKsByModel.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.gfks.BrokenGFKsByModel.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/BrokenGFKsByModel", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.BrokenGFKsByModel.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/gfks/BrokenGFKsByModel", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.gfks.BrokenGFKsByModel.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.gfks.BrokenGFKsByModel.GridPanel(p);
});

Lino.about.About.showPanel = Ext.extend(Lino.about.About.DetailFormPanel,{
  empty_title: "About",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/about/About",
  initComponent : function() {
    this.ls_detail_handler = Lino.about.About.show;
    Lino.about.About.showPanel.superclass.initComponent.call(this);
  }
});

Lino.about.About.show = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.about.About.showPanel(p);
});

Lino.about.About.showPanel = Ext.extend(Lino.about.About.DetailFormPanel,{
  empty_title: "About",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [  ],
  ls_url: "/about/About",
  initComponent : function() {
    this.ls_detail_handler = Lino.about.About.show;
    Lino.about.About.showPanel.superclass.initComponent.call(this);
  }
});

Lino.about.About.show = new Lino.WindowAction({ "draggable": true, "height": Lino.rows2height(20), "maximizable": true, "maximized": false, "modal": true, "width": Lino.chars2width(60) }, function(){
  var p = { "hide_top_toolbar": true, "is_main_window": true };
  return new Lino.about.About.showPanel(p);
});
Lino.extensible.CalendarPanel.grid = new Lino.WindowAction({  }, function(){
  return Lino.CalendarApp().get_main_panel();
});

Lino.courses.StatusReport.showPanel = Ext.extend(Lino.courses.StatusReport.DetailFormPanel,{
  empty_title: "\u00dcrituste \u00fclevaade",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." } ],
  ls_url: "/courses/StatusReport",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.StatusReport.show;
    Lino.courses.StatusReport.showPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.StatusReport.show = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.StatusReport.showPanel(p);
});

Lino.courses.StatusReport.showPanel = Ext.extend(Lino.courses.StatusReport.DetailFormPanel,{
  empty_title: "\u00dcrituste \u00fclevaade",
  hide_navigator: true,
  params_panel_hidden: true,
  save_action_name: "submit_detail",
  ls_bbar_actions: [ { "auto_save": true, "iconCls": "x-tbar-printer", "itemId": "do_print", "menu_item_text": "Tr\u00fcki", "overflowText": "Tr\u00fcki", "panel_btn_handler": Lino.row_action_handler('do_print','GET',null), "tooltip": "Print using a hard-coded template and without cache." } ],
  ls_url: "/courses/StatusReport",
  initComponent : function() {
    this.ls_detail_handler = Lino.courses.StatusReport.show;
    Lino.courses.StatusReport.showPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.StatusReport.show = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.StatusReport.showPanel(p);
});
Lino.courses.StatusReport.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/StatusReport", "GET", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

// js_render_GridPanel_class notify.MailModes
Lino.notify.MailModes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/notify/MailModes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/notify/MailModes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/notify/MailModes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Email notification modes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7241 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7242 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7243 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7244 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7245 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(notify.MailModes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(notify.MailModes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(notify.MailModes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(notify.MailModes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(notify.MailModes.type) ", "width": Lino.chars2width(31) } ];
    Lino.notify.MailModes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.notify.MailModes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MailModes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MailModes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MailModes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MailModes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.notify.MailModes.GridPanel(p);
});

// js_render_GridPanel_class changes.ChangeTypes
Lino.changes.ChangeTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/changes/ChangeTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/changes/ChangeTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/changes/ChangeTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Change Types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7247 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7248 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7249 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7250 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7251 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(changes.ChangeTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(changes.ChangeTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(changes.ChangeTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(changes.ChangeTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(changes.ChangeTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.changes.ChangeTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.changes.ChangeTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangeTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangeTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/changes/ChangeTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.changes.ChangeTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.changes.ChangeTypes.GridPanel(p);
});

// js_render_GridPanel_class cal.DurationUnits
Lino.cal.DurationUnits.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/DurationUnits",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/DurationUnits','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/DurationUnits','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "DurationUnits",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7253 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7254 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7255 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7256 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7257 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.DurationUnits.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.DurationUnits.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.DurationUnits.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(cal.DurationUnits.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(cal.DurationUnits.type) ", "width": Lino.chars2width(31) } ];
    Lino.cal.DurationUnits.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.DurationUnits.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/DurationUnits", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.DurationUnits.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/DurationUnits", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.DurationUnits.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.DurationUnits.GridPanel(p);
});

// js_render_GridPanel_class uploads.UploadAreas
Lino.uploads.UploadAreas.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/uploads/UploadAreas",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadAreas','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/UploadAreas','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Upload Areas",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7259 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7260 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7261 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7262 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7263 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(uploads.UploadAreas.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(uploads.UploadAreas.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(uploads.UploadAreas.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadAreas.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(uploads.UploadAreas.type) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.UploadAreas.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.UploadAreas.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadAreas", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadAreas.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/UploadAreas", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.UploadAreas.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.UploadAreas.GridPanel(p);
});

// js_render_GridPanel_class cal.TaskStates
Lino.cal.TaskStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/TaskStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/TaskStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/TaskStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Task states",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "button_text" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7265 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7266 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7267 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7268 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7269 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var button_text7270 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": null });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.TaskStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.TaskStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.TaskStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(cal.TaskStates.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(cal.TaskStates.type) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "button_text", "editable": false, "header": "Symbol", "hidden": true, "sortable": false, "tooltip": "(cal.TaskStates.button_text) ", "width": Lino.chars2width(5) } ];
    Lino.cal.TaskStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.TaskStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TaskStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TaskStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/TaskStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.TaskStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.TaskStates.GridPanel(p);
});

// js_render_GridPanel_class addresses.DataSources
Lino.addresses.DataSources.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/addresses/DataSources",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/addresses/DataSources','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/addresses/DataSources','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Data sources",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7272 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7273 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7274 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7275 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7276 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(addresses.DataSources.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(addresses.DataSources.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(addresses.DataSources.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(addresses.DataSources.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(addresses.DataSources.type) ", "width": Lino.chars2width(31) } ];
    Lino.addresses.DataSources.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.DataSources.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/DataSources", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.DataSources.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/DataSources", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.DataSources.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.addresses.DataSources.GridPanel(p);
});

// js_render_GridPanel_class cal.Weekdays
Lino.cal.Weekdays.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/Weekdays",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Weekdays','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Weekdays','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Weekdays",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7278 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7279 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7280 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7281 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7282 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.Weekdays.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.Weekdays.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.Weekdays.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(cal.Weekdays.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(cal.Weekdays.type) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Weekdays.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Weekdays.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Weekdays", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Weekdays.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Weekdays", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Weekdays.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Weekdays.GridPanel(p);
});

// js_render_GridPanel_class outbox.RecipientTypes
Lino.outbox.RecipientTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/outbox/RecipientTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/outbox/RecipientTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/outbox/RecipientTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "RecipientTypes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7284 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7285 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7286 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7287 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7288 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(outbox.RecipientTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(outbox.RecipientTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(outbox.RecipientTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(outbox.RecipientTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(outbox.RecipientTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.outbox.RecipientTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.outbox.RecipientTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/outbox/RecipientTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.outbox.RecipientTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.outbox.RecipientTypes.GridPanel(p);
});

// js_render_GridPanel_class excerpts.Shortcuts
Lino.excerpts.Shortcuts.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/excerpts/Shortcuts",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/excerpts/Shortcuts','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/excerpts/Shortcuts','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Excerpt shortcuts",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7290 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7291 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7292 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7293 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7294 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(excerpts.Shortcuts.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(excerpts.Shortcuts.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(excerpts.Shortcuts.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(excerpts.Shortcuts.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(excerpts.Shortcuts.type) ", "width": Lino.chars2width(31) } ];
    Lino.excerpts.Shortcuts.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.excerpts.Shortcuts.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Shortcuts", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Shortcuts.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/excerpts/Shortcuts", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.excerpts.Shortcuts.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.excerpts.Shortcuts.GridPanel(p);
});

// js_render_GridPanel_class system.PeriodEvents
Lino.system.PeriodEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/system/PeriodEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/system/PeriodEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/system/PeriodEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Observed events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7296 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7297 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7298 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7299 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7300 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(system.PeriodEvents.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(system.PeriodEvents.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(system.PeriodEvents.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(system.PeriodEvents.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(system.PeriodEvents.type) ", "width": Lino.chars2width(31) } ];
    Lino.system.PeriodEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.system.PeriodEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/PeriodEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.PeriodEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/PeriodEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.PeriodEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.system.PeriodEvents.GridPanel(p);
});

// js_render_GridPanel_class clocking.ReportingTypes
Lino.clocking.ReportingTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/clocking/ReportingTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/clocking/ReportingTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/clocking/ReportingTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Reporting types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7302 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7303 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7304 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7305 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7306 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(clocking.ReportingTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(clocking.ReportingTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(clocking.ReportingTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportingTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(clocking.ReportingTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.clocking.ReportingTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.clocking.ReportingTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportingTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportingTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/ReportingTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.ReportingTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.clocking.ReportingTypes.GridPanel(p);
});

// js_render_GridPanel_class notify.MessageTypes
Lino.notify.MessageTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/notify/MessageTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/notify/MessageTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/notify/MessageTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Message Types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7308 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7309 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7310 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7311 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7312 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(notify.MessageTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(notify.MessageTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(notify.MessageTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(notify.MessageTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(notify.MessageTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.notify.MessageTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.notify.MessageTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MessageTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MessageTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/notify/MessageTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.notify.MessageTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.notify.MessageTypes.GridPanel(p);
});

// js_render_GridPanel_class tickets.LinkTypes
Lino.tickets.LinkTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/tickets/LinkTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/LinkTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/LinkTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Dependency types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7314 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7315 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7316 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7317 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7318 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(tickets.LinkTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(tickets.LinkTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(tickets.LinkTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(tickets.LinkTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(tickets.LinkTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.LinkTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.LinkTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinkTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinkTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/LinkTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.LinkTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.LinkTypes.GridPanel(p);
});

// js_render_GridPanel_class cal.Recurrencies
Lino.cal.Recurrencies.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/Recurrencies",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/Recurrencies','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/Recurrencies','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Recurrencies",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7320 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7321 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7322 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7323 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7324 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.Recurrencies.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.Recurrencies.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.Recurrencies.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(cal.Recurrencies.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(cal.Recurrencies.type) ", "width": Lino.chars2width(31) } ];
    Lino.cal.Recurrencies.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.Recurrencies.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Recurrencies", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Recurrencies.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Recurrencies", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Recurrencies.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.Recurrencies.GridPanel(p);
});

// js_render_GridPanel_class system.Genders
Lino.system.Genders.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/system/Genders",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/system/Genders','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/system/Genders','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Genders",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7326 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7327 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7328 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7329 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7330 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(system.Genders.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(system.Genders.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(system.Genders.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(system.Genders.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(system.Genders.type) ", "width": Lino.chars2width(31) } ];
    Lino.system.Genders.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.system.Genders.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/Genders", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.Genders.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/Genders", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.Genders.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.system.Genders.GridPanel(p);
});

// js_render_GridPanel_class uploads.Shortcuts
Lino.uploads.Shortcuts.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/uploads/Shortcuts",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/uploads/Shortcuts','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/uploads/Shortcuts','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Upload shortcuts",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7332 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7333 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7334 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7335 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7336 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(uploads.Shortcuts.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(uploads.Shortcuts.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(uploads.Shortcuts.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(uploads.Shortcuts.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(uploads.Shortcuts.type) ", "width": Lino.chars2width(31) } ];
    Lino.uploads.Shortcuts.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.uploads.Shortcuts.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Shortcuts", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Shortcuts.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/uploads/Shortcuts", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.uploads.Shortcuts.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.uploads.Shortcuts.GridPanel(p);
});

// js_render_GridPanel_class courses.EnrolmentStates
Lino.courses.EnrolmentStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/courses/EnrolmentStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/EnrolmentStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/EnrolmentStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Enrolment states",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 9,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "uses_a_place", "type": "boolean" }, { "name": "invoiceable", "type": "boolean" }, { "name": "type" }, { "name": "button_text" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7338 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7339 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7340 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7341 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var uses_a_place_disp7342 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var invoiceable_disp7343 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var type_disp7344 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var button_text7345 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": null });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(courses.EnrolmentStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(courses.EnrolmentStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(courses.EnrolmentStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentStates.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "uses_a_place", "editable": false, "header": "Uses a place", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentStates.uses_a_place) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "invoiceable", "editable": false, "header": "invoiceable", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentStates.invoiceable) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentStates.type) ", "width": Lino.chars2width(31) }, { "colIndex": 7, "dataIndex": "button_text", "editable": false, "header": "Symbol", "hidden": true, "sortable": false, "tooltip": "(courses.EnrolmentStates.button_text) ", "width": Lino.chars2width(5) } ];
    Lino.courses.EnrolmentStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.EnrolmentStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/EnrolmentStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.EnrolmentStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.EnrolmentStates.GridPanel(p);
});

// js_render_GridPanel_class tickets.ProjectEvents
Lino.tickets.ProjectEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/tickets/ProjectEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/ProjectEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Observed events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7347 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7348 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7349 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7350 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7351 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(tickets.ProjectEvents.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(tickets.ProjectEvents.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(tickets.ProjectEvents.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectEvents.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(tickets.ProjectEvents.type) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.ProjectEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.ProjectEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/ProjectEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.ProjectEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.ProjectEvents.GridPanel(p);
});

// js_render_GridPanel_class cal.EventEvents
Lino.cal.EventEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/EventEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EventEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EventEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Observed events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7353 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7354 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7355 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7356 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7357 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.EventEvents.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.EventEvents.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.EventEvents.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(cal.EventEvents.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(cal.EventEvents.type) ", "width": Lino.chars2width(31) } ];
    Lino.cal.EventEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EventEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EventEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EventEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EventEvents.GridPanel(p);
});

// js_render_GridPanel_class votes.Ratings
Lino.votes.Ratings.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/votes/Ratings",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/votes/Ratings','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/votes/Ratings','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Ratings",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7359 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7360 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7361 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7362 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7363 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(votes.Ratings.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(votes.Ratings.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(votes.Ratings.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(votes.Ratings.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(votes.Ratings.type) ", "width": Lino.chars2width(31) } ];
    Lino.votes.Ratings.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.votes.Ratings.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/votes/Ratings", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.votes.Ratings.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/votes/Ratings", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.votes.Ratings.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.votes.Ratings.GridPanel(p);
});

// js_render_GridPanel_class cal.GuestStates
Lino.cal.GuestStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/GuestStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/GuestStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/GuestStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Guest states",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "afterwards", "type": "boolean" }, { "name": "text" }, { "name": "button_text" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7365 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7366 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var afterwards_disp7367 = new Ext.form.DisplayField({ "disabled": true });
    var text7368 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var button_text7369 = new Ext.form.TextField({ "disabled": true, "maxLength": null });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.GuestStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.GuestStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "afterwards", "editable": false, "header": "Afterwards", "sortable": false, "tooltip": "(cal.GuestStates.afterwards) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.GuestStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 4, "dataIndex": "button_text", "editable": false, "header": "Symbol", "sortable": false, "tooltip": "(cal.GuestStates.button_text) ", "width": Lino.chars2width(5) } ];
    Lino.cal.GuestStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.GuestStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/GuestStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.GuestStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.GuestStates.GridPanel(p);
});

// js_render_GridPanel_class meetings.MeetingStates
Lino.meetings.MeetingStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/meetings/MeetingStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/meetings/MeetingStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/meetings/MeetingStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "States",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "button_text" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7371 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7372 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7373 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7374 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7375 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var button_text7376 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": null });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(meetings.MeetingStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(meetings.MeetingStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(meetings.MeetingStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(meetings.MeetingStates.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(meetings.MeetingStates.type) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "button_text", "editable": false, "header": "Symbol", "hidden": true, "sortable": false, "tooltip": "(meetings.MeetingStates.button_text) ", "width": Lino.chars2width(5) } ];
    Lino.meetings.MeetingStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.meetings.MeetingStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MeetingStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MeetingStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/meetings/MeetingStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.meetings.MeetingStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.meetings.MeetingStates.GridPanel(p);
});

// js_render_GridPanel_class addresses.AddressTypes
Lino.addresses.AddressTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/addresses/AddressTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/addresses/AddressTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/addresses/AddressTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Aadressiliike",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7378 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7379 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7380 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7381 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7382 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(addresses.AddressTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(addresses.AddressTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(addresses.AddressTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(addresses.AddressTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(addresses.AddressTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.addresses.AddressTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.addresses.AddressTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/addresses/AddressTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.addresses.AddressTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.addresses.AddressTypes.GridPanel(p);
});

// js_render_GridPanel_class printing.BuildMethods
Lino.printing.BuildMethods.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/printing/BuildMethods",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/printing/BuildMethods','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/printing/BuildMethods','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "BuildMethods",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7384 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7385 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7386 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7387 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7388 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(printing.BuildMethods.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(printing.BuildMethods.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(printing.BuildMethods.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(printing.BuildMethods.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(printing.BuildMethods.type) ", "width": Lino.chars2width(31) } ];
    Lino.printing.BuildMethods.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.printing.BuildMethods.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/printing/BuildMethods", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.printing.BuildMethods.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/printing/BuildMethods", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.printing.BuildMethods.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.printing.BuildMethods.GridPanel(p);
});

// js_render_GridPanel_class cal.EntryStates
Lino.cal.EntryStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/EntryStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/EntryStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/EntryStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Event states",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 9,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "button_text" }, { "name": "edit_guests", "type": "boolean" }, { "name": "fixed", "type": "boolean" }, { "name": "transparent", "type": "boolean" }, { "name": "noauto", "type": "boolean" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7390 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7391 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7392 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var button_text7393 = new Ext.form.TextField({ "disabled": true, "maxLength": null });
    var edit_guests_disp7394 = new Ext.form.DisplayField({ "disabled": true });
    var fixed_disp7395 = new Ext.form.DisplayField({ "disabled": true });
    var transparent_disp7396 = new Ext.form.DisplayField({ "disabled": true });
    var noauto_disp7397 = new Ext.form.DisplayField({ "disabled": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.EntryStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.EntryStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.EntryStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "button_text", "editable": false, "header": "Symbol", "sortable": false, "tooltip": "(cal.EntryStates.button_text) ", "width": Lino.chars2width(5) }, { "colIndex": 4, "dataIndex": "edit_guests", "editable": false, "header": "Edit participants", "sortable": false, "tooltip": "(cal.EntryStates.edit_guests) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "fixed", "editable": false, "header": "Stable", "sortable": false, "tooltip": "(cal.EntryStates.fixed) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "transparent", "editable": false, "header": "Transparent", "sortable": false, "tooltip": "(cal.EntryStates.transparent) ", "width": Lino.chars2width(21) }, { "colIndex": 7, "dataIndex": "noauto", "editable": false, "header": "No auto", "sortable": false, "tooltip": "(cal.EntryStates.noauto) ", "width": Lino.chars2width(21) } ];
    Lino.cal.EntryStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.EntryStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntryStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntryStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/EntryStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.EntryStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.EntryStates.GridPanel(p);
});

// js_render_GridPanel_class tickets.TicketEvents
Lino.tickets.TicketEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/tickets/TicketEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Observed events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7399 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7400 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7401 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7402 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7403 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(tickets.TicketEvents.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(tickets.TicketEvents.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(tickets.TicketEvents.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketEvents.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketEvents.type) ", "width": Lino.chars2width(31) } ];
    Lino.tickets.TicketEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketEvents.GridPanel(p);
});

// js_render_GridPanel_class cal.AccessClasses
Lino.cal.AccessClasses.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/cal/AccessClasses",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/cal/AccessClasses','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/cal/AccessClasses','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "AccessClasses",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7405 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7406 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7407 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7408 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7409 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(cal.AccessClasses.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(cal.AccessClasses.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(cal.AccessClasses.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(cal.AccessClasses.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(cal.AccessClasses.type) ", "width": Lino.chars2width(31) } ];
    Lino.cal.AccessClasses.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.AccessClasses.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AccessClasses", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AccessClasses.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/AccessClasses", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.AccessClasses.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.AccessClasses.GridPanel(p);
});

// js_render_GridPanel_class system.YesNo
Lino.system.YesNo.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/system/YesNo",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/system/YesNo','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/system/YesNo','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Yes or no",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7411 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7412 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7413 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7414 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7415 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(system.YesNo.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(system.YesNo.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(system.YesNo.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(system.YesNo.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(system.YesNo.type) ", "width": Lino.chars2width(31) } ];
    Lino.system.YesNo.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.system.YesNo.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/YesNo", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.YesNo.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/system/YesNo", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.system.YesNo.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.system.YesNo.GridPanel(p);
});

// js_render_GridPanel_class votes.VoteEvents
Lino.votes.VoteEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/votes/VoteEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/votes/VoteEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/votes/VoteEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Observed events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7417 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7418 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7419 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7420 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7421 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(votes.VoteEvents.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(votes.VoteEvents.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(votes.VoteEvents.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(votes.VoteEvents.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(votes.VoteEvents.type) ", "width": Lino.chars2width(31) } ];
    Lino.votes.VoteEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.votes.VoteEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/votes/VoteEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.votes.VoteEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/votes/VoteEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.votes.VoteEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.votes.VoteEvents.GridPanel(p);
});

// js_render_GridPanel_class users.UserTypes
Lino.users.UserTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/users/UserTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/UserTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/UserTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Kasutajaliigid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 5,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "user_role" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7423 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7424 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7425 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var user_role_disp7426 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(users.UserTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(users.UserTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(users.UserTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "user_role", "editable": false, "header": "User role", "sortable": false, "tooltip": "(users.UserTypes.user_role) ", "width": Lino.chars2width(31) } ];
    Lino.users.UserTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.UserTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UserTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UserTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UserTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UserTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.UserTypes.GridPanel(p);
});

// js_render_GridPanel_class deploy.WishTypes
Lino.deploy.WishTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/deploy/WishTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/deploy/WishTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/deploy/WishTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Wish types",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7428 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7429 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7430 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7431 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7432 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(deploy.WishTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(deploy.WishTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(deploy.WishTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(deploy.WishTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(deploy.WishTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.deploy.WishTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.deploy.WishTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/WishTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.WishTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/deploy/WishTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.deploy.WishTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.deploy.WishTypes.GridPanel(p);
});

// js_render_GridPanel_class tickets.TicketStates
Lino.tickets.TicketStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/tickets/TicketStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Lipikuolekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "button_text" }, { "name": "active", "type": "boolean" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7434 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7435 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7436 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var button_text7437 = new Ext.form.TextField({ "disabled": true, "maxLength": null });
    var active_disp7438 = new Ext.form.DisplayField({ "disabled": true });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(tickets.TicketStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(tickets.TicketStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(tickets.TicketStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "button_text", "editable": false, "header": "Symbol", "sortable": false, "tooltip": "(tickets.TicketStates.button_text) ", "width": Lino.chars2width(5) }, { "colIndex": 4, "dataIndex": "active", "editable": false, "header": "Active", "sortable": false, "tooltip": "(tickets.TicketStates.active) ", "width": Lino.chars2width(21) } ];
    Lino.tickets.TicketStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.tickets.TicketStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.tickets.TicketStates.GridPanel(p);
});

// js_render_GridPanel_class courses.CourseAreas
Lino.courses.CourseAreas.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/courses/CourseAreas",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/CourseAreas','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/CourseAreas','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Course layouts",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7440 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7441 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7442 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7443 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7444 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(courses.CourseAreas.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(courses.CourseAreas.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(courses.CourseAreas.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.CourseAreas.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(courses.CourseAreas.type) ", "width": Lino.chars2width(31) } ];
    Lino.courses.CourseAreas.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CourseAreas.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CourseAreas", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CourseAreas.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CourseAreas", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CourseAreas.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.CourseAreas.GridPanel(p);
});

// js_render_GridPanel_class contacts.PartnerEvents
Lino.contacts.PartnerEvents.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/contacts/PartnerEvents",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/contacts/PartnerEvents','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/contacts/PartnerEvents','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Observed events",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7446 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7447 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7448 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7449 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7450 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(contacts.PartnerEvents.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(contacts.PartnerEvents.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(contacts.PartnerEvents.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnerEvents.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(contacts.PartnerEvents.type) ", "width": Lino.chars2width(31) } ];
    Lino.contacts.PartnerEvents.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.contacts.PartnerEvents.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnerEvents", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnerEvents.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/contacts/PartnerEvents", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.contacts.PartnerEvents.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.contacts.PartnerEvents.GridPanel(p);
});

// js_render_GridPanel_class courses.CourseStates
Lino.courses.CourseStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/courses/CourseStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/courses/CourseStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/courses/CourseStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "States",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 8,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "invoiceable", "type": "boolean" }, { "name": "type" }, { "name": "button_text" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7452 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7453 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7454 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7455 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var invoiceable_disp7456 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var type_disp7457 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var button_text7458 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": null });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(courses.CourseStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(courses.CourseStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(courses.CourseStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(courses.CourseStates.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "invoiceable", "editable": false, "header": "invoiceable", "hidden": true, "sortable": false, "tooltip": "(courses.CourseStates.invoiceable) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(courses.CourseStates.type) ", "width": Lino.chars2width(31) }, { "colIndex": 6, "dataIndex": "button_text", "editable": false, "header": "Symbol", "hidden": true, "sortable": false, "tooltip": "(courses.CourseStates.button_text) ", "width": Lino.chars2width(5) } ];
    Lino.courses.CourseStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.courses.CourseStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CourseStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CourseStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/courses/CourseStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.courses.CourseStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.courses.CourseStates.GridPanel(p);
});

// js_render_GridPanel_class countries.PlaceTypes
Lino.countries.PlaceTypes.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/countries/PlaceTypes",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/countries/PlaceTypes','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/countries/PlaceTypes','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "PlaceTypes",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 6,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7460 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7461 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7462 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7463 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7464 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(countries.PlaceTypes.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(countries.PlaceTypes.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(countries.PlaceTypes.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(countries.PlaceTypes.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(countries.PlaceTypes.type) ", "width": Lino.chars2width(31) } ];
    Lino.countries.PlaceTypes.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.countries.PlaceTypes.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlaceTypes", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlaceTypes.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/countries/PlaceTypes", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.countries.PlaceTypes.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.countries.PlaceTypes.GridPanel(p);
});

// js_render_GridPanel_class users.UserStates
Lino.users.UserStates.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true },
  ls_url : "/users/UserStates",
  ls_bbar_actions : [ { "auto_save": true, "iconCls": "x-tbar-html", "itemId": "show_as_html", "menu_item_text": "HTML", "overflowText": "HTML", "panel_btn_handler": Lino.list_action_handler('/users/UserStates','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "auto_save": true, "iconCls": "x-tbar-page_excel", "itemId": "export_excel", "menu_item_text": "Export to .xls", "overflowText": "Export to .xls", "panel_btn_handler": Lino.list_action_handler('/users/UserStates','export_excel','GET',Lino.get_current_grid_config), "tooltip": "Export this table as an .xls document" } ],
  cell_edit : true,
  title : "Kasutaja olekud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disable_editing : true,
  disabled_actions_index : 7,
  ls_store_fields : [ { "name": "value" }, { "name": "name" }, { "name": "text" }, { "name": "remark" }, { "name": "type" }, { "name": "button_text" }, { "name": "None" }, { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  ls_id_property : null,
  gc_name : 0,
  initComponent : function() {
    var ww = this.containing_window;
    var value7466 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var name7467 = new Ext.form.TextField({ "disabled": true, "maxLength": 20 });
    var text7468 = new Ext.form.TextField({ "disabled": true, "maxLength": 50 });
    var remark_disp7469 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var type_disp7470 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var button_text7471 = new Ext.form.TextField({ "disabled": true, "hidden": true, "maxLength": null });
    this.before_row_edit = function(record) {
    };
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "value", "editable": false, "header": "value", "sortable": false, "tooltip": "(users.UserStates.value) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "name", "editable": false, "header": "nimi", "sortable": false, "tooltip": "(users.UserStates.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "text", "editable": false, "header": "text", "sortable": false, "tooltip": "(users.UserStates.text) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "remark", "editable": false, "header": "M\u00e4rkus", "hidden": true, "sortable": false, "tooltip": "(users.UserStates.remark) ", "width": Lino.chars2width(31) }, { "colIndex": 4, "dataIndex": "type", "editable": false, "header": "Type", "hidden": true, "sortable": false, "tooltip": "(users.UserStates.type) ", "width": Lino.chars2width(31) }, { "colIndex": 5, "dataIndex": "button_text", "editable": false, "header": "Symbol", "hidden": true, "sortable": false, "tooltip": "(users.UserStates.button_text) ", "width": Lino.chars2width(5) } ];
    Lino.users.UserStates.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.users.UserStates.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UserStates", "GET", pk, "show_as_html", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UserStates.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/UserStates", "GET", pk, "export_excel", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.UserStates.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.users.UserStates.GridPanel(p);
});
