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

// lino.js --- generated Tue Apr 11 19:33:27 2017 by Lino Noi 2017.2.0 for Anonüümne.
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.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.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.system.SiteConfigs')
Ext.namespace('Lino.gfks.ContentTypes')
Ext.namespace('Lino.gfks.HelpTexts')
Ext.namespace('Lino.countries.Countries')
Ext.namespace('Lino.countries.Places')
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.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.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.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.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.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.tinymce.TextFieldTemplates')
Ext.namespace('Lino.tinymce.MyTextFieldTemplates')
Ext.namespace('Lino.dashboard.Widgets')
Ext.namespace('Lino.dashboard.AllWidgets')
Ext.namespace('Lino.mailbox.Mailboxes')
Ext.namespace('Lino.mailbox.Messages')
Ext.namespace('Lino.mailbox.UnassignedMessages')
Ext.namespace('Lino.mailbox.MessageAttachments')
Ext.namespace('Lino.users.OtherUsers')
Ext.namespace('Lino.users.Register')
Ext.namespace('Lino.users.NewUsers')
Ext.namespace('Lino.deploy.Deployments')
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.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.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.comments.CommentsByRFC')
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.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.clocking.SessionsByReport')
Ext.namespace('Lino.clocking.TicketsByReport')
Ext.namespace('Lino.clocking.ProjectsByReport')
Ext.namespace('Lino.clocking.CoursesByReport')
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.dashboard.WidgetsByUser')
Ext.namespace('Lino.mailbox.MessagesByMailbox')
Ext.namespace('Lino.mailbox.MessageAttachmentsByMessage')
Ext.namespace('Lino.courses.MyEnrolments')
Ext.namespace('Lino.deploy.DeploymentsByMilestone')
Ext.namespace('Lino.deploy.DeploymentsByTicket')
Ext.namespace('Lino.uploads.UploadsByController')
Ext.namespace('Lino.changes.ChangesByObject')
Ext.namespace('Lino.cal.TasksByController')
Ext.namespace('Lino.gfks.HelpTextsByModel')
Ext.namespace('Lino.changes.ChangesByMaster')
Ext.namespace('Lino.cal.EntriesByController')
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.cal.Weekdays')
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.votes.VoteStates')
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.users.UserStates')
Ext.namespace('Lino.courses.CourseAreas')
Ext.namespace('Lino.contacts.PartnerEvents')
Ext.namespace('Lino.courses.CourseStates')
Ext.namespace('Lino.countries.PlaceTypes')
Ext.namespace('Lino.tickets.TicketStates')

// 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.cal.Weekdays = [ [ "1", "esmasp\u00e4ev" ], [ "2", "teisip\u00e4ev" ], [ "3", "kolmap\u00e4ev" ], [ "4", "neljap\u00e4ev" ], [ "5", "reede" ], [ "6", "laup\u00e4ev" ], [ "7", "p\u00fchap\u00e4ev" ] ];
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.votes.VoteStates = [ [ "00", "Autor" ], [ "05", "Kutsutud" ], [ "10", "Huvi" ], [ "15", "Poolt" ], [ "16", "Vastu" ], [ "20", "Kandidaat" ], [ "30", "Assigned" ], [ "40", "Done" ], [ "50", "Hinnatud" ], [ "60", "T\u00fchistatud" ] ];
Lino.printing.BuildMethods = [ [ "latex", "LatexBuildMethod" ], [ "pisa", "PisaBuildMethod" ], [ "rtf", "RtfBuildMethod" ], [ "weasy2html", "WeasyHtmlBuildMethod" ], [ "weasy2pdf", "WeasyPdfBuildMethod" ], [ "appyodt", "AppyOdtBuildMethod" ], [ "appydoc", "AppyDocBuildMethod" ], [ "appypdf", "AppyPdfBuildMethod" ], [ "appyrtf", "AppyRtfBuildMethod" ] ];
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 (Consultant)" ], [ "300", "300 (Hoster)" ], [ "400", "400 (Developer)" ], [ "490", "490 (Senior developer)" ], [ "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.users.UserStates = [ [ "10", "Uus" ], [ "20", "Active" ], [ "30", "Inactive" ] ];
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.tickets.TicketStates = [ [ "10", "Uus" ], [ "15", "Arutusel" ], [ "20", "Avatud" ], [ "22", "Alanud" ], [ "30", "Magab" ], [ "40", "Valmis" ], [ "50", "L\u00f5petatud" ], [ "60", "Refused" ] ];

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_for1 = 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_date2 = 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_date3 = 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_event4 = 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_for1, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_date2, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date3, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": observed_event4, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ interesting_for1, start_date2, end_date3, observed_event4 ];
    Lino.tickets.Projects.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_date10 = 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_date11 = 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 user12 = 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_state13 = 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_state14 = 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_panel15 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 18, "items": start_date10, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": end_date11, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": user12, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": event_state13, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": guest_state14, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var partner21 = 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_panel15, { "anchor": "-20", "autoHeight": true, "items": partner21, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date10, end_date11, user12, event_state13, guest_state14, partner21 ];
    Lino.cal.Guests.ParamsPanel.superclass.initComponent.call(this);
  }
});


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_date24 = 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_date25 = 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 user26 = 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 state27 = 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_panel28 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": start_date24, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": end_date25, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": user26, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": state27, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel28 ];
    this.fields = [ start_date24, end_date25, user26, state27 ];
    Lino.cal.Tasks.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 date34 = 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 user35 = 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_type36 = 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_type37 = 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_id38 = 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_panel39 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": date34, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": user35, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": change_type36, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": object_type37, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": object_id38, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel39 ];
    this.fields = [ date34, user35, change_type36, object_type37, object_id38 ];
    Lino.changes.Changes.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 user46 = 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": user46, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user46 ];
    Lino.faculties.Offers.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 user49 = 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": user49, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user49 ];
    Lino.cal.RecurrentEvents.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 user52 = 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": user52, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user52 ];
    Lino.dashboard.Widgets.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_date55 = 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_date56 = 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_closed57 = 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_date55, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": end_date56, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": show_closed57, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date55, end_date56, show_closed57 ];
    Lino.deploy.Deployments.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 user62 = 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_user63 = 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 site64 = 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 project65 = 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 state66 = 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_panel67 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": user62, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": end_user63, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": site64, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": project65, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": state66, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date73 = 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_date74 = 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_event75 = 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 topic76 = 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_by77 = 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_active78 = 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_panel79 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 13, "items": start_date73, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": end_date74, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event75, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": topic76, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": feasable_by77, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": show_active78, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel67, main_2_panel79 ];
    this.fields = [ user62, end_user63, site64, project65, state66, start_date73, end_date74, observed_event75, topic76, feasable_by77, show_active78 ];
    Lino.tickets.MyTickets.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 inspected87 = 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_callables88 = 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": inspected87, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": show_callables88, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ inspected87, show_callables88 ];
    Lino.about.Inspector.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_date92 = 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_date93 = 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_event94 = 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 state95 = 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_panel96 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 26, "items": start_date92, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": end_date93, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event94, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": state95, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user101 = 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_to102 = 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_type103 = 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 room104 = 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_appointments105 = 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_panel106 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": user101, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": assigned_to102, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": event_type103, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": room104, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": show_appointments105, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel96, main_2_panel106 ];
    this.fields = [ start_date92, end_date93, observed_event94, state95, user101, assigned_to102, event_type103, room104, show_appointments105 ];
    Lino.cal.Events.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 user113 = 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": user113, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user113 ];
    Lino.comments.Comments.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 user116 = 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": user116, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user116 ];
    Lino.cal.Subscriptions.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_date119 = 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_date120 = 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 pcertifying121 = 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_panel122 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": start_date119, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": end_date120, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": pcertifying121, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user126 = 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_type127 = 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_panel128 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": user126, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": excerpt_type127, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel122, main_2_panel128 ];
    this.fields = [ start_date119, end_date120, pcertifying121, user126, excerpt_type127 ];
    Lino.excerpts.Excerpts.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 user132 = 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_mode133 = 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 state134 = 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_state135 = 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_user136 = 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_panel137 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 27, "items": user132, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": mail_mode133, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": state134, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": votable_state135, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": ticket_user136, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date143 = 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_date144 = 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_event145 = 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_user146 = 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_panel147 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 23, "items": start_date143, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": end_date144, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 17, "items": observed_event145, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 35, "items": exclude_ticket_user146, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel137, main_2_panel147 ];
    this.fields = [ user132, mail_mode133, state134, votable_state135, ticket_user136, start_date143, end_date144, observed_event145, exclude_ticket_user146 ];
    Lino.votes.Votes.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 profile153 = 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_date154 = 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 gender155 = 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 observed_event156 = 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_from157 = 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_state158 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "User state", "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 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","(users.Users.start_date) Start date of observed period") }, "name": "start_date", "selectOnFocus": true, "value": null });
    var aged_to160 = 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": 24, "items": profile153, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": end_date154, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": gender155, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": observed_event156, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 4, "items": aged_from157, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": user_state158, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": start_date159, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 4, "items": aged_to160, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ profile153, end_date154, gender155, observed_event156, aged_from157, user_state158, start_date159, aged_to160 ];
    Lino.users.Users.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 user170 = 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": user170, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user170 ];
    Lino.blogs.Entries.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_date173 = 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_date174 = 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_event175 = 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 company176 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "Organization", "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 project177 = 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 user178 = 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_type179 = 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 ticket180 = 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_date173, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": end_date174, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": observed_event175, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": company176, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": project177, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": user178, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": session_type179, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": ticket180, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date173, end_date174, observed_event175, company176, project177, user178, session_type179, ticket180 ];
    Lino.clocking.Sessions.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_date190 = 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_date191 = 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 author192 = 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 state193 = 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 active194 = new Lino.ChoicesFieldElement({ "allowBlank": false, "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": Lino.system.YesNo });
    var participants_only195 = 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_date190, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 17, "items": end_date191, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": author192, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": state193, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": active194, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": participants_only195, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date190, end_date191, author192, state193, active194, participants_only195 ];
    Lino.courses.MyEnrolments.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 line203 = 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 teacher204 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "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 user205 = 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 state206 = 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_enroll207 = 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": line203, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": teacher204, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": user205, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": state206, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": can_enroll207, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ line203, teacher204, user205, state206, can_enroll207 ];
    Lino.courses.CoursesByTopic.ParamsPanel.superclass.initComponent.call(this);
  }
});


Lino.mailbox.Messages.ParamsPanel = Ext.extend(Ext.form.FormPanel, {
  autoScroll: false,
  border: false,
  labelWidth: 81,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  layout: 'form',
  autoHeight: true,
  initComponent : function() {
    var show_assigned214 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Assigned", "forceSelection": true, "hiddenName": "show_assignedHidden", "listeners": { "render": Lino.quicktip_renderer("Assigned","(mailbox.Messages.show_assigned) ") }, "name": "show_assigned", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.YesNo) });
    this.items = [ { "autoHeight": true, "items": show_assigned214, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ show_assigned214 ];
    Lino.mailbox.Messages.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 user217 = 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_user218 = 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_to219 = 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_to220 = 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_for221 = 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 site222 = 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 project223 = 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 state224 = 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_to225 = 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_panel226 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 11, "items": user217, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": end_user218, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": assigned_to219, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": not_assigned_to220, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": interesting_for221, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": site222, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": project223, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 6, "items": state224, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": deployed_to225, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var has_project236 = 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_assigned237 = 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_active238 = 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_deployed239 = 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_todo240 = 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_private241 = 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_panel242 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": has_project236, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_assigned237, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_active238, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_deployed239, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_todo240, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": show_private241, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date249 = 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_date250 = 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_event251 = 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 topic252 = 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_by253 = 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 main_3_panel254 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 14, "items": start_date249, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": end_date250, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": observed_event251, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": topic252, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": feasable_by253, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel226, main_2_panel242, main_3_panel254 ];
    this.fields = [ user217, end_user218, assigned_to219, not_assigned_to220, interesting_for221, site222, project223, state224, deployed_to225, has_project236, show_assigned237, show_active238, show_deployed239, show_todo240, show_private241, start_date249, end_date250, observed_event251, topic252, feasable_by253 ];
    Lino.tickets.Tickets.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_user261 = 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_by262 = 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 site263 = 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 project264 = 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 state265 = 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_panel266 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": end_user261, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": feasable_by262, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": site263, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": project264, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": state265, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var show_assigned272 = 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_active273 = 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 topic274 = 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_panel275 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 20, "items": show_assigned272, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": show_active273, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 58, "items": topic274, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel266, main_2_panel275 ];
    this.fields = [ end_user261, feasable_by262, site263, project264, state265, show_assigned272, show_active273, topic274 ];
    Lino.tickets.SuggestedTicketsByEndUser.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 user280 = 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_seen281 = 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_date282 = 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_date283 = 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": user280, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": show_seen281, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": start_date282, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 24, "items": end_date283, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user280, show_seen281, start_date282, end_date283 ];
    Lino.notify.Messages.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 user289 = 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": user289, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user289 ];
    Lino.users.Authorities.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_date292 = 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_date293 = 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 author294 = 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 state295 = 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_state296 = 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_only297 = 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_date292, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": end_date293, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": author294, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": state295, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": course_state296, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": participants_only297, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date292, end_date293, author294, state295, course_state296, participants_only297 ];
    Lino.courses.Enrolments.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_event305 = 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_date306 = 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_date307 = 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_event305, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": start_date306, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": end_date307, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ observed_event305, start_date306, end_date307 ];
    Lino.contacts.Partners.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 topic312 = 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 line313 = 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 user314 = 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 teacher315 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "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 state316 = 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_panel317 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": topic312, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": line313, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": user314, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": teacher315, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": state316, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var room323 = 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_enroll324 = 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_date325 = 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_date326 = 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_active327 = 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_panel328 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 31, "items": room323, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": can_enroll324, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": start_date325, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": end_date326, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": show_active327, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel317, main_2_panel328 ];
    this.fields = [ topic312, line313, user314, teacher315, state316, room323, can_enroll324, start_date325, end_date326, show_active327 ];
    Lino.courses.Activities.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_date335 = 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_date336 = 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 user337 = 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_type338 = 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_date335, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date336, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": user337, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": upload_type338, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ start_date335, end_date336, user337, upload_type338 ];
    Lino.uploads.Uploads.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 user344 = 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_date345 = 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_date346 = 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": user344, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": end_date345, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": start_date346, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user344, end_date345, start_date346 ];
    Lino.clocking.ServiceReports.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_date351 = 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_date352 = 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_event353 = 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 state354 = 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_panel355 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 26, "items": start_date351, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": end_date352, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": observed_event353, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": state354, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user360 = 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_to361 = 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_type362 = 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 room363 = 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_appointments364 = 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_panel365 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": user360, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": assigned_to361, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": event_type362, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": room363, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": show_appointments364, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    this.items = [ main_1_panel355, main_2_panel365 ];
    this.fields = [ start_date351, end_date352, observed_event353, state354, user360, assigned_to361, event_type362, room363, show_appointments364 ];
    Lino.cal.OneEvent.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 user372 = 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": user372, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ user372 ];
    Lino.tinymce.TextFieldTemplates.ParamsPanel.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.email419 = 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.subject420 = 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.email419, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.subject420, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.email419, this.subject420 ];
    Lino.users.NewUsers.send_welcome_email_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_date401 = 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_date402 = 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_remarks403 = 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_states404 = 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_date401, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.end_date402, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_remarks403, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_states404, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.start_date401, this.end_date402, this.show_remarks403, this.show_states404 ];
    Lino.courses.Activities.print_presence_sheet_html_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_date410 = 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_date411 = 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_remarks412 = 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_states413 = 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_date410, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.end_date411, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_remarks412, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.show_states413, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.start_date410, this.end_date411, this.show_remarks412, this.show_states413 ];
    Lino.courses.Activities.print_presence_sheet_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Companies.merge_row_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  autoHeight: true,
  border: false,
  layout: "form",
  labelWidth: 72,
  hideCheckBoxLabels: true,
  frame: true,
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'merge_row',
  ls_url: "/contacts/Companies",
  window_title: "Merge",
  before_row_edit : function(record) {
  },
  autoHeight: true,
  initComponent : function() {
    this.merge_to375 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "into...", "hiddenName": "merge_toHidden", "listeners": { "render": Lino.quicktip_renderer("into...","(Merge.merge_to) ") }, "name": "merge_to", "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": "/apchoices/contacts/Companies/merge_row/merge_to" }) }) });
    this.reason376 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Reason", "listeners": { "render": Lino.quicktip_renderer("Reason","(Merge.reason) ") }, "maxLength": 100, "name": "reason", "selectOnFocus": true });
    this.items = [ { "anchor": "-20", "autoHeight": true, "items": this.merge_to375, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.reason376, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.merge_to375, this.reason376 ];
    Lino.contacts.Companies.merge_row_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.email396 = 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.subject397 = 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.email396, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.subject397, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.email396, this.subject397 ];
    Lino.users.AllUsers.send_welcome_email_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.current389 = 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.new1390 = 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.new2391 = 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.current389, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.new1390, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.new2391, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.current389, this.new1390, this.new2391 ];
    Lino.users.Users.change_password_ActionFormPanel.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.email384 = 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_code385 = 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.email384, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": this.verification_code385, "labelAlign": "top", "layout": "form", "xtype": "panel" } ];
    this.fields = [ this.email384, this.verification_code385 ];
    Lino.users.Users.verify_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.Votes.wf8_ActionFormPanel = Ext.extend(Lino.ActionFormPanel,{
  autoScroll: false,
  border: false,
  layout: "vbox",
  labelWidth: 72,
  hideCheckBoxLabels: true,
  frame: true,
  layoutConfig: { "align": "stretch" },
  bodyBorder: false,
  labelAlign: "top",
  action_name: 'wf8',
  ls_url: "/votes/Votes",
  window_title: "Rate",
  before_row_edit : function(record) {
    this.comment381.refresh();
  },
  initComponent : function() {
    this.rating380 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Rating", "forceSelection": true, "hiddenName": "ratingHidden", "listeners": { "render": Lino.quicktip_renderer("Rating","(Rate.rating) ") }, "name": "rating", "selectOnFocus": true, "store": Lino.votes.Ratings });
    this.comment381 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Comment", "flex": 83, "name": "comment", "selectOnFocus": true, "title": "Comment" });
    this.items = [ { "autoHeight": true, "items": this.rating380, "labelAlign": "top", "layout": "form", "xtype": "panel" }, this.comment381 ];
    this.fields = [ this.rating380, this.comment381 ];
    Lino.votes.Votes.wf8_ActionFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Partners.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 10,
  initComponent : function() {
    var name424 = 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("Nimi","(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 country425 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Riik","(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 city426 = 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("Linn","(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_code427 = 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_panel428 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": country425, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": city426, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code427, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street432 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Street</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(contacts.Partners.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no433 = 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("Nr.","(contacts.Partners.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box434 = 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_panel435 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": street432, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_no433, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_box434, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_box_panel439 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 50, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name424, "labelAlign": "top", "layout": "form", "xtype": "panel" }, address_box_2_panel428, address_box_4_panel435 ], "labelAlign": "top", "labelWidth": 45, "layout": "form", "title": "Aadres" });
    var url441 = 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 phone442 = 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 gsm443 = 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_panel444 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 25, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": url441, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": phone442, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": gsm443, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "form", "title": "Contact" });
    var overview_disp448 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Kirjeldus", "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(contacts.Partners.overview) ") }, "name": "overview", "value": "<br/>" });
    var main_1_panel449 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ address_box_panel439, contact_box_panel444, { "autoHeight": true, "flex": 25, "items": overview_disp448, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks451 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 62, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_panel452 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel449, remarks451 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel452;
    this.before_row_edit = function(record) {
      city426.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city426.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      remarks451.refresh();
    }
    this.onRender = function(ct, position) {
      country425.on('change',Lino.chooser_handler(city426,'country'));
      Lino.contacts.Partners.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.contacts.Partners.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city426.on("change", function(){ this.save() }, this);
    zip_code427.on("change", function(){ this.save() }, this);
  }
});


Lino.mailbox.Messages.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 64,
  initComponent : function() {
    var from_header453 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "From header", "listeners": { "render": Lino.quicktip_renderer("From header","(mailbox.Messages.from_header) ") }, "maxLength": 255, "name": "from_header", "selectOnFocus": true });
    var subject454 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Teema", "listeners": { "render": Lino.quicktip_renderer("Teema","(mailbox.Messages.subject) ") }, "maxLength": 255, "name": "subject", "selectOnFocus": true });
    var ticket455 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(mailbox.Messages.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/mailbox/Messages/ticket" }) }) });
    var general_1_panel456 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": from_header453, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": subject454, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": ticket455, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var to_header460 = new Lino.RichTextPanel({ "allowBlank": false, "containing_panel": this, "fieldLabel": "To header", "flex": 5, "name": "to_header", "region": "center", "selectOnFocus": true, "split": true, "title": "To header" });
    var general_panel469 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel456, to_header460 ], "labelAlign": "top", "labelWidth": 90, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var preview_htmlbox470 = 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 }, "name": "preview", "title": "Eelvaade", "value": "<br/>" });
    var main_panel471 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel469, preview_htmlbox470 ], "labelAlign": "top", "split": true });
    this.items = main_panel471;
    this.before_row_edit = function(record) {
      to_header460.refresh();
      preview_htmlbox470.refresh();
    }
    Lino.mailbox.Messages.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.EventTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 17,
  initComponent : function() {
    var name472 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.EventTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et473 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.EventTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel474 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name472, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et473, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var event_label477 = 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_et478 = 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_panel479 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": event_label477, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": event_label_et478, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date482 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(cal.EventTypes.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var max_days483 = 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 id484 = 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_panel485 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 56, "items": start_date482, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": max_days483, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": id484, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var email_template489 = 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_email490 = 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_panel491 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": email_template489, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": attach_to_email490, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var is_appointment494 = 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_rooms495 = 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_user496 = 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_conflicting497 = 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_panel498 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 28, "items": is_appointment494, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": all_rooms495, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": locks_user496, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": max_conflicting497, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 189, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel622 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel474, main_2_panel479, main_3_panel485, main_4_panel491, main_5_panel498 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel622;
    this.before_row_edit = function(record) {
    }
    Lino.cal.EventTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Tasks.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 14,
  initComponent : function() {
    var summary623 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00fchikirjeldus", "listeners": { "render": Lino.quicktip_renderer("L\u00fchikirjeldus","(cal.Tasks.summary) ") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var user624 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_panel625 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": summary623, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user624, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "form" });
    this.items = main_panel625;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Tasks.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.DemandsByDemander.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 45,
  initComponent : function() {
    var skill628 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Oskus","(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 importance629 = 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_panel630 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": skill628, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": importance629, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "form" });
    this.items = main_panel630;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.DemandsByDemander.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 30,
  initComponent : function() {
    var line633 = 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("Tegevuste sari","(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 room634 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Ruum","(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_disp635 = 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 name636 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(courses.Activities.name) ") }, "maxLength": 100, "name": "name", "selectOnFocus": true });
    var general_1_panel637 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": line633, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": room634, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": workflow_buttons_disp635, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": name636, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var general_panel667 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel637 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var start_date668 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(courses.Activities.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date669 = 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_time670 = 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_time671 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (aeg)","(courses.Activities.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var cal_tab_1_panel672 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": start_date668, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": end_date669, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_time670, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_time671, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var max_events677 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "S\u00fcndmuste arv", "listeners": { "render": Lino.quicktip_renderer("S\u00fcndmuste arv","(courses.Activities.max_events) ") }, "name": "max_events", "selectOnFocus": true });
    var max_date678 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Genereeri s\u00fcndmusi kuni", "listeners": { "render": Lino.quicktip_renderer("Genereeri s\u00fcndmusi kuni","(courses.Activities.max_date) ") }, "name": "max_date", "selectOnFocus": true });
    var every_unit679 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Korduvus", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Korduvus","(courses.Activities.every_unit) ") }, "name": "every_unit", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every680 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Korda iga","(courses.Activities.every) ") }, "name": "every", "selectOnFocus": true });
    var cal_tab_2_panel681 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 11, "items": max_events677, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 29, "items": max_date678, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 47, "items": every_unit679, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": every680, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var monday686 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "esmasp\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("esmasp\u00e4ev","(courses.Activities.monday) ") }, "name": "monday", "selectOnFocus": true });
    var tuesday687 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "teisip\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("teisip\u00e4ev","(courses.Activities.tuesday) ") }, "name": "tuesday", "selectOnFocus": true });
    var wednesday688 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "kolmap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("kolmap\u00e4ev","(courses.Activities.wednesday) ") }, "name": "wednesday", "selectOnFocus": true });
    var thursday689 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "neljap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("neljap\u00e4ev","(courses.Activities.thursday) ") }, "name": "thursday", "selectOnFocus": true });
    var friday690 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "reede", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("reede","(courses.Activities.friday) ") }, "name": "friday", "selectOnFocus": true });
    var saturday691 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "laup\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("laup\u00e4ev","(courses.Activities.saturday) ") }, "name": "saturday", "selectOnFocus": true });
    var sunday692 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "p\u00fchap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("p\u00fchap\u00e4ev","(courses.Activities.sunday) ") }, "name": "sunday", "selectOnFocus": true });
    var cal_tab_3_panel693 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 14, "items": monday686, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": tuesday687, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": wednesday688, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": thursday689, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": friday690, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": saturday691, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": sunday692, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var cal_tab_panel702 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ cal_tab_1_panel672, cal_tab_2_panel681, cal_tab_3_panel693 ], "labelAlign": "top", "labelWidth": 63, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Kalender" });
    var enrolments_until703 = 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_places704 = 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 confirmed705 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Kinnitatud", "listeners": { "render": Lino.quicktip_renderer("Kinnitatud","(courses.Activities.confirmed) ") }, "name": "confirmed" });
    var free_places706 = 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_disp707 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Tr\u00fcki", "listeners": { "render": Lino.quicktip_renderer("Tr\u00fcki","(courses.Activities.print_actions) ") }, "name": "print_actions", "value": "<br/>" });
    var enrolments_top_panel708 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 24, "items": enrolments_until703, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": max_places704, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": confirmed705, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": free_places706, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": print_actions_disp707, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var enrolments_panel715 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ enrolments_top_panel708 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Osav\u00f5tud" });
    var id716 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Activities.id) ") }, "name": "id", "selectOnFocus": true });
    var user717 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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 teacher718 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "\u00dcrituse juht", "hiddenName": "teacherHidden", "listeners": { "render": Lino.quicktip_renderer("\u00dcrituse juht","(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 more_left_panel719 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 37, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": id716, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user717, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": teacher718, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "form" });
    var blogs_EntriesByController_htmlbox723 = 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","(courses.Activities.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_panel724 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ more_left_panel719, blogs_EntriesByController_htmlbox723 ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description725 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et726 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var more_2_panel727 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ description725, description_et726 ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var more_panel728 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel724, more_2_panel727 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel729 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel667, cal_tab_panel702, enrolments_panel715, more_panel728 ], "labelAlign": "top", "split": true });
    this.items = main_panel729;
    this.before_row_edit = function(record) {
      blogs_EntriesByController_htmlbox723.refresh();
      description725.refresh();
      description_et726.refresh();
    }
    Lino.courses.Activities.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Enrolments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 29,
  initComponent : function() {
    var request_date730 = 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 user731 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_date732 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(courses.Enrolments.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date733 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (p\u00e4ev)","(courses.Enrolments.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var main_1_panel734 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": request_date730, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": user731, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": start_date732, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": end_date733, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var course739 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "courseHidden", "listeners": { "render": Lino.quicktip_renderer("Tegevus","(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 pupil740 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "Person", "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_panel741 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": course739, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": pupil740, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remark744 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(courses.Enrolments.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var workflow_buttons_disp745 = 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_panel746 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 41, "items": remark744, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 58, "items": workflow_buttons_disp745, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var confirmation_details749 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Confirmation details", "flex": 50, "name": "confirmation_details", "selectOnFocus": true, "title": "Confirmation details" });
    var main_panel750 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel734, main_2_panel741, main_3_panel746, confirmation_details749 ], "labelAlign": "top", "labelWidth": 189, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel750;
    this.before_row_edit = function(record) {
      course739.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course739.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil740.setContextValue('course', record ? record.data['courseHidden'] : undefined);
      confirmation_details749.refresh();
    }
    this.onRender = function(ct, position) {
      request_date730.on('change',Lino.chooser_handler(course739,'request_date'));
      course739.on('change',Lino.chooser_handler(pupil740,'course'));
      Lino.courses.Enrolments.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.Enrolments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Enrolments.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 29,
  initComponent : function() {
    var request_date751 = 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 user752 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_panel753 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": request_date751, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 60, "items": user752, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var course756 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "courseHidden", "listeners": { "render": Lino.quicktip_renderer("Tegevus","(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 pupil757 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "Person", "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_panel758 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": course756, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": pupil757, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remark761 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(courses.Enrolments.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var main_panel762 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel753, main_2_panel758, { "anchor": "-20", "autoHeight": true, "items": remark761, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "form" });
    this.items = main_panel762;
    this.before_row_edit = function(record) {
      course756.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course756.setContextValue('request_date', record ? record.data['request_date'] : undefined);
      pupil757.setContextValue('course', record ? record.data['courseHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      request_date751.on('change',Lino.chooser_handler(course756,'request_date'));
      course756.on('change',Lino.chooser_handler(pupil757,'course'));
      Lino.courses.Enrolments.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.Enrolments.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Companies.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 7,
  initComponent : function() {
    var name764 = 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("Nimi","(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 language765 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(contacts.Companies.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var email766 = 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_panel767 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": language765, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 66, "items": email766, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var type770 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization type...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organization type</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 id771 = 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_panel772 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 80, "items": type770, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": id771, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel775 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name764, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel767, main_3_panel772 ], "labelAlign": "top", "labelWidth": 45, "layout": "form" });
    this.items = main_panel775;
    this.before_row_edit = function(record) {
    }
    Lino.contacts.Companies.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.Entries.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 56,
  initComponent : function() {
    var title777 = 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_type778 = 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 id779 = 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_panel780 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 55, "items": title777, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": entry_type778, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": id779, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var pub_date784 = 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_time785 = 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 user786 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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 language787 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Keel", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(blogs.Entries.language) ") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp788 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var main_2_panel789 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": pub_date784, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": pub_time785, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": user786, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": language787, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": owner_disp788, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var body795 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Body", "flex": 75, "name": "body", "selectOnFocus": true, "title": "Body" });
    var main_3_panel804 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 71, "frame": false, "hideCheckBoxLabels": true, "items": [ body795 ], "labelAlign": "top", "labelWidth": 45, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel805 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel780, main_2_panel789, main_3_panel804 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel805;
    this.before_row_edit = function(record) {
      body795.refresh();
    }
    Lino.blogs.Entries.DetailFormPanel.superclass.initComponent.call(this);
  }
});


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


Lino.countries.Places.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 5,
  initComponent : function() {
    var name814 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(countries.Places.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et815 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(countries.Places.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var country816 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Riik","(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_panel817 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": name814, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": name_et815, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": country816, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var type821 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Asumiliik", "hiddenName": "typeHidden", "listeners": { "render": Lino.quicktip_renderer("Asumiliik","(countries.Places.type) ") }, "name": "type", "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/countries/Places/type" }) }) });
    var parent822 = 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_code823 = 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 id824 = 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_panel825 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 22, "items": type821, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 45, "items": parent822, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code823, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": id824, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel897 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel817, main_2_panel825 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel897;
    this.before_row_edit = function(record) {
      type821.setContextValue('country', record ? record.data['countryHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      country816.on('change',Lino.chooser_handler(type821,'country'));
      Lino.countries.Places.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.countries.Places.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.Sessions.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 51,
  initComponent : function() {
    var ticket898 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(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 summary899 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kokkuv\u00f5te</span>", "listeners": { "render": Lino.quicktip_renderer("Kokkuv\u00f5te","(clocking.Sessions.summary) Summary of the session.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var session_type900 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Istungiliik...", "fieldLabel": "Istungiliik", "hiddenName": "session_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Istungiliik","(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_panel901 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": ticket898, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": summary899, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": session_type900, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel901;
    this.before_row_edit = function(record) {
    }
    Lino.clocking.Sessions.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Users.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 12,
  initComponent : function() {
    var username905 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajanimi", "listeners": { "render": Lino.quicktip_renderer("Kasutajanimi","(users.Users.username) ") }, "maxLength": 30, "name": "username", "selectOnFocus": true });
    var email906 = 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_panel907 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": username905, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": email906, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var first_name910 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("Eesnimi","(users.Users.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name911 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Perenimi","(users.Users.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var main_2_panel912 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": first_name910, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": last_name911, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var language915 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(users.Users.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var profile916 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajaliik", "forceSelection": true, "hiddenName": "profileHidden", "listeners": { "render": Lino.quicktip_renderer("Kasutajaliik","(users.Users.profile) ") }, "name": "profile", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var main_4_panel917 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 44, "items": language915, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 55, "items": profile916, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel920 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel907, main_2_panel912, main_4_panel917 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel920;
    this.before_row_edit = function(record) {
    }
    Lino.users.Users.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Events.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 18,
  initComponent : function() {
    var start_date609 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(cal.Events.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var start_time610 = 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_date611 = 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_time612 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00f5peb (aeg)</span>", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (aeg)","(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_panel613 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": start_date609, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_time610, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": end_date611, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_time612, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var summary618 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00fchikirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("L\u00fchikirjeldus","(cal.Events.summary) A one-line descriptive text.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var main_panel619 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel613, { "anchor": "-20", "autoHeight": true, "items": summary618, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "form" });
    this.items = main_panel619;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Events.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.UploadTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 60,
  initComponent : function() {
    var id921 = 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_area922 = 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 wanted923 = 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_number924 = 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 shortcut925 = 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_panel926 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 9, "items": id921, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": upload_area922, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": wanted923, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": max_number924, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 41, "items": shortcut925, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name932 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(uploads.UploadTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et933 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(uploads.UploadTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel934 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name932, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et933, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel977 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel926, main_2_panel934 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel977;
    this.before_row_edit = function(record) {
    }
    Lino.uploads.UploadTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.Votes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 34,
  initComponent : function() {
    var user978 = 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("S\u00f5nav\u00f5tja","(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 votable979 = 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("Lipik","(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_panel980 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": user978, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": votable979, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var mail_mode983 = 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 priority984 = 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 nickname985 = 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_panel986 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": priority984, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 80, "items": nickname985, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var state989 = 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("Staatus","(votes.Votes.state) The state of this vote.  Pointer to VoteStates.") }, "name": "state", "selectOnFocus": true, "store": Lino.votes.VoteStates });
    var rating990 = 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_panel991 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel980, { "anchor": "-20", "autoHeight": true, "items": mail_mode983, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_4_panel986, { "anchor": "-20", "autoHeight": true, "items": state989, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": rating990, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel991;
    this.before_row_edit = function(record) {
    }
    Lino.votes.Votes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.Deployments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 49,
  initComponent : function() {
    var milestone654 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "milestoneHidden", "listeners": { "render": Lino.quicktip_renderer("Tegevus","(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 ticket655 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(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 remark656 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "M\u00e4rkus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(deploy.Deployments.remark) ") }, "name": "remark", "selectOnFocus": true });
    var main_panel657 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "items": milestone654, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "items": ticket655, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "flex": 71, "items": remark656, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel657;
    this.before_row_edit = function(record) {
    }
    Lino.deploy.Deployments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.MyVotes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 34,
  initComponent : function() {
    var user995 = 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("S\u00f5nav\u00f5tja","(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_disp996 = 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_mode997 = 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 priority998 = 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 nickname999 = 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_panel1000 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": priority998, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 80, "items": nickname999, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1003 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ user995, { "anchor": "-20", "autoHeight": true, "items": workflow_buttons_disp996, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": mail_mode997, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_4_panel1000 ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel1003;
    this.before_row_edit = function(record) {
    }
    Lino.votes.MyVotes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.DeploymentsByMilestone.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 49,
  initComponent : function() {
    var ticket661 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(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 remark662 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "M\u00e4rkus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(deploy.DeploymentsByMilestone.remark) ") }, "name": "remark", "selectOnFocus": true });
    var main_panel663 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "items": ticket661, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "flex": 83, "items": remark662, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel663;
    this.before_row_edit = function(record) {
    }
    Lino.deploy.DeploymentsByMilestone.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.deploy.DeploymentsByTicket.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 49,
  initComponent : function() {
    var milestone1006 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "milestoneHidden", "listeners": { "render": Lino.quicktip_renderer("Tegevus","(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_type1007 = 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_panel1008 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 57, "items": milestone1006, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 42, "items": wish_type1007, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remark1011 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "M\u00e4rkus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(deploy.DeploymentsByTicket.remark) ") }, "name": "remark", "selectOnFocus": true });
    var main_panel1012 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1008, { "flex": 83, "items": remark1011, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1012;
    this.before_row_edit = function(record) {
    }
    Lino.deploy.DeploymentsByTicket.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.EventTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 17,
  initComponent : function() {
    var name1014 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.EventTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1015 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.EventTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1016 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1014, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1015, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var event_label1019 = 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_et1020 = 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_panel1021 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": event_label1019, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": event_label_et1020, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1024 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1016, main_2_panel1021 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1024;
    this.before_row_edit = function(record) {
    }
    Lino.cal.EventTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Links.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 41,
  initComponent : function() {
    var parent1025 = 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 type1026 = 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 child1027 = 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_panel1028 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": parent1025, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": type1026, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": child1027, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "form" });
    this.items = main_panel1028;
    this.before_row_edit = function(record) {
    }
    Lino.tickets.Links.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.RecurrentEvents.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 16,
  initComponent : function() {
    var name1032 = 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("Nimetus","(cal.RecurrentEvents.name) See lino.utils.mldbc.mixins.BabelNamed.name.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1033 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.RecurrentEvents.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1034 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1032, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1033, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id1037 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.RecurrentEvents.id) ") }, "name": "id", "selectOnFocus": true });
    var user1038 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_type1039 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "S\u00fcndmuseliik", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("S\u00fcndmuseliik","(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_panel1040 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 11, "items": id1037, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": user1038, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": event_type1039, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date1044 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(cal.RecurrentEvents.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var start_time1045 = 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_date1046 = 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_time1047 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (aeg)","(cal.RecurrentEvents.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var main_3_panel1048 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": start_date1044, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": start_time1045, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": end_date1046, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_time1047, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var every_unit1053 = 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("Korduvus","(cal.RecurrentEvents.every_unit) Inherited from RecurrentSet.every_unit.") }, "name": "every_unit", "selectOnFocus": true, "store": Lino.cal.Recurrencies });
    var every1054 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Korda iga","(cal.RecurrentEvents.every) ") }, "name": "every", "selectOnFocus": true, "value": 1 });
    var max_events1055 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "S\u00fcndmuste arv", "listeners": { "render": Lino.quicktip_renderer("S\u00fcndmuste arv","(cal.RecurrentEvents.max_events) ") }, "name": "max_events", "selectOnFocus": true });
    var main_4_panel1056 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 67, "items": every_unit1053, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": every1054, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": max_events1055, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var monday1060 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "esmasp\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("esmasp\u00e4ev","(cal.RecurrentEvents.monday) ") }, "name": "monday", "selectOnFocus": true });
    var tuesday1061 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "teisip\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("teisip\u00e4ev","(cal.RecurrentEvents.tuesday) ") }, "name": "tuesday", "selectOnFocus": true });
    var wednesday1062 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "kolmap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("kolmap\u00e4ev","(cal.RecurrentEvents.wednesday) ") }, "name": "wednesday", "selectOnFocus": true });
    var thursday1063 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "neljap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("neljap\u00e4ev","(cal.RecurrentEvents.thursday) ") }, "name": "thursday", "selectOnFocus": true });
    var friday1064 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "reede", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("reede","(cal.RecurrentEvents.friday) ") }, "name": "friday", "selectOnFocus": true });
    var saturday1065 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "laup\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("laup\u00e4ev","(cal.RecurrentEvents.saturday) ") }, "name": "saturday", "selectOnFocus": true });
    var sunday1066 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "p\u00fchap\u00e4ev", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("p\u00fchap\u00e4ev","(cal.RecurrentEvents.sunday) ") }, "name": "sunday", "selectOnFocus": true });
    var main_5_panel1067 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 14, "items": monday1060, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": tuesday1061, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": wednesday1062, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": thursday1063, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": friday1064, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": saturday1065, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": sunday1066, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1075 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 66, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_6_panel1077 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description1075 ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel1078 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1034, main_2_panel1040, main_3_panel1048, main_4_panel1056, main_5_panel1067, main_6_panel1077 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1078;
    this.before_row_edit = function(record) {
      description1075.refresh();
    }
    Lino.cal.RecurrentEvents.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Lines.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 28,
  initComponent : function() {
    var name1079 = 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("Nimetus","(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_et1080 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(courses.Lines.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1081 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1079, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1080, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var ref1084 = 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 topic1085 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Teema","(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_panel1086 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": ref1084, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": topic1085, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var every_unit1089 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Korduvus", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Korduvus","(courses.Lines.every_unit) ") }, "name": "every_unit", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every1090 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Korda iga","(courses.Lines.every) ") }, "name": "every", "selectOnFocus": true, "value": 1 });
    var event_type1091 = 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("S\u00fcndmuseliik","(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_panel1092 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 45, "items": every_unit1089, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": every1090, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": event_type1091, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1096 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et1097 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var main_4_panel1098 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ description1096, description_et1097 ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel1099 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1081, main_2_panel1086, main_3_panel1092, main_4_panel1098 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1099;
    this.before_row_edit = function(record) {
      description1096.refresh();
      description_et1097.refresh();
    }
    Lino.courses.Lines.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Guests.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 20,
  initComponent : function() {
    var event585 = 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 partner586 = 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 role587 = 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_panel588 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": event585, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": partner586, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": role587, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var state592 = 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("Staatus","(cal.Guests.state) The state of this presence.") }, "name": "state", "selectOnFocus": true, "store": Lino.cal.GuestStates });
    var remark593 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(cal.Guests.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var workflow_buttons_disp594 = 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_panel595 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": state592, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": remark593, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 49, "items": workflow_buttons_disp594, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel599 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel588, main_2_panel595 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel599;
    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: 22,
  initComponent : function() {
    var id1100 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.GuestRoles.id) ") }, "name": "id", "selectOnFocus": true });
    var name1101 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.GuestRoles.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1102 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.GuestRoles.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1103 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1100, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1101, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1102, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1119 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1103 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1119;
    this.before_row_edit = function(record) {
    }
    Lino.cal.GuestRoles.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.VotesByVotable.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 34,
  initComponent : function() {
    var mail_mode1120 = 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_disp1121 = 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 rating1122 = 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_panel1123 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": mail_mode1120, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": workflow_buttons_disp1121, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": rating1122, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel1123;
    this.before_row_edit = function(record) {
    }
    Lino.votes.VotesByVotable.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.mailbox.Mailboxes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 66,
  initComponent : function() {
    var name1127 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Nimi","(mailbox.Mailboxes.name) ") }, "maxLength": 255, "name": "name", "selectOnFocus": true });
    var uri1128 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">URI</span>", "listeners": { "render": Lino.quicktip_renderer("URI","(mailbox.Mailboxes.uri) Example: imap+ssl://myusername:mypassword@someserver <br /><br />Internet transports include 'imap' and 'pop3'; common local file transports include 'maildir', 'mbox', and less commonly 'babyl', 'mh', and 'mmdf'. <br /><br />Be sure to urlencode your username and password should they contain illegal characters (like @, :, etc).") }, "maxLength": 255, "name": "uri", "selectOnFocus": true, "value": "" });
    var from_email1129 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">From email</span>", "listeners": { "render": Lino.quicktip_renderer("From email","(mailbox.Mailboxes.from_email) Example: MailBot &lt;mailbot@yourdomain.com&gt;<br />'From' header to set for outgoing email.<br /><br />If you do not use this e-mail inbox for outgoing mail, this setting is unnecessary.<br />If you send e-mail without setting this, your 'From' header will'be set to match the setting `DEFAULT_FROM_EMAIL`.") }, "maxLength": 255, "name": "from_email", "selectOnFocus": true, "value": "" });
    var main_1_panel1130 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": name1127, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": uri1128, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": from_email1129, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1155 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1130 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1155;
    this.before_row_edit = function(record) {
    }
    Lino.mailbox.Mailboxes.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_htmlbox1156 = 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_panel1157 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ body_htmlbox1156 ], "labelAlign": "top", "labelWidth": 0, "layout": "fit" });
    this.items = main_panel1157;
    this.before_row_edit = function(record) {
      body_htmlbox1156.refresh();
    }
    Lino.courses.StatusReport.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.SkillTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 47,
  initComponent : function() {
    var id1158 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(faculties.SkillTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name1159 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(faculties.SkillTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1160 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(faculties.SkillTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1161 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1158, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1159, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1160, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1286 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1161 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1286;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.SkillTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Guests.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 20,
  initComponent : function() {
    var event600 = 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 partner601 = 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 role602 = 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_panel603 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": event600, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": partner601, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": role602, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "form" });
    this.items = main_panel603;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Guests.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.topics.TopicGroups.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 31,
  initComponent : function() {
    var id1287 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(topics.TopicGroups.id) ") }, "name": "id", "selectOnFocus": true });
    var name1288 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(topics.TopicGroups.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1289 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(topics.TopicGroups.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1290 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1287, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1288, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1289, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var description1294 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 5, "name": "description", "region": "center", "selectOnFocus": true, "split": true, "title": "Kirjeldus" });
    var main_panel1569 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1290, description1294 ], "labelAlign": "top", "labelWidth": 90 });
    this.items = main_panel1569;
    this.before_row_edit = function(record) {
      description1294.refresh();
    }
    Lino.topics.TopicGroups.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.votes.VotesByVotable.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 34,
  initComponent : function() {
    var user1570 = 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("S\u00f5nav\u00f5tja","(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_mode1571 = 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_disp1572 = 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_panel1573 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": user1570, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": mail_mode1571, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": workflow_buttons_disp1572, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "form" });
    this.items = main_panel1573;
    this.before_row_edit = function(record) {
    }
    Lino.votes.VotesByVotable.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Offers.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 46,
  initComponent : function() {
    var user1236 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Kasutaja","(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_user1237 = 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_panel1238 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": user1236, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": end_user1237, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var faculty1241 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "facultyHidden", "listeners": { "render": Lino.quicktip_renderer("Oskus","(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 affinity1242 = 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_panel1243 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 80, "items": faculty1241, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": affinity1242, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1246 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 71, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_panel1247 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1238, main_2_panel1243, description1246 ], "labelAlign": "top", "labelWidth": 90, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1247;
    this.before_row_edit = function(record) {
      description1246.refresh();
    }
    Lino.faculties.Offers.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.system.SiteConfigs.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 1,
  initComponent : function() {
    var site_company1577 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "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_id1578 = 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_method1579 = 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_panel1580 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 37, "items": site_company1577, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": next_partner_id1578, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": default_build_method1579, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 189, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var site_calendar1584 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kalender...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Site Calendar</span>", "hiddenName": "site_calendarHidden", "listeners": { "render": Lino.quicktip_renderer("Site Calendar","(system.SiteConfigs.site_calendar) The default calendar of this site.") }, "name": "site_calendar", "onTrigger2Click": function(e){ Lino.show_fk_detail(this,Lino.cal.Calendars.detail,Lino.cal.Calendars.insert)}, "pageSize": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/system/SiteConfigs/site_calendar" }) }) });
    var simulate_today1585 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Simulated date</span>", "listeners": { "render": Lino.quicktip_renderer("Simulated date","(system.SiteConfigs.simulate_today) A constant user-defined date to be substituted as current\nsystem date.") }, "name": "simulate_today", "selectOnFocus": true });
    var hide_events_before1586 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Hide events before</span>", "listeners": { "render": Lino.quicktip_renderer("Hide events before","(system.SiteConfigs.hide_events_before) If this is specified, certain tables show only \nevents after the given date.") }, "name": "hide_events_before", "selectOnFocus": true });
    var main_2_panel1587 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 43, "items": site_calendar1584, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": simulate_today1585, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": hide_events_before1586, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 171, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var default_event_type1591 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Default Event Type</span>", "hiddenName": "default_event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Default Event Type","(system.SiteConfigs.default_event_type) The default type of events on this site.") }, "name": "default_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/system/SiteConfigs/default_event_type" }) }) });
    var max_auto_events1592 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Max automatic events</span>", "listeners": { "render": Lino.quicktip_renderer("Max automatic events","(system.SiteConfigs.max_auto_events) Maximum number of automatic events to be generated.") }, "name": "max_auto_events", "selectOnFocus": true, "value": 72 });
    var main_3_panel1593 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 80, "items": default_event_type1591, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": max_auto_events1592, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 189, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1596 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1580, main_2_panel1587, main_3_panel1593 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1596;
    this.before_row_edit = function(record) {
    }
    Lino.system.SiteConfigs.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.RecurrentEvents.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 16,
  initComponent : function() {
    var name1597 = 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("Nimetus","(cal.RecurrentEvents.name) See lino.utils.mldbc.mixins.BabelNamed.name.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1598 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.RecurrentEvents.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1599 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1597, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1598, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date1602 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(cal.RecurrentEvents.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date1603 = 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_unit1604 = 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("Korduvus","(cal.RecurrentEvents.every_unit) Inherited from RecurrentSet.every_unit.") }, "name": "every_unit", "selectOnFocus": true, "store": Lino.cal.Recurrencies });
    var event_type1605 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni S\u00fcndmuseliik...", "fieldLabel": "S\u00fcndmuseliik", "hiddenName": "event_typeHidden", "listeners": { "render": Lino.quicktip_renderer("S\u00fcndmuseliik","(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_panel1606 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": start_date1602, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date1603, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": every_unit1604, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 29, "items": event_type1605, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1611 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1599, main_2_panel1606 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel1611;
    this.before_row_edit = function(record) {
    }
    Lino.cal.RecurrentEvents.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.EntryTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 57,
  initComponent : function() {
    var id1612 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(blogs.EntryTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name1613 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(blogs.EntryTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1614 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(blogs.EntryTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1615 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1612, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1613, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1614, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var remark1619 = 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_grid1640 = 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_panel1641 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1615, remark1619, blogs_EntriesByType_grid1640 ], "labelAlign": "top", "labelWidth": 63 });
    this.items = main_panel1641;
    this.before_row_edit = function(record) {
      remark1619.refresh();
      blogs_EntriesByType_grid1640.on_master_changed();
    }
    Lino.blogs.EntryTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.EnrolmentsByPupil.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 29,
  initComponent : function() {
    var course1642 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Tegevus...", "fieldLabel": "Tegevus", "hiddenName": "courseHidden", "listeners": { "render": Lino.quicktip_renderer("Tegevus","(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 remark1643 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(courses.EnrolmentsByPupil.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var request_date1644 = 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 user1645 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_panel1646 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": request_date1644, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 60, "items": user1645, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1649 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": course1642, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": remark1643, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel1646 ], "labelAlign": "top", "labelWidth": 72, "layout": "form" });
    this.items = main_panel1649;
    this.before_row_edit = function(record) {
      course1642.setContextValue('course_area', record ? record.data['course_areaHidden'] : undefined);
      course1642.setContextValue('request_date', record ? record.data['request_date'] : undefined);
    }
    this.onRender = function(ct, position) {
      request_date1644.on('change',Lino.chooser_handler(course1642,'request_date'));
      Lino.courses.EnrolmentsByPupil.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.EnrolmentsByPupil.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Demands.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 45,
  initComponent : function() {
    var demander1257 = 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 skill1258 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Oskus","(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 importance1259 = 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 id1260 = 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_panel1261 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": importance1259, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": id1260, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1264 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": demander1257, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": skill1258, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel1261 ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel1264;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.Demands.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Tickets.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 42,
  initComponent : function() {
    var summary1352 = 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 id1353 = 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_panel1354 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 86, "items": summary1352, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": id1353, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user1357 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_user1358 = 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 deadline1359 = 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_panel1360 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 32, "items": user1357, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": end_user1358, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 35, "items": deadline1359, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var site1364 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "siteHidden", "listeners": { "render": Lino.quicktip_renderer("Ruum","(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 topic1365 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Teema","(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 project1366 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Eesm\u00e4rk...", "fieldLabel": "Eesm\u00e4rk", "hiddenName": "projectHidden", "listeners": { "render": Lino.quicktip_renderer("Eesm\u00e4rk","(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_panel1367 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": site1364, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": topic1365, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": project1366, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var workflow_buttons_disp1371 = 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 private1372 = 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_panel1373 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 75, "items": workflow_buttons_disp1371, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": private1372, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var general1_panel1383 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "flex": 66, "frame": true, "hideCheckBoxLabels": true, "items": [ general1_1_panel1354, general1_2_panel1360, general1_3_panel1367, general1_4_panel1373 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    var general_1_panel1385 = new Ext.Panel({ "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ general1_panel1383 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var created1386 = 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("Loodud","(tickets.Tickets.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified1387 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Muudatud","(tickets.Tickets.modified) ") }, "name": "modified", "value": "<br>" });
    var reported_for1388 = 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_type1389 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipikuliik...", "fieldLabel": "Lipikuliik", "hiddenName": "ticket_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Lipikuliik","(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_panel1390 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": created1386, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": modified1387, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": reported_for1388, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": ticket_type1389, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var state1395 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Staatus", "forceSelection": true, "hiddenName": "stateHidden", "listeners": { "render": Lino.quicktip_renderer("Staatus","(tickets.Tickets.state) ") }, "name": "state", "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var duplicate_of1396 = 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_time1397 = 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 priority1398 = 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_panel1399 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": state1395, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 45, "items": duplicate_of1396, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": planned_time1397, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": priority1398, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var more1_panel1404 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 75, "frame": true, "hideCheckBoxLabels": true, "items": [ more1_1_panel1390, more1_2_panel1399 ], "labelAlign": "top", "layout": "form" });
    var DuplicatesByTicket_grid1538 = new Lino.tickets.DuplicatesByTicket.GridPanel({ "containing_panel": this, "flex": 24, "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_panel1539 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ more1_panel1404, DuplicatesByTicket_grid1538 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1540 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 42, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes1541 = 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 more_2_panel1543 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description1540, { "flex": 28, "items": upgrade_notes1541, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var more_panel1545 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel1539, more_2_panel1543 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel1548 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel1385, more_panel1545 ], "labelAlign": "top", "split": true });
    this.items = main_panel1548;
    this.before_row_edit = function(record) {
      reported_for1388.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      DuplicatesByTicket_grid1538.on_master_changed();
      description1540.refresh();
    }
    this.onRender = function(ct, position) {
      site1364.on('change',Lino.chooser_handler(reported_for1388,'site'));
      Lino.tickets.Tickets.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.tickets.Tickets.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.CommentTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 38,
  initComponent : function() {
    var name1652 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(comments.CommentTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1653 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(comments.CommentTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1654 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1652, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1653, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id1657 = 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_panel1658 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1654, { "anchor": "-20", "autoHeight": true, "items": id1657, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 27, "layout": "form" });
    this.items = main_panel1658;
    this.before_row_edit = function(record) {
    }
    Lino.comments.CommentTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


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


Lino.mailbox.Mailboxes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 66,
  initComponent : function() {
    var name1671 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Nimi","(mailbox.Mailboxes.name) ") }, "maxLength": 255, "name": "name", "selectOnFocus": true });
    var uri1672 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">URI</span>", "listeners": { "render": Lino.quicktip_renderer("URI","(mailbox.Mailboxes.uri) Example: imap+ssl://myusername:mypassword@someserver <br /><br />Internet transports include 'imap' and 'pop3'; common local file transports include 'maildir', 'mbox', and less commonly 'babyl', 'mh', and 'mmdf'. <br /><br />Be sure to urlencode your username and password should they contain illegal characters (like @, :, etc).") }, "maxLength": 255, "name": "uri", "selectOnFocus": true, "value": "" });
    var from_email1673 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">From email</span>", "listeners": { "render": Lino.quicktip_renderer("From email","(mailbox.Mailboxes.from_email) Example: MailBot &lt;mailbot@yourdomain.com&gt;<br />'From' header to set for outgoing email.<br /><br />If you do not use this e-mail inbox for outgoing mail, this setting is unnecessary.<br />If you send e-mail without setting this, your 'From' header will'be set to match the setting `DEFAULT_FROM_EMAIL`.") }, "maxLength": 255, "name": "from_email", "selectOnFocus": true, "value": "" });
    var active1674 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Active", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Active","(mailbox.Mailboxes.active) Check this e-mail inbox for new e-mail messages during polling cycles.  This checkbox does not have an effect upon whether mail is collected here when this mailbox receives mail from a pipe, and does not affect whether e-mail messages can be dispatched from this mailbox. ") }, "name": "active", "selectOnFocus": true });
    var main_panel1675 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name1671, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": uri1672, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": from_email1673, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": active1674, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "form" });
    this.items = main_panel1675;
    this.before_row_edit = function(record) {
    }
    Lino.mailbox.Mailboxes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.topics.Topics.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 32,
  initComponent : function() {
    var topic_group1560 = 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 name1561 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(topics.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1562 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(topics.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel1563 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1561, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1562, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1566 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": topic_group1560, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel1563 ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel1566;
    this.before_row_edit = function(record) {
    }
    Lino.topics.Topics.InsertFormPanel.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_disp1681 = 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_panel1682 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "flex": 25, "html": "<div class=\"htmlText\"><span>See on <a href=\"http://noi.lino-framework.org/\" target=\"_blank\">Lino Noi</a> 2017.2.0 kasutades <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, <a href=\"http://appyframework.org/pod.html\" target=\"_blank\">Appy</a> 0.9.5 (2017/03/01 08:14), <a href=\"https://github.com/CylonOven/django-mailbox\" target=\"_blank\">django_mailbox</a> 4.5.4</span><p>Keeled: en, et</p><p>Server uptime : <b>11.04.17 at 19:33</b> (UTC)</p><p>Tere tulemast selle Lino demo saidile.</p><p>We are running with simulated date set to neljap&#228;ev, 16. m&#228;rts 2017.</p><p>Source timestamps:</p><ul><li>rest_framework : <b>09.03.17 at 05:39</b></li><li>atelier : <b>15.03.17 at 16:14</b></li><li>django_mailbox : <b>03.04.17 at 07:22</b></li><li>django : <b>10.04.17 at 02:48</b></li><li>lino_noi : <b>11.04.17 at 15:40</b></li><li>lino : <b>11.04.17 at 18:47</b></li><li>lino_xl : <b>11.04.17 at 19:30</b></li></ul></div>", "xtype": "label" }, { "autoHeight": true, "items": server_status_disp1681, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1682;
    this.before_row_edit = function(record) {
    }
    Lino.about.About.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.Comments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 37,
  initComponent : function() {
    var id1684 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(comments.Comments.id) ") }, "name": "id", "selectOnFocus": true });
    var user1685 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "disabled": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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 created1686 = 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("Loodud","(comments.Comments.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified1687 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Muudatud","(comments.Comments.modified) ") }, "name": "modified", "value": "<br>" });
    var main_1_panel1688 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 8, "items": id1684, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 35, "items": user1685, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": created1686, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": modified1687, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var reply_to1693 = 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 owner1694 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ownerHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(comments.Comments.owner) ") }, "name": "owner", "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/comments/Comments/owner" }) }) });
    var comment_type1695 = 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_panel1696 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": reply_to1693, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": owner1694, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": comment_type1695, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var short_text1700 = 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_panel1701 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1688, main_2_panel1696, short_text1700 ], "labelAlign": "top", "labelWidth": 99, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1701;
    this.before_row_edit = function(record) {
      short_text1700.refresh();
    }
    Lino.comments.Comments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Events.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 18,
  initComponent : function() {
    var event_type542 = 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("S\u00fcndmuseliik","(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 summary543 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00fchikirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("L\u00fchikirjeldus","(cal.Events.summary) A one-line descriptive text.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var id544 = 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_panel545 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 23, "items": event_type542, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 70, "items": summary543, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 5, "items": id544, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date549 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(cal.Events.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var start_time550 = 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_panel551 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "flex": 38, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": start_date549, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": start_time550, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var end_date554 = 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_time555 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00f5peb (aeg)</span>", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (aeg)","(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_panel556 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "flex": 38, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": end_date554, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": end_time555, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var access_class559 = 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_panel560 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ start_panel551, end_panel556, { "autoHeight": true, "flex": 22, "items": access_class559, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user562 = 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("Autor","(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 room563 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Ruum...", "fieldLabel": "Ruum", "hiddenName": "roomHidden", "listeners": { "render": Lino.quicktip_renderer("Ruum","(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 company564 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "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_person565 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kontaktisik</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Kontaktisik","(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_panel566 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": user562, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": room563, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": company564, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": contact_person565, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var owner_disp571 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var workflow_buttons_disp572 = 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_panel573 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 25, "items": owner_disp571, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 75, "items": workflow_buttons_disp572, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description576 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(cal.Events.description) A longer descriptive text.") }, "name": "description", "selectOnFocus": true });
    var blogs_EntriesByController_htmlbox577 = 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_panel578 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 45, "frame": false, "hideCheckBoxLabels": true, "items": [ { "flex": 66, "items": description576, "labelAlign": "top", "layout": "form", "xtype": "panel" }, blogs_EntriesByController_htmlbox577 ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var general_panel580 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel545, general_2_panel560, general_3_panel566, general_4_panel573, general_5_panel578 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var main_panel608 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel580 ], "labelAlign": "top", "split": true });
    this.items = main_panel608;
    this.before_row_edit = function(record) {
      contact_person565.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      blogs_EntriesByController_htmlbox577.refresh();
    }
    this.onRender = function(ct, position) {
      company564.on('change',Lino.chooser_handler(contact_person565,'company'));
      Lino.cal.Events.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.cal.Events.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.EnrolmentsByCourse.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 29,
  initComponent : function() {
    var pupil1702 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "Person", "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 remark1703 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "M\u00e4rkus", "listeners": { "render": Lino.quicktip_renderer("M\u00e4rkus","(courses.EnrolmentsByCourse.remark) ") }, "maxLength": 200, "name": "remark", "selectOnFocus": true });
    var request_date1704 = 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 user1705 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_panel1706 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 39, "items": request_date1704, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 60, "items": user1705, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel1709 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": pupil1702, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": remark1703, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_3_panel1706 ], "labelAlign": "top", "labelWidth": 63, "layout": "form" });
    this.items = main_panel1709;
    this.before_row_edit = function(record) {
      var bp = this.get_base_params();
      pupil1702.setContextValue('mk',bp['mk']);
      pupil1702.setContextValue('mt',bp['mt']);
    }
    Lino.courses.EnrolmentsByCourse.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Skills.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 48,
  initComponent : function() {
    var name1270 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(faculties.Skills.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1271 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(faculties.Skills.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1272 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name1270, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et1271, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var parent1275 = 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_panel1276 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1272, { "anchor": "-20", "autoHeight": true, "items": parent1275, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "form" });
    this.items = main_panel1276;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.Skills.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Persons.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 8,
  initComponent : function() {
    var overview_disp1712 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Kirjeldus", "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(contacts.Persons.overview) ") }, "name": "overview", "value": "<br/>" });
    var id1713 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(contacts.Persons.id) ") }, "name": "id", "selectOnFocus": true });
    var language1714 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(contacts.Persons.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var email1715 = 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 info_box_panel1716 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 57, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": id1713, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": language1714, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": email1715, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "form" });
    var general_1_panel1720 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 42, "items": overview_disp1712, "labelAlign": "top", "layout": "form", "xtype": "panel" }, info_box_panel1716 ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var general_panel1731 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel1720 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var last_name1732 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Perenimi","(contacts.Persons.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var first_name1733 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("Eesnimi","(contacts.Persons.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var gender1734 = 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("Sugu","(contacts.Persons.gender) The sex of this person (male or female).") }, "name": "gender", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var name_box_panel1735 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 46, "items": last_name1732, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": first_name1733, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": gender1734, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var country1739 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Riik","(contacts.Persons.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/Persons/country" }) }) });
    var city1740 = 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("Linn","(contacts.Persons.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/Persons/city" }) }) });
    var zip_code1741 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "Zip code", "listeners": { "render": Lino.quicktip_renderer("Zip code","(contacts.Persons.zip_code) ") }, "maxLength": 10, "name": "zip_code", "selectOnFocus": true });
    var address_box_2_panel1742 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": country1739, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": city1740, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code1741, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street1746 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Street</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(contacts.Persons.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no1747 = 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("Nr.","(contacts.Persons.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box1748 = 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.Persons.street_box) Text to print after street nuber on the same line.") }, "maxLength": 10, "name": "street_box", "selectOnFocus": true });
    var address_box_4_panel1749 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": street1746, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_no1747, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_box1748, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_box_panel1753 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 66, "frame": true, "hideCheckBoxLabels": true, "items": [ name_box_panel1735, address_box_2_panel1742, address_box_4_panel1749 ], "labelAlign": "top", "layout": "form", "title": "Aadres" });
    var url1754 = 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 phone1755 = 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 gsm1756 = 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 contact_box_panel1757 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 33, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": url1754, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": phone1755, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": gsm1756, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "form", "title": "Contact" });
    var contact_1_panel1761 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ address_box_panel1753, contact_box_panel1757 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks1762 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 33, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var contact_2_panel1771 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ remarks1762 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var contact_panel1772 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ contact_1_panel1761, contact_2_panel1771 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Contact" });
    var tickets_TicketsByEndUser_grid1852 = new Lino.tickets.TicketsByEndUser.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Lipikud","(tickets.tickets.TicketsByEndUser) Global list of all tickets.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.TicketsByEndUser.grid) ] });
    var tickets_1_panel2006 = new Ext.Panel({ "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ tickets_TicketsByEndUser_grid1852 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Lipikud" });
    var main_panel2007 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel1731, contact_panel1772, tickets_1_panel2006 ], "labelAlign": "top", "split": true });
    this.items = main_panel2007;
    this.before_row_edit = function(record) {
      city1740.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city1740.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      remarks1762.refresh();
      tickets_TicketsByEndUser_grid1852.on_master_changed();
    }
    this.onRender = function(ct, position) {
      country1739.on('change',Lino.chooser_handler(city1740,'country'));
      Lino.contacts.Persons.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.contacts.Persons.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city1740.on("change", function(){ this.save() }, this);
    zip_code1741.on("change", function(){ this.save() }, this);
  }
});


Lino.countries.Countries.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 4,
  initComponent : function() {
    var isocode2008 = 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 name2009 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(countries.Countries.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2010 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(countries.Countries.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var short_code2011 = 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_panel2012 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": isocode2008, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": name2009, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": name_et2010, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": short_code2011, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2030 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2012 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2030;
    this.before_row_edit = function(record) {
    }
    Lino.countries.Countries.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.DemandsByDemander.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 45,
  initComponent : function() {
    var skill2031 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskus...", "fieldLabel": "Oskus", "hiddenName": "skillHidden", "listeners": { "render": Lino.quicktip_renderer("Oskus","(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 importance2032 = 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_panel2033 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": skill2031, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": importance2032, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "form" });
    this.items = main_panel2033;
    this.before_row_edit = function(record) {
    }
    Lino.faculties.DemandsByDemander.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.Uploads.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 61,
  initComponent : function() {
    var file952 = Lino.file_field_handler(this,{ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Fail</span>", "listeners": { "render": Lino.quicktip_renderer("Fail","(uploads.Uploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file") }, "maxLength": 100, "name": "file", "selectOnFocus": true });
    var user953 = 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_panel954 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": file952, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": user953, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var upload_area957 = 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 type958 = 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 description959 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(uploads.Uploads.description) A short description entered manually by the user.") }, "maxLength": 200, "name": "description", "selectOnFocus": true });
    var main_2_panel960 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": upload_area957, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 39, "items": type958, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 41, "items": description959, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var owner_disp964 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var main_panel965 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel954, main_2_panel960, { "anchor": "-20", "autoHeight": true, "items": owner_disp964, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "form" });
    this.items = main_panel965;
    this.before_row_edit = function(record) {
      type958.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      upload_area957.on('change',Lino.chooser_handler(type958,'upload_area'));
      Lino.uploads.Uploads.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.uploads.Uploads.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.topics.Topics.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 32,
  initComponent : function() {
    var id1306 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(topics.Topics.id) ") }, "name": "id", "selectOnFocus": true });
    var ref1307 = 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 name1308 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(topics.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1309 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(topics.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var topic_group1310 = 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_panel1311 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 5, "items": id1306, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": ref1307, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": name1308, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": name_et1309, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 22, "items": topic_group1310, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var description1317 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Long description", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Long description" });
    var description_et1318 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Long description (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Long description (et)" });
    var main_2_panel1319 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 5, "frame": false, "hideCheckBoxLabels": true, "items": [ description1317, description_et1318 ], "labelAlign": "top", "labelWidth": 198, "layout": "hbox", "layoutConfig": { "align": "stretch" }, "region": "center", "split": true });
    var tickets_TicketsByTopic_grid1549 = new Lino.tickets.TicketsByTopic.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Lipikud","(tickets.tickets.TicketsByTopic) Global list of all tickets.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.TicketsByTopic.grid) ] });
    var main_3_panel1558 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 5, "frame": false, "hideCheckBoxLabels": true, "items": [ tickets_TicketsByTopic_grid1549 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretch" }, "region": "south", "split": true });
    var main_panel1559 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1311, main_2_panel1319, main_3_panel1558 ], "labelAlign": "top" });
    this.items = main_panel1559;
    this.before_row_edit = function(record) {
      description1317.refresh();
      description_et1318.refresh();
      tickets_TicketsByTopic_grid1549.on_master_changed();
    }
    Lino.topics.Topics.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Calendars.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 23,
  initComponent : function() {
    var name2036 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.Calendars.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2037 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.Calendars.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var color2038 = 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 id2039 = 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_panel2040 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": name2036, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": name_et2037, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": color2038, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 9, "items": id2039, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2045 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 33, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_2_panel2055 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 83, "frame": false, "hideCheckBoxLabels": true, "items": [ description2045 ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel2056 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2040, main_2_panel2055 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2056;
    this.before_row_edit = function(record) {
      description2045.refresh();
    }
    Lino.cal.Calendars.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Companies.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 7,
  initComponent : function() {
    var overview_disp2057 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Kirjeldus", "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(contacts.Companies.overview) ") }, "name": "overview", "value": "<br/>" });
    var id2058 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(contacts.Companies.id) ") }, "name": "id", "selectOnFocus": true });
    var language2059 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(contacts.Companies.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var email2060 = 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 info_box_panel2061 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 57, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": id2058, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": language2059, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": email2060, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "form" });
    var general_1_panel2065 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 42, "items": overview_disp2057, "labelAlign": "top", "layout": "form", "xtype": "panel" }, info_box_panel2061 ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var general_panel2076 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel2065 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var prefix2077 = 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 name2078 = 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("Nimi","(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 type2079 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization type...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organization type</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_panel2080 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": prefix2077, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": name2078, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 49, "items": type2079, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var country2084 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Riik","(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 city2085 = 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("Linn","(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_code2086 = 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_panel2087 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": country2084, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": city2085, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": zip_code2086, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street2091 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Street</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(contacts.Companies.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no2092 = 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("Nr.","(contacts.Companies.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var street_box2093 = 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_panel2094 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": street2091, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_no2092, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": street_box2093, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_box_panel2098 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 66, "frame": true, "hideCheckBoxLabels": true, "items": [ name_box_panel2080, address_box_2_panel2087, address_box_4_panel2094 ], "labelAlign": "top", "layout": "form", "title": "Aadres" });
    var url2099 = 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 phone2100 = 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 gsm2101 = 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 contact_box_panel2102 = new Ext.form.FieldSet({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 33, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": url2099, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": phone2100, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": gsm2101, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "form", "title": "Contact" });
    var contact_1_panel2106 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ address_box_panel2098, contact_box_panel2102 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks2107 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 62, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var contact_panel2108 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ contact_1_panel2106, remarks2107 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Contact" });
    var tickets_TicketsByEndUser_grid2112 = new Lino.tickets.TicketsByEndUser.GridPanel({ "containing_panel": this, "flex": 50, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Lipikud","(tickets.tickets.TicketsByEndUser) Global list of all tickets.") }, "master_panel": this, "params_panel_hidden": true, "preview_limit": 15, "tools": [ Lino.show_in_own_window_button(Lino.tickets.TicketsByEndUser.grid) ] });
    var tickets_1_panel2138 = new Ext.Panel({ "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ tickets_TicketsByEndUser_grid2112 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Lipikud" });
    var main_panel2139 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel2076, contact_panel2108, tickets_1_panel2138 ], "labelAlign": "top", "split": true });
    this.items = main_panel2139;
    this.before_row_edit = function(record) {
      city2085.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city2085.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      remarks2107.refresh();
      tickets_TicketsByEndUser_grid2112.on_master_changed();
    }
    this.onRender = function(ct, position) {
      country2084.on('change',Lino.chooser_handler(city2085,'country'));
      Lino.contacts.Companies.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.contacts.Companies.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city2085.on("change", function(){ this.save() }, this);
    zip_code2086.on("change", function(){ this.save() }, this);
  }
});


Lino.tinymce.TextFieldTemplates.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 62,
  initComponent : function() {
    var name2140 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(tinymce.TextFieldTemplates.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var user2141 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_panel2142 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name2140, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user2141, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "form" });
    this.items = main_panel2142;
    this.before_row_edit = function(record) {
    }
    Lino.tinymce.TextFieldTemplates.InsertFormPanel.superclass.initComponent.call(this);
  }
});


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


Lino.lists.Lists.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 55,
  initComponent : function() {
    var ref2153 = 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_type2154 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Listiliik...", "fieldLabel": "Listiliik", "hiddenName": "list_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Listiliik","(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_panel2155 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": ref2153, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": list_type2154, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2158 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(lists.Lists.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2159 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(lists.Lists.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel2160 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2158, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2159, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks2163 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 71, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_panel2164 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2155, main_2_panel2160, remarks2163 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2164;
    this.before_row_edit = function(record) {
      remarks2163.refresh();
    }
    Lino.lists.Lists.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.mailbox.MessageAttachments.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 65,
  disable_editing: true,
  initComponent : function() {
    var document464 = Lino.file_field_handler(this,{ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Document", "listeners": { "render": Lino.quicktip_renderer("Document","(mailbox.MessageAttachments.document) ") }, "maxLength": 100, "name": "document", "selectOnFocus": true });
    var headers465 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Headers", "flex": 83, "name": "headers", "selectOnFocus": true, "title": "Headers" });
    var main_panel466 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "items": document464, "labelAlign": "top", "layout": "form", "xtype": "panel" }, headers465 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel466;
    this.before_row_edit = function(record) {
      headers465.refresh();
    }
    Lino.mailbox.MessageAttachments.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Slots.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 26,
  initComponent : function() {
    var name2165 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Nimi","(courses.Slots.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var start_time2166 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (aeg)", "listeners": { "render": Lino.quicktip_renderer("Algab (aeg)","(courses.Slots.start_time) ") }, "name": "start_time", "selectOnFocus": true });
    var end_time2167 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (aeg)", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (aeg)","(courses.Slots.end_time) ") }, "name": "end_time", "selectOnFocus": true });
    var main_1_panel2168 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 56, "items": name2165, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": start_time2166, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": end_time2167, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2228 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2168 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2228;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Slots.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Topics.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 27,
  initComponent : function() {
    var id2229 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Topics.id) ") }, "name": "id", "selectOnFocus": true });
    var name2230 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(courses.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2231 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(courses.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2232 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2229, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2230, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2231, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var main_panel2343 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2232 ], "labelAlign": "top" });
    this.items = main_panel2343;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Topics.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Topics.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 27,
  initComponent : function() {
    var name2344 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(courses.Topics.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2345 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(courses.Topics.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2346 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2344, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2345, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var id2349 = 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_panel2350 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2346, { "anchor": "-20", "autoHeight": true, "items": id2349, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 27, "layout": "form" });
    this.items = main_panel2350;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Topics.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Tasks.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 14,
  initComponent : function() {
    var start_date2352 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(cal.Tasks.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var due_date2353 = 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 id2354 = 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_disp2355 = 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_panel2356 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": start_date2352, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": due_date2353, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": id2354, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 49, "items": workflow_buttons_disp2355, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var summary2361 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00fchikirjeldus", "listeners": { "render": Lino.quicktip_renderer("L\u00fchikirjeldus","(cal.Tasks.summary) ") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var user2362 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_disp2363 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Controlled by", "name": "owner" });
    var created2364 = 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("Loodud","(cal.Tasks.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified2365 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Muudatud","(cal.Tasks.modified) ") }, "name": "modified", "value": "<br>" });
    var main_4_panel2366 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 20, "items": owner_disp2363, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": created2364, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": modified2365, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2370 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "Kirjeldus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(cal.Tasks.description) ") }, "name": "description", "selectOnFocus": true });
    var main_panel2371 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2356, { "autoHeight": true, "items": summary2361, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "items": user2362, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_4_panel2366, { "flex": 45, "items": description2370, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2371;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Tasks.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.faculties.Skills.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 48,
  initComponent : function() {
    var id1179 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(faculties.Skills.id) ") }, "name": "id", "selectOnFocus": true });
    var name1180 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(faculties.Skills.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et1181 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(faculties.Skills.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel1182 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id1179, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name1180, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et1181, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var parent1186 = 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_type1187 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Oskuseliik...", "fieldLabel": "Oskuseliik", "hiddenName": "skill_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Oskuseliik","(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 affinity1188 = 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_panel1189 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 44, "items": parent1186, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": skill_type1187, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 11, "items": affinity1188, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks1279 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 50, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_3_panel1280 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 41, "frame": false, "hideCheckBoxLabels": true, "items": [ remarks1279 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel1284 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1182, main_2_panel1189, main_3_panel1280 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1284;
    this.before_row_edit = function(record) {
      remarks1279.refresh();
    }
    Lino.faculties.Skills.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.lists.Lists.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 55,
  initComponent : function() {
    var ref2375 = 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_type2376 = new Lino.RemoteComboFieldElement({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Listiliik...", "fieldLabel": "Listiliik", "hiddenName": "list_typeHidden", "listeners": { "render": Lino.quicktip_renderer("Listiliik","(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 id2377 = 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_panel2378 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 45, "items": ref2375, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": list_type2376, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": id2377, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2382 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(lists.Lists.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2383 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(lists.Lists.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel2384 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2382, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2383, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks2387 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 41, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var main_panel2399 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2378, main_2_panel2384, remarks2387 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2399;
    this.before_row_edit = function(record) {
      remarks2387.refresh();
    }
    Lino.lists.Lists.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.Sessions.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 51,
  initComponent : function() {
    var ticket2400 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "hiddenName": "ticketHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(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 user2401 = 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("T\u00f6\u00f6taja","(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 faculty2402 = 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("Oskus","(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_panel2403 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": ticket2400, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": user2401, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": faculty2402, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date2407 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Algab (p\u00e4ev)</span>", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(clocking.Sessions.start_date) The date when you started to work.") }, "name": "start_date", "selectOnFocus": true });
    var start_time2408 = 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_date2409 = 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_time2410 = new Lino.TimeField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">L\u00f5peb (aeg)</span>", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (aeg)","(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_time2411 = 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("Paus","(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 duration2412 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(6), "disabled": true, "fieldLabel": "Kestus", "listeners": { "render": Lino.quicktip_renderer("Kestus","(clocking.Sessions.duration) ") }, "maxLength": 6, "name": "duration" });
    var main_2_panel2413 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 23, "items": start_date2407, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": start_time2408, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": end_date2409, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": end_time2410, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": break_time2411, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": duration2412, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var summary2420 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kokkuv\u00f5te</span>", "listeners": { "render": Lino.quicktip_renderer("Kokkuv\u00f5te","(clocking.Sessions.summary) Summary of the session.") }, "maxLength": 200, "name": "summary", "selectOnFocus": true });
    var workflow_buttons_disp2421 = 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_panel2422 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 75, "items": summary2420, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": workflow_buttons_disp2421, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2425 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_panel2426 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2403, main_2_panel2413, main_3_panel2422, description2425 ], "labelAlign": "top", "labelWidth": 90, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2426;
    this.before_row_edit = function(record) {
      description2425.refresh();
    }
    Lino.clocking.Sessions.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.gfks.ContentTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 2,
  initComponent : function() {
    var id2427 = 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_label2428 = 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 model2429 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "pythoni mudeli klassinimi", "listeners": { "render": Lino.quicktip_renderer("pythoni mudeli klassinimi","(gfks.ContentTypes.model) ") }, "maxLength": 100, "name": "model", "selectOnFocus": true });
    var base_classes_disp2430 = 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_panel2431 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 6, "items": id2427, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": app_label2428, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 27, "items": model2429, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": base_classes_disp2430, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 234, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var main_panel2448 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2431 ], "labelAlign": "top" });
    this.items = main_panel2448;
    this.before_row_edit = function(record) {
    }
    Lino.gfks.ContentTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tinymce.TextFieldTemplates.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 62,
  initComponent : function() {
    var id2449 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tinymce.TextFieldTemplates.id) ") }, "name": "id", "selectOnFocus": true });
    var name2450 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(tinymce.TextFieldTemplates.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var user2451 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_panel2452 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2449, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 45, "items": name2450, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 43, "items": user2451, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "hbox", "layoutConfig": { "align": "stretchmax" }, "region": "north", "split": true });
    var description2456 = new Ext.form.TextArea({ "anchor": "-20 -10", "fieldLabel": "Kirjeldus", "growMax": 2000, "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(tinymce.TextFieldTemplates.description) ") }, "name": "description", "selectOnFocus": true });
    var text2457 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Template Text", "flex": 5, "name": "text", "region": "south", "selectOnFocus": true, "split": true, "title": "Template Text" });
    var main_panel2458 = new Lino.VBorderPanel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2452, { "flex": 5, "items": description2456, "labelAlign": "top", "layout": "form", "region": "center", "split": true, "xtype": "panel" }, text2457 ], "labelAlign": "top", "labelWidth": 126 });
    this.items = main_panel2458;
    this.before_row_edit = function(record) {
      text2457.refresh();
    }
    Lino.tinymce.TextFieldTemplates.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.about.Models.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  disable_editing: true,
  initComponent : function() {
    var app_disp2460 = 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_disp2461 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "nimi", "listeners": { "render": Lino.quicktip_renderer("nimi","(about.Models.name) ") }, "name": "name", "value": "<br/>" });
    var docstring_disp2462 = 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 rows2463 = 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_panel2464 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 31, "items": app_disp2460, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": name_disp2461, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": docstring_disp2462, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 5, "items": rows2463, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2474 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2464 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2474;
    this.before_row_edit = function(record) {
    }
    Lino.about.Models.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Rooms.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 15,
  initComponent : function() {
    var id2475 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Rooms.id) ") }, "name": "id", "selectOnFocus": true });
    var name2476 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.Rooms.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2477 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.Rooms.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2478 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2475, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2476, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2477, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2482 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "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_person2483 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kontaktisik</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Kontaktisik","(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_panel2484 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2482, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2483, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2487 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 41, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var main_panel2528 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2478, main_2_panel2484, description2487 ], "labelAlign": "top", "labelWidth": 90, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2528;
    this.before_row_edit = function(record) {
      contact_person2483.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2487.refresh();
    }
    this.onRender = function(ct, position) {
      company2482.on('change',Lino.chooser_handler(contact_person2483,'company'));
      Lino.cal.Rooms.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.cal.Rooms.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.countries.Countries.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 4,
  initComponent : function() {
    var isocode2529 = 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_code2530 = 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_panel2531 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": isocode2529, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": short_code2530, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 99, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2534 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(countries.Countries.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2535 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(countries.Countries.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_2_panel2536 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2534, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2535, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2539 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2531, main_2_panel2536 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2539;
    this.before_row_edit = function(record) {
    }
    Lino.countries.Countries.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.UploadsByController.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 61,
  initComponent : function() {
    var file2540 = Lino.file_field_handler(this,{ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Fail</span>", "listeners": { "render": Lino.quicktip_renderer("Fail","(uploads.UploadsByController.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file") }, "maxLength": 100, "name": "file", "selectOnFocus": true });
    var type2541 = 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 description2542 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(uploads.UploadsByController.description) A short description entered manually by the user.") }, "maxLength": 200, "name": "description", "selectOnFocus": true });
    var main_panel2543 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": file2540, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": type2541, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": description2542, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel2543;
    this.before_row_edit = function(record) {
      type2541.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    }
    Lino.uploads.UploadsByController.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.clocking.ServiceReports.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 50,
  initComponent : function() {
    var start_date2547 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(clocking.ServiceReports.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date2548 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (p\u00e4ev)","(clocking.ServiceReports.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var user2549 = 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("Autor","(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_for2550 = 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_state2551 = 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("Staatus","(clocking.ServiceReports.ticket_state) Only tickets in this state.") }, "name": "ticket_state", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.tickets.TicketStates) });
    var printed_disp2552 = new Ext.form.DisplayField({ "always_enabled": true, "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Tr\u00fckitud", "listeners": { "render": Lino.quicktip_renderer("Tr\u00fckitud","(clocking.ServiceReports.printed) ") }, "name": "printed", "value": "<br/>" });
    var main_1_panel2553 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 12, "items": start_date2547, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 12, "items": end_date2548, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": user2549, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 18, "items": interesting_for2550, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 10, "items": ticket_state2551, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": printed_disp2552, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2560 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organization</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_person2561 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "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_panel2562 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2560, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2561, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2623 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2553, main_2_panel2562 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2623;
    this.before_row_edit = function(record) {
      contact_person2561.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      company2560.on('change',Lino.chooser_handler(contact_person2561,'company'));
      Lino.clocking.ServiceReports.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.clocking.ServiceReports.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Tickets.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 42,
  initComponent : function() {
    var summary1533 = 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_user1534 = 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_panel1535 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": summary1533, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": end_user1534, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "form" });
    this.items = main_panel1535;
    this.before_row_edit = function(record) {
    }
    Lino.tickets.Tickets.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Calendars.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 23,
  initComponent : function() {
    var name2624 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.Calendars.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2625 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.Calendars.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2626 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2624, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2625, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var color2629 = 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_panel2630 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2626, { "anchor": "-20", "autoHeight": true, "items": color2629, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "form" });
    this.items = main_panel2630;
    this.before_row_edit = function(record) {
    }
    Lino.cal.Calendars.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.ExcerptTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 35,
  initComponent : function() {
    var id2632 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(excerpts.ExcerptTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2633 = 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("Nimetus","(excerpts.ExcerptTypes.name) The designation of this excerpt type.\nOne field for every language.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2634 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(excerpts.ExcerptTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2635 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2632, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2633, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2634, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var content_type2639 = 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_method2640 = 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 template2641 = 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_template2642 = 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_template2643 = 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 shortcut2644 = 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_panel2645 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 15, "items": content_type2639, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": build_method2640, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": template2641, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": body_template2642, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 15, "items": email_template2643, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": shortcut2644, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 153, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var primary2652 = 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_directly2653 = 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 certifying2654 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Tsertifitseeriv", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Tsertifitseeriv","(excerpts.ExcerptTypes.certifying) Whether an excerpt of this type is a unique printout.") }, "name": "certifying", "selectOnFocus": true });
    var print_recipient2655 = 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_compat2656 = 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_email2657 = 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_panel2658 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": primary2652, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": print_directly2653, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": certifying2654, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": print_recipient2655, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": backward_compat2656, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": attach_to_email2657, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2715 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2635, main_2_panel2645, main_3_panel2658 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2715;
    this.before_row_edit = function(record) {
      template2641.setContextValue('build_method', record ? record.data['build_methodHidden'] : undefined);
      template2641.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      body_template2642.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      email_template2643.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      build_method2640.on('change',Lino.chooser_handler(template2641,'build_method'));
      content_type2639.on('change',Lino.chooser_handler(template2641,'content_type'));
      content_type2639.on('change',Lino.chooser_handler(body_template2642,'content_type'));
      content_type2639.on('change',Lino.chooser_handler(email_template2643,'content_type'));
      Lino.excerpts.ExcerptTypes.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.ExcerptTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.Uploads.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 61,
  initComponent : function() {
    var type967 = 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 description968 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kirjeldus</span>", "listeners": { "render": Lino.quicktip_renderer("Kirjeldus","(uploads.Uploads.description) A short description entered manually by the user.") }, "maxLength": 200, "name": "description", "selectOnFocus": true });
    var file969 = Lino.file_field_handler(this,{ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Fail</span>", "listeners": { "render": Lino.quicktip_renderer("Fail","(uploads.Uploads.file) Pointer to the uploaded file. See\nlino.mixins.uploadable.Uploadable.file") }, "maxLength": 100, "name": "file", "selectOnFocus": true });
    var user970 = 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_panel971 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": type967, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": description968, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": file969, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": user970, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel971;
    this.before_row_edit = function(record) {
      type967.setContextValue('upload_area', record ? record.data['upload_areaHidden'] : undefined);
    }
    Lino.uploads.Uploads.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.Excerpts.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 36,
  initComponent : function() {
    var excerpt_type2706 = 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("V\u00e4ljav\u00f5teliik","(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 company2707 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Firma)</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Saaja (Firma)","(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_person2708 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Isik)</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Saaja (Isik)","(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_panel2709 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2707, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2708, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2712 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": excerpt_type2706, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel2709 ], "labelAlign": "top", "labelWidth": 126, "layout": "form" });
    this.items = main_panel2712;
    this.before_row_edit = function(record) {
      excerpt_type2706.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person2708.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      company2707.on('change',Lino.chooser_handler(contact_person2708,'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: 35,
  initComponent : function() {
    var name2716 = 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("Nimetus","(excerpts.ExcerptTypes.name) The designation of this excerpt type.\nOne field for every language.") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2717 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(excerpts.ExcerptTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2718 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2716, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2717, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var content_type2721 = 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 primary2722 = 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 certifying2723 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Tsertifitseeriv", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Tsertifitseeriv","(excerpts.ExcerptTypes.certifying) Whether an excerpt of this type is a unique printout.") }, "name": "certifying", "selectOnFocus": true });
    var main_2_panel2724 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": content_type2721, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": primary2722, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 25, "items": certifying2723, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var build_method2728 = 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 template2729 = 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_template2730 = 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_panel2731 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 53, "items": build_method2728, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": template2729, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": body_template2730, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2735 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2718, main_2_panel2724, main_3_panel2731 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2735;
    this.before_row_edit = function(record) {
      template2729.setContextValue('build_method', record ? record.data['build_methodHidden'] : undefined);
      template2729.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
      body_template2730.setContextValue('content_type', record ? record.data['content_typeHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      build_method2728.on('change',Lino.chooser_handler(template2729,'build_method'));
      content_type2721.on('change',Lino.chooser_handler(template2729,'content_type'));
      content_type2721.on('change',Lino.chooser_handler(body_template2730,'content_type'));
      Lino.excerpts.ExcerptTypes.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.ExcerptTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.uploads.UploadTypes.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 60,
  initComponent : function() {
    var name2736 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(uploads.UploadTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2737 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(uploads.UploadTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2738 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": name2736, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name_et2737, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var upload_area2741 = 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_panel2742 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2738, { "anchor": "-20", "autoHeight": true, "items": upload_area2741, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel2742;
    this.before_row_edit = function(record) {
    }
    Lino.uploads.UploadTypes.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.changes.Changes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 39,
  disable_editing: true,
  initComponent : function() {
    var time1514 = 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 user1515 = new Lino.TwinCombo({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Kasutaja", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Kasutaja","(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 type1516 = 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_disp1517 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Master</span>", "name": "master" });
    var object_disp1518 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Object</span>", "name": "object" });
    var id1519 = 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_panel1520 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 21, "items": time1514, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 26, "items": user1515, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": type1516, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": master_disp1517, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 13, "items": object_disp1518, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 6, "items": id1519, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var diff1527 = 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_panel1528 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel1520, { "flex": 83, "items": diff1527, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 72, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel1528;
    this.before_row_edit = function(record) {
    }
    Lino.changes.Changes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.cal.Rooms.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 15,
  initComponent : function() {
    var id2744 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(cal.Rooms.id) ") }, "name": "id", "selectOnFocus": true });
    var name2745 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(cal.Rooms.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2746 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(cal.Rooms.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2747 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2744, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2745, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2746, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2751 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "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_person2752 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Kontaktisik</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Kontaktisik","(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_panel2753 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2747, { "anchor": "-20", "autoHeight": true, "items": company2751, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": contact_person2752, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 108, "layout": "form" });
    this.items = main_panel2753;
    this.before_row_edit = function(record) {
      contact_person2752.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      company2751.on('change',Lino.chooser_handler(contact_person2752,'company'));
      Lino.cal.Rooms.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.cal.Rooms.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.TicketTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 44,
  initComponent : function() {
    var id2756 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tickets.TicketTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2757 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(tickets.TicketTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2758 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(tickets.TicketTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2759 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2756, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2757, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2758, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var TicketsByType_grid2795 = new Lino.tickets.TicketsByType.GridPanel({ "containing_panel": this, "flex": 83, "hide_top_toolbar": true, "listeners": { "render": Lino.quicktip_renderer("Lipikud","(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_panel2796 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2759, TicketsByType_grid2795 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2796;
    this.before_row_edit = function(record) {
      TicketsByType_grid2795.on_master_changed();
    }
    Lino.tickets.TicketTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.ProjectTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 43,
  initComponent : function() {
    var id2797 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(tickets.ProjectTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2798 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(tickets.ProjectTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2799 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(tickets.ProjectTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2800 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2797, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2798, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2799, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2829 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2800 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2829;
    this.before_row_edit = function(record) {
    }
    Lino.tickets.ProjectTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.CommentTypes.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 38,
  initComponent : function() {
    var id2830 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(comments.CommentTypes.id) ") }, "name": "id", "selectOnFocus": true });
    var name2831 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(comments.CommentTypes.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var name_et2832 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(comments.CommentTypes.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var main_1_panel2833 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 10, "items": id2830, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name2831, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 44, "items": name_et2832, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2838 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2833 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2838;
    this.before_row_edit = function(record) {
    }
    Lino.comments.CommentTypes.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.comments.Comments.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 37,
  initComponent : function() {
    var reply_to2839 = new Lino.TwinCombo({ "emptyText": "Vali m\u00f5ni Comment...", "fieldLabel": "Reply to", "flex": 50, "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 owner2840 = new Lino.TwinCombo({ "emptyText": "Vali m\u00f5ni Lipik...", "fieldLabel": "Lipik", "flex": 50, "hidden": true, "hiddenName": "ownerHidden", "listeners": { "render": Lino.quicktip_renderer("Lipik","(comments.Comments.owner) ") }, "name": "owner", "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/comments/Comments/owner" }) }) });
    var main_1_panel2841 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hidden": true, "hideCheckBoxLabels": true, "items": [ reply_to2839, owner2840 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var short_text2842 = 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_panel2843 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2841, short_text2842 ], "labelAlign": "top", "labelWidth": 99, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2843;
    this.before_row_edit = function(record) {
      short_text2842.refresh();
    }
    Lino.comments.Comments.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Lines.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 28,
  initComponent : function() {
    var id2258 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(courses.Lines.id) ") }, "name": "id", "selectOnFocus": true });
    var name2259 = 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("Nimetus","(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_et2260 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus (et)", "listeners": { "render": Lino.quicktip_renderer("Nimetus (et)","(courses.Lines.name_et) ") }, "maxLength": 200, "name": "name_et", "selectOnFocus": true });
    var ref2261 = 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_panel2262 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 7, "items": id2258, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": name2259, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": name_et2260, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": ref2261, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2267 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organization</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_person2268 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "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_panel2269 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": company2267, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": contact_person2268, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var course_area2272 = 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 topic2273 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Teema...", "fieldLabel": "Teema", "hiddenName": "topicHidden", "listeners": { "render": Lino.quicktip_renderer("Teema","(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_template2274 = 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_panel2275 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": course_area2272, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 46, "items": topic2273, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 23, "items": body_template2274, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var event_type2279 = 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("S\u00fcndmuseliik","(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_role2280 = 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_unit2281 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Korduvus", "forceSelection": true, "hiddenName": "every_unitHidden", "listeners": { "render": Lino.quicktip_renderer("Korduvus","(courses.Lines.every_unit) ") }, "name": "every_unit", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.Recurrencies) });
    var every2282 = new Ext.form.NumberField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Korda iga", "listeners": { "render": Lino.quicktip_renderer("Korda iga","(courses.Lines.every) ") }, "name": "every", "selectOnFocus": true, "value": 1 });
    var main_4_panel2283 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": event_type2279, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": guest_role2280, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": every_unit2281, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 7, "items": every2282, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 180, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var excerpt_title2288 = 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_et2289 = 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_panel2290 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": excerpt_title2288, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": excerpt_title_et2289, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 171, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description2293 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 50, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var description_et2294 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus (et)", "flex": 50, "name": "description_et", "selectOnFocus": true, "title": "Kirjeldus (et)" });
    var main_6_panel2295 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 50, "frame": false, "hideCheckBoxLabels": true, "items": [ description2293, description_et2294 ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var main_panel2296 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2262, main_2_panel2269, main_3_panel2275, main_4_panel2283, main_5_panel2290, main_6_panel2295 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2296;
    this.before_row_edit = function(record) {
      contact_person2268.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2293.refresh();
      description_et2294.refresh();
    }
    this.onRender = function(ct, position) {
      company2267.on('change',Lino.chooser_handler(contact_person2268,'company'));
      Lino.courses.Lines.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.courses.Lines.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.excerpts.Excerpts.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 36,
  initComponent : function() {
    var id2683 = 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_type2684 = 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("V\u00e4ljav\u00f5teliik","(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_panel2685 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 16, "items": id2683, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 83, "items": excerpt_type2684, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var user2688 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Kasutaja...", "fieldLabel": "Autor", "hiddenName": "userHidden", "listeners": { "render": Lino.quicktip_renderer("Autor","(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_method2689 = 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_panel2690 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 30, "items": user2688, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 69, "items": build_method2689, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company2693 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Firma)</span>", "hiddenName": "companyHidden", "listeners": { "render": Lino.quicktip_renderer("Saaja (Firma)","(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_person2694 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Saaja (Isik)</span>", "hiddenName": "contact_personHidden", "listeners": { "render": Lino.quicktip_renderer("Saaja (Isik)","(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 language2695 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(excerpts.Excerpts.language) The language used for printing this excerpt.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var main_3_panel2696 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": company2693, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": contact_person2694, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": language2695, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var owner_disp2700 = 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_time2701 = 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_panel2702 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 38, "items": owner_disp2700, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 61, "items": build_time2701, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 126, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2705 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2685, main_2_panel2690, main_3_panel2696, main_4_panel2702 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2705;
    this.before_row_edit = function(record) {
      excerpt_type2684.setContextValue('owner', record ? record.data['owner'] : undefined);
      contact_person2694.setContextValue('company', record ? record.data['companyHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      owner_disp2700.on('change',Lino.chooser_handler(excerpt_type2684,'owner'));
      company2693.on('change',Lino.chooser_handler(contact_person2694,'company'));
      Lino.excerpts.Excerpts.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.excerpts.Excerpts.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.users.Users.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 12,
  initComponent : function() {
    var username2844 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajanimi", "listeners": { "render": Lino.quicktip_renderer("Kasutajanimi","(users.Users.username) ") }, "maxLength": 30, "name": "username", "selectOnFocus": true });
    var profile2845 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajaliik", "forceSelection": true, "hiddenName": "profileHidden", "listeners": { "render": Lino.quicktip_renderer("Kasutajaliik","(users.Users.profile) ") }, "name": "profile", "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var initials2846 = 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_1_panel2847 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": username2844, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": profile2845, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 21, "items": initials2846, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var language2851 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(users.Users.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var id2852 = new Ext.form.NumberField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "ID", "listeners": { "render": Lino.quicktip_renderer("ID","(users.Users.id) ") }, "name": "id", "selectOnFocus": true });
    var created2853 = 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("Loodud","(users.Users.created) The timestame when this object was created.") }, "name": "created", "value": "<br>" });
    var modified2854 = new Ext.form.DisplayField({ "anchor": "-20", "autoHeight": true, "disabled": true, "fieldLabel": "Muudatud", "listeners": { "render": Lino.quicktip_renderer("Muudatud","(users.Users.modified) ") }, "name": "modified", "value": "<br>" });
    var box1_2_panel2855 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 35, "items": language2851, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 8, "items": id2852, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": created2853, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": modified2854, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var callme_mode2860 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Others may contact me", "checked": true, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Others may contact me","(users.Users.callme_mode) Whether other users can see my contact data.") }, "name": "callme_mode", "selectOnFocus": true });
    var mail_mode2861 = new Lino.ChoicesFieldElement({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Email notification mode", "forceSelection": true, "hiddenName": "mail_modeHidden", "listeners": { "render": Lino.quicktip_renderer("Email notification mode","(users.Users.mail_mode) ") }, "name": "mail_mode", "selectOnFocus": true, "store": Lino.notify.MailModes });
    var notify_myself2862 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "Notify myself", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("Notify myself","(users.Users.notify_myself) ") }, "name": "notify_myself", "selectOnFocus": true });
    var box1_3_panel2863 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 34, "items": callme_mode2860, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 31, "items": mail_mode2861, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": notify_myself2862, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 216, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var box1_panel2867 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 75, "frame": true, "hideCheckBoxLabels": true, "items": [ box1_1_panel2847, box1_2_panel2855, box1_3_panel2863 ], "labelAlign": "top", "layout": "form" });
    var general_1_panel2873 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ box1_panel2867 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var general_panel2875 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel2873 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var first_name2876 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("Eesnimi","(users.Users.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name2877 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Perenimi","(users.Users.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var address_box_1_panel2878 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": first_name2876, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": last_name2877, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var country2881 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Riik","(users.Users.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/Users/country" }) }) });
    var region2882 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Asum...", "fieldLabel": "Maakond", "hiddenName": "regionHidden", "listeners": { "render": Lino.quicktip_renderer("Maakond","(users.Users.region) ") }, "name": "region", "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/Users/region" }) }) });
    var city2883 = 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("Linn","(users.Users.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/Users/city" }) }) });
    var zip_code2884 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "boxMinWidth": Lino.chars2width(10), "fieldLabel": "Zip code", "listeners": { "render": Lino.quicktip_renderer("Zip code","(users.Users.zip_code) ") }, "maxLength": 10, "name": "zip_code", "selectOnFocus": true });
    var address_box_2_panel2885 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 28, "items": country2881, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": region2882, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 28, "items": city2883, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 14, "items": zip_code2884, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street2890 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Street</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(users.Users.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no2891 = 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("Nr.","(users.Users.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var address_box_4_panel2892 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 69, "items": street2890, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": street_no2891, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var address_box_panel2895 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 63, "frame": true, "hideCheckBoxLabels": true, "items": [ address_box_1_panel2878, address_box_2_panel2885, address_box_4_panel2892 ], "labelAlign": "top", "layout": "form" });
    var email2896 = 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 phone2897 = 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.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.") }, "maxLength": 200, "name": "phone", "selectOnFocus": true });
    var gsm2898 = 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.Users.gsm) The primary mobile phone number.") }, "maxLength": 200, "name": "gsm", "selectOnFocus": true });
    var info_box_panel2899 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "flex": 36, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": email2896, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": phone2897, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": gsm2898, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "form" });
    var contact_1_panel2903 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ address_box_panel2895, info_box_panel2899 ], "labelAlign": "top", "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var remarks2904 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "M\u00e4rkused", "flex": 66, "name": "remarks", "selectOnFocus": true, "title": "M\u00e4rkused" });
    var contact_2_panel2908 = new Ext.Panel({ "autoScroll": false, "border": false, "flex": 62, "frame": false, "hideCheckBoxLabels": true, "items": [ remarks2904 ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretch" } });
    var contact_panel2909 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ contact_1_panel2903, contact_2_panel2908 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "Contact" });
    var main_panel2937 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel2875, contact_panel2909 ], "labelAlign": "top", "split": true });
    this.items = main_panel2937;
    this.before_row_edit = function(record) {
      region2882.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city2883.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city2883.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      remarks2904.refresh();
    }
    this.onRender = function(ct, position) {
      country2881.on('change',Lino.chooser_handler(region2882,'country'));
      country2881.on('change',Lino.chooser_handler(city2883,'country'));
      region2882.on('change',Lino.chooser_handler(city2883,'region'));
      Lino.users.Users.DetailFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.users.Users.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city2883.on("change", function(){ this.save() }, this);
    zip_code2884.on("change", function(){ this.save() }, this);
  }
});


Lino.users.OtherUsers.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 12,
  disable_editing: true,
  initComponent : function() {
    var first_name2938 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("Eesnimi","(users.OtherUsers.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name2939 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Perenimi","(users.OtherUsers.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var city2940 = 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("Linn","(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_panel2941 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": first_name2938, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": last_name2939, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 32, "items": city2940, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var phone2945 = 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 gsm2946 = 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_panel2947 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": phone2945, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": gsm2946, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var about_me_htmlbox2950 = 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_panel2951 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2941, main_2_panel2947, about_me_htmlbox2950 ], "labelAlign": "top", "labelWidth": 81, "layout": "vbox", "layoutConfig": { "align": "stretch" } });
    this.items = main_panel2951;
    this.before_row_edit = function(record) {
      about_me_htmlbox2950.refresh();
    }
    Lino.users.OtherUsers.DetailFormPanel.superclass.initComponent.call(this);
    // active_fields:
    city2940.on("change", function(){ this.save() }, this);
  }
});


Lino.users.Register.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 12,
  initComponent : function() {
    var first_name2952 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Eesnimi</span>", "listeners": { "render": Lino.quicktip_renderer("Eesnimi","(users.Register.first_name) The first name, also known as given name.") }, "maxLength": 200, "name": "first_name", "selectOnFocus": true });
    var last_name2953 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Perenimi</span>", "listeners": { "render": Lino.quicktip_renderer("Perenimi","(users.Register.last_name) The last name, also known as family name.") }, "maxLength": 200, "name": "last_name", "selectOnFocus": true });
    var main_1_panel2954 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": first_name2952, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": last_name2953, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 81, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var email2957 = 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 language2958 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(users.Register.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var main_2_panel2959 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 51, "items": email2957, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 48, "items": language2958, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var gsm2962 = 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 phone2963 = 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_panel2964 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": gsm2962, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": phone2963, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 54, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var country2967 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Riik...", "fieldLabel": "Riik", "hiddenName": "countryHidden", "listeners": { "render": Lino.quicktip_renderer("Riik","(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 city2968 = 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("Linn","(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_panel2969 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": country2967, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": city2968, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 45, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var street2972 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Street</span>", "listeners": { "render": Lino.quicktip_renderer("Street","(users.Register.street) Name of street, without house number.") }, "maxLength": 200, "name": "street", "selectOnFocus": true });
    var street_no2973 = 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("Nr.","(users.Register.street_no) House number.") }, "maxLength": 10, "name": "street_no", "selectOnFocus": true });
    var main_5_panel2974 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 65, "items": street2972, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 34, "items": street_no2973, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 63, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var username2977 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Kasutajanimi", "listeners": { "render": Lino.quicktip_renderer("Kasutajanimi","(users.Register.username) ") }, "maxLength": 30, "name": "username", "selectOnFocus": true });
    var main_panel2978 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2954, main_2_panel2959, main_3_panel2964, main_4_panel2969, main_5_panel2974, { "anchor": "-20", "autoHeight": true, "items": username2977, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "form" });
    this.items = main_panel2978;
    this.before_row_edit = function(record) {
      city2968.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city2968.setContextValue('region', record ? record.data['regionHidden'] : undefined);
    }
    this.onRender = function(ct, position) {
      country2967.on('change',Lino.chooser_handler(city2968,'country'));
      Lino.users.Register.InsertFormPanel.superclass.onRender.call(this, ct, position);
    }
    Lino.users.Register.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.contacts.Partners.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 10,
  initComponent : function() {
    var name885 = 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("Nimi","(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 language886 = new Lino.ChoicesFieldElement({ "anchor": "-20", "autoHeight": true, "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Keel</span>", "hiddenName": "languageHidden", "listeners": { "render": Lino.quicktip_renderer("Keel","(contacts.Partners.language) The language to use when communicating with this partner.") }, "name": "language", "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var email887 = 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_panel888 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 48, "items": language886, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 51, "items": email887, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel891 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": name885, "labelAlign": "top", "layout": "form", "xtype": "panel" }, main_2_panel888 ], "labelAlign": "top", "labelWidth": 45, "layout": "form" });
    this.items = main_panel891;
    this.before_row_edit = function(record) {
    }
    Lino.contacts.Partners.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.tickets.Projects.DetailFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  content_type: 40,
  initComponent : function() {
    var ref1877 = 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 name1878 = new Ext.form.TextField({ "allowBlank": false, "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimi", "listeners": { "render": Lino.quicktip_renderer("Nimi","(tickets.Projects.name) ") }, "maxLength": 200, "name": "name", "selectOnFocus": true });
    var general_1_panel1879 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": ref1877, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": name1878, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 90, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var description1882 = new Lino.RichTextPanel({ "containing_panel": this, "fieldLabel": "Kirjeldus", "flex": 83, "name": "description", "selectOnFocus": true, "title": "Kirjeldus" });
    var general_panel1883 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ general_1_panel1879, description1882 ], "labelAlign": "top", "labelWidth": 90, "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "\u00dcld" });
    var parent1917 = 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 type1918 = 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_type1919 = 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_panel1920 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 40, "items": parent1917, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 40, "items": type1918, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 20, "items": reporting_type1919, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var company1924 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Organization...", "fieldLabel": "<span style=\"border-bottom: 1px dotted #000000;\">Organization</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_to1925 = 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 private1926 = 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 closed1927 = new Ext.form.Checkbox({ "anchor": "-20", "autoHeight": true, "boxLabel": "L\u00f5petatud", "checked": false, "hideLabel": true, "listeners": { "render": Lino.quicktip_renderer("L\u00f5petatud","(tickets.Projects.closed) Whether this investment is closed, i.e. certain things should\nnot change anymore.") }, "name": "closed", "selectOnFocus": true });
    var more_2_panel1928 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 33, "items": company1924, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 33, "items": assign_to1925, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": private1926, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 16, "items": closed1927, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 162, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var start_date1933 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(tickets.Projects.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var end_date1934 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "L\u00f5peb (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("L\u00f5peb (p\u00e4ev)","(tickets.Projects.end_date) ") }, "name": "end_date", "selectOnFocus": true });
    var srcref_url_template1935 = 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_template1936 = 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_panel1937 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 19, "items": start_date1933, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 19, "items": end_date1934, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": srcref_url_template1935, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 30, "items": changeset_url_template1936, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 207, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var more_panel2003 = new Ext.Panel({ "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ more_1_panel1920, more_2_panel1928, more_3_panel1937 ], "labelAlign": "top", "layout": "vbox", "layoutConfig": { "align": "stretch" }, "listeners": { "activate": Lino.on_tab_activate }, "title": "More" });
    var main_panel2004 = new Ext.TabPanel({ "activeTab": 0, "autoScroll": false, "bodyBorder": false, "border": false, "enableTabScroll": true, "frame": true, "hideCheckBoxLabels": true, "items": [ general_panel1883, more_panel2003 ], "labelAlign": "top", "split": true });
    this.items = main_panel2004;
    this.before_row_edit = function(record) {
      description1882.refresh();
    }
    Lino.tickets.Projects.DetailFormPanel.superclass.initComponent.call(this);
  }
});


Lino.courses.Activities.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 30,
  initComponent : function() {
    var line2216 = 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("Tegevuste sari","(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 teacher2217 = new Lino.TwinCombo({ "anchor": "-20", "autoHeight": true, "emptyText": "Vali m\u00f5ni Person...", "fieldLabel": "\u00dcrituse juht", "hiddenName": "teacherHidden", "listeners": { "render": Lino.quicktip_renderer("\u00dcrituse juht","(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_panel2218 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 50, "items": line2216, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 50, "items": teacher2217, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 135, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var name2221 = new Ext.form.TextField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Nimetus", "listeners": { "render": Lino.quicktip_renderer("Nimetus","(courses.Activities.name) ") }, "maxLength": 100, "name": "name", "selectOnFocus": true });
    var start_date2222 = new Lino.DateField({ "anchor": "-20", "autoHeight": true, "fieldLabel": "Algab (p\u00e4ev)", "listeners": { "render": Lino.quicktip_renderer("Algab (p\u00e4ev)","(courses.Activities.start_date) ") }, "name": "start_date", "selectOnFocus": true });
    var main_2_panel2223 = new Ext.Panel({ "anchor": "-20", "autoHeight": true, "autoScroll": false, "border": false, "frame": false, "hideCheckBoxLabels": true, "items": [ { "autoHeight": true, "flex": 61, "items": name2221, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "autoHeight": true, "flex": 38, "items": start_date2222, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 117, "layout": "hbox", "layoutConfig": { "align": "stretchmax" } });
    var main_panel2226 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ main_1_panel2218, main_2_panel2223 ], "labelAlign": "top", "layout": "form" });
    this.items = main_panel2226;
    this.before_row_edit = function(record) {
    }
    Lino.courses.Activities.InsertFormPanel.superclass.initComponent.call(this);
  }
});


Lino.blogs.Entries.InsertFormPanel = Ext.extend(Lino.FormPanel,{
  layout: 'fit',
  auto_save: true,
  autoHeight: true,
  content_type: 56,
  initComponent : function() {
    var title1635 = 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_type1636 = 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_panel1637 = new Ext.Panel({ "autoHeight": true, "autoScroll": false, "bodyBorder": false, "border": false, "frame": true, "hideCheckBoxLabels": true, "items": [ { "anchor": "-20", "autoHeight": true, "items": title1635, "labelAlign": "top", "layout": "form", "xtype": "panel" }, { "anchor": "-20", "autoHeight": true, "items": entry_type1636, "labelAlign": "top", "layout": "form", "xtype": "panel" } ], "labelAlign": "top", "labelWidth": 144, "layout": "form" });
    this.items = main_panel1637;
    this.before_row_edit = function(record) {
    }
    Lino.blogs.Entries.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({});
});

// 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/cal/Rooms','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/cal/Rooms','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/cal/Rooms','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Ruumid",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 14,
  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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 15,
  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 id2980 = new Ext.form.NumberField({ "selectOnFocus": true });
    var name2981 = new Ext.form.TextField({ "allowBlank": false, "maxLength": 200, "selectOnFocus": true });
    var name_et2982 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var company2983 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organization...", "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_person2984 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Person...", "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_role2985 = 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 description2986 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Kirjeldus" });
    var workflow_buttons_disp2987 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2988 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2989 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      contact_person2984.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      description2986.refresh();
    };
    this.onRender = function(ct, position) {
      company2983.on('change',Lino.chooser_handler(contact_person2984,'company'));
      Lino.cal.Rooms.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id2980, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(cal.Rooms.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "name", "editable": true, "editor": name2981, "filter": { "type": "string" }, "header": "Nimetus", "sortable": true, "tooltip": "(cal.Rooms.name) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "name_et", "editable": true, "editor": name_et2982, "filter": { "type": "string" }, "header": "Nimetus (et)", "sortable": true, "tooltip": "(cal.Rooms.name_et) ", "width": Lino.chars2width(22) }, { "colIndex": 3, "dataIndex": "company", "editable": true, "editor": company2983, "filter": { "type": "string" }, "header": "Responsible", "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_person2984, "filter": { "type": "string" }, "header": "Kontaktisik", "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_role2985, "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": description2986, "filter": { "type": "string" }, "header": "Kirjeldus", "sortable": false, "tooltip": "(cal.Rooms.description) ", "width": Lino.chars2width(61) }, { "colIndex": 7, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 8, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 9, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.Rooms.description_column) ", "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.Rooms.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/Rooms", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.PublicEntries
Lino.cal.PublicEntries.GridPanel = Ext.extend(Lino.GridPanel,{
  viewConfig : { "emptyText": "No data to display.", "forceFit": true, "getRowClass": Lino.getRowClass },
  ls_url : "/cal/PublicEntries",
  ls_bbar_actions : [ { "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/PublicEntries','show_as_html','GET',Lino.get_current_grid_config), "tooltip": "Show this table in Bootstrap3 interface" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/cal/PublicEntries','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/cal/PublicEntries','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/cal/PublicEntries','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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/PublicEntries','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, "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-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 : 53,
  ls_store_fields : [ { "name": "overview" }, { "name": "room" }, 'roomHidden', { "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": "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": "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": "workflow_buttons" }, { "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 : 18,
  ls_id_property : "id",
  gc_name : 0,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.PublicEntries.detail;
    this.ls_insert_handler = Lino.cal.PublicEntries.insert;
    var ww = this.containing_window;
    var overview_disp2991 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var room2992 = 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/PublicEntries/room" }) }) });
    var event_type2993 = 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/PublicEntries/event_type" }) }) });
    var id2994 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified2995 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2996 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var start_date2997 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var start_time2998 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var end_date2999 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var end_time3000 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var build_time3001 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var build_method3002 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.printing.BuildMethods) });
    var company3003 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Organization...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/PublicEntries/company" }) }) });
    var contact_person3004 = new Lino.RemoteComboFieldElement({ "emptyText": "Vali m\u00f5ni Person...", "hidden": true, "pageSize": 20, "preferred_width": 20, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/PublicEntries/contact_person" }) }) });
    var contact_role3005 = 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/PublicEntries/contact_role" }) }) });
    var user3006 = 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/PublicEntries/user" }) }) });
    var assigned_to3007 = 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/PublicEntries/assigned_to" }) }) });
    var owner_type3008 = 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/PublicEntries/owner_type" }) }) });
    var owner_id3009 = new Lino.RemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/cal/PublicEntries/owner_id" }) }) });
    var summary3010 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description3011 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var access_class3012 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.cal.AccessClasses) });
    var sequence3013 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 0 });
    var auto_type3014 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var transparent3015 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3016 = 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/PublicEntries/priority" }) }) });
    var state3017 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.EntryStates });
    var owner_disp3018 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var calendar3019 = new Lino.RemoteComboFieldElement({ "disabled": true, "emptyText": "Vali m\u00f5ni Kalender...", "hidden": true, "pageSize": 20, "store": new Lino.ComplexRemoteComboStore({  }) });
    var when_html_disp3020 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reminder_disp3021 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var when_text_disp3022 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var all_day3023 = new Ext.form.Checkbox({ "hidden": true, "selectOnFocus": true });
    var url_disp3024 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3025 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3026 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3027 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duration3028 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "hidden": true, "maxLength": 6 });
    this.before_row_edit = function(record) {
      contact_person3004.setContextValue('company', record ? record.data['companyHidden'] : undefined);
      owner_id3009.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      company3003.on('change',Lino.chooser_handler(contact_person3004,'company'));
      owner_type3008.on('change',Lino.chooser_handler(owner_id3009,'owner_type'));
      Lino.cal.PublicEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "sortable": false, "tooltip": "(cal.PublicEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 1, "dataIndex": "room", "editable": true, "editor": room2992, "filter": { "type": "string" }, "header": "Ruum", "renderer": Lino.fk_renderer('roomHidden','Lino.cal.Rooms.detail'), "sortable": false, "tooltip": "(cal.PublicEntries.room) ", "width": Lino.chars2width(21) }, { "colIndex": 2, "dataIndex": "event_type", "editable": true, "editor": event_type2993, "filter": { "type": "string" }, "header": "S\u00fcndmuseliik", "sortable": false, "tooltip": "(cal.PublicEntries.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": 3, "dataIndex": "id", "editable": true, "editor": id2994, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.id) ", "width": Lino.chars2width(6) }, { "colIndex": 4, "dataIndex": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 5, "dataIndex": "created", "editable": false, "header": "Loodud", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.created) The timestame when this object was created.", "width": Lino.chars2width(17) }, { "colIndex": 6, "dataIndex": "start_date", "editable": true, "editor": start_date2997, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "Algab (p\u00e4ev)", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.start_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 7, "dataIndex": "start_time", "editable": true, "editor": start_time2998, "header": "Start time", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.start_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "end_date", "editable": true, "editor": end_date2999, "filter": { "dateFormat": "d.m.Y", "type": "date" }, "format": "d.m.Y", "header": "End Date", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.end_date) ", "width": Lino.chars2width(14), "xtype": "datecolumn" }, { "colIndex": 9, "dataIndex": "end_time", "editable": true, "editor": end_time3000, "header": "L\u00f5peb (aeg)", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.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.PublicEntries.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_method3002, "filter": { "type": "string" }, "header": "Build method", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.build_method) ", "width": Lino.chars2width(24) }, { "colIndex": 12, "dataIndex": "company", "editable": true, "editor": company3003, "filter": { "type": "string" }, "header": "Organizer", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.company) Pointer to lino_xl.lib.contacts.models.Company.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "contact_person", "editable": true, "editor": contact_person3004, "filter": { "type": "string" }, "header": "Kontaktisik", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.contact_person) Pointer to lino_xl.lib.contacts.models.Person.", "width": Lino.chars2width(21) }, { "colIndex": 14, "dataIndex": "contact_role", "editable": true, "editor": contact_role3005, "filter": { "type": "string" }, "header": "represented as", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.contact_role) The optional Role\nof the contact_person within company.", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "user", "editable": true, "editor": user3006, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.user) The responsible user.", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "assigned_to", "editable": true, "editor": assigned_to3007, "filter": { "type": "string" }, "header": "Assigned to", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.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_type3008, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "owner_id", "editable": true, "editor": owner_id3009, "filter": { "type": "string" }, "header": "Controlled by (object)", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.owner_id) ", "width": Lino.chars2width(11) }, { "colIndex": 19, "dataIndex": "summary", "editable": true, "editor": summary3010, "filter": { "type": "string" }, "header": "L\u00fchikirjeldus", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.summary) A one-line descriptive text.", "width": Lino.chars2width(22) }, { "colIndex": 20, "dataIndex": "description", "editable": true, "editor": description3011, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.description) A longer descriptive text.", "width": Lino.chars2width(61) }, { "colIndex": 21, "dataIndex": "access_class", "editable": true, "editor": access_class3012, "filter": { "type": "string" }, "header": "Access Class", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.access_class) Whether this is private, public or between.", "width": Lino.chars2width(13) }, { "align": "right", "colIndex": 22, "dataIndex": "sequence", "editable": true, "editor": sequence3013, "filter": { "type": "numeric" }, "format": "0", "header": "Revision", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.sequence) ", "width": Lino.chars2width(6) }, { "align": "right", "colIndex": 23, "dataIndex": "auto_type", "editable": true, "editor": auto_type3014, "filter": { "type": "numeric" }, "format": "0", "header": "Nr.", "hidden": true, "sortable": true, "tooltip": "(cal.PublicEntries.auto_type) Contains the sequence number if this is an automatically\ngenerated component. Otherwise this field is empty.", "width": Lino.chars2width(6) }, { "colIndex": 24, "dataIndex": "transparent", "editable": true, "filter": { "type": "boolean" }, "header": "Transparent", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.transparent) Indicates that this entry shouldn't prevent other entries at\nthe same time.", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "priority", "editable": true, "editor": priority3016, "filter": { "type": "string" }, "header": "Priority", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.priority) ", "width": Lino.chars2width(21) }, { "colIndex": 26, "dataIndex": "state", "editable": true, "editor": state3017, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.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.PublicEntries.owner) ", "width": Lino.chars2width(11) }, { "colIndex": 28, "dataIndex": "calendar", "editable": false, "header": "Kalender", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.calendar) ", "width": Lino.chars2width(21) }, { "colIndex": 29, "dataIndex": "when_html", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.when_html) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reminder", "editable": false, "header": "Reminder", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.reminder) ", "width": Lino.chars2width(31) }, { "colIndex": 31, "dataIndex": "when_text", "editable": false, "header": "Millal", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.when_text) ", "width": Lino.chars2width(31) }, { "colIndex": 32, "dataIndex": "all_day", "editable": true, "header": "all day", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.all_day) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 33, "dataIndex": "url", "editable": false, "header": "Link URL", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.url) ", "width": Lino.chars2width(31) }, { "colIndex": 34, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 35, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 36, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.created_natural) ", "width": Lino.chars2width(31) }, { "align": "right", "colIndex": 37, "dataIndex": "duration", "editable": false, "format": "", "header": "Kestus", "hidden": true, "sortable": false, "tooltip": "(cal.PublicEntries.duration) ", "width": Lino.chars2width(8) } ];
    Lino.cal.PublicEntries.GridPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.PublicEntries.show_as_html = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "show_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.PublicEntries.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "as_pdf_p", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.export_excel = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "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.PublicEntries.submit_detail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "submit_detail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.PublicEntries.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: [  ],
  ls_url: "/cal/PublicEntries",
  action_name: "insert",
  default_record_id: -99999,
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.PublicEntries.detail;
    this.ls_insert_handler = Lino.cal.PublicEntries.insert;
    Lino.cal.PublicEntries.insertPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.PublicEntries.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.PublicEntries.insertPanel(p);
});
Lino.cal.PublicEntries.grid_put = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "grid_put", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.grid_post = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "grid_post", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.submit_insert = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "submit_insert", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.duplicate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "duplicate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};

Lino.cal.PublicEntries.detailPanel = Ext.extend(Lino.cal.Events.DetailFormPanel,{
  empty_title: "Detail",
  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','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-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/PublicEntries",
  action_name: "detail",
  initComponent : function() {
    this.ls_detail_handler = Lino.cal.PublicEntries.detail;
    this.ls_insert_handler = Lino.cal.PublicEntries.insert;
    Lino.cal.PublicEntries.detailPanel.superclass.initComponent.call(this);
  }
});

Lino.cal.PublicEntries.detail = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  return new Lino.cal.PublicEntries.detailPanel(p);
});
Lino.cal.PublicEntries.delete_selected = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "delete_selected", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.do_print = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "POST", pk, "do_print", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.do_clear_cache = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "do_clear_cache", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.show_conflicting = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "show_conflicting", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.show_today = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "show_today", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.grid = new Lino.WindowAction({  }, function(){
  var p = { "is_main_window": true };
  p.params_panel = new Lino.cal.Events.ParamsPanel({});
  return new Lino.cal.PublicEntries.GridPanel(p);
});
Lino.cal.PublicEntries.validate = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "validate", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.create_postings = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "create_postings", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.update_guests = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "update_guests", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.take = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "take", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.assign_to_me = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "assign_to_me", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.move_next = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "move_next", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.create_mail = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "create_mail", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.update_events = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "update_events", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.reset_event = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "reset_event", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.wf2 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "wf2", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.cal.PublicEntries.wf3 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/cal/PublicEntries", "GET", pk, "wf3", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/Tickets','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/Tickets','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/Tickets','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  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": "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": "overview" }, { "name": "description_column" }, { "name": "created_natural" }, { "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.Tickets.detail;
    this.ls_insert_handler = Lino.tickets.Tickets.insert;
    var ww = this.containing_window;
    var id3030 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3031 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3032 = 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 topic3033 = 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_disp3034 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project3035 = 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 modified3036 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3037 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var private3038 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3039 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3040 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3041 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var site3042 = 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 description3043 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3044 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3045 = 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_of3046 = 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_user3047 = 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 state3048 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3049 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3050 = 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_for3051 = 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 reporter3052 = 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_for3053 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3054 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3055 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3056 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3057 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3058 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3059 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3060 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description3043.refresh();
      reported_for3050.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for3051.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site3042.on('change',Lino.chooser_handler(reported_for3050,'site'));
      site3042.on('change',Lino.chooser_handler(fixed_for3051,'site'));
      Lino.tickets.Tickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3030, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.Tickets.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3031, "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": user3032, "filter": { "type": "string" }, "header": "Autor", "sortable": false, "tooltip": "(tickets.Tickets.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic3033, "filter": { "type": "string" }, "header": "Teema", "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": project3035, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "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": "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": 9, "dataIndex": "priority", "editable": true, "editor": priority3039, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "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": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time3041, "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": 12, "dataIndex": "site", "editable": true, "editor": site3042, "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": 13, "dataIndex": "description", "editable": true, "editor": description3043, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3044, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3045, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3046, "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": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3047, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "state", "editable": true, "editor": state3048, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline3049, "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": 20, "dataIndex": "reported_for", "editable": true, "editor": reported_for3050, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3051, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "reporter", "editable": true, "editor": reporter3052, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3053, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.Tickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.Tickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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();
};
Lino.tickets.Tickets.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.Tickets.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/Tickets", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/PublicTickets','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/PublicTickets','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/PublicTickets','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Avalikud lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  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": "user" }, 'userHidden', { "name": "private", "type": "boolean" }, { "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": "workflow_buttons" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 6,
  ls_grid_configs : [  ],
  content_type : 42,
  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_disp3062 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var ticket_type3063 = 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 topic3064 = 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 priority3065 = new Ext.form.NumberField({ "allowBlank": false, "selectOnFocus": true, "value": 100 });
    var id3066 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified3067 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3068 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var user3069 = 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 private3070 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var closed3071 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3072 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3073 = 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 site3074 = 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 summary3075 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description3076 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3077 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var duplicate_of3078 = 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_user3079 = 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 state3080 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3081 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3082 = 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_for3083 = 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 reporter3084 = 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_for3085 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3086 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3087 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3088 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3089 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3090 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3091 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3092 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      description3076.refresh();
      reported_for3082.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for3083.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site3074.on('change',Lino.chooser_handler(reported_for3082,'site'));
      site3074.on('change',Lino.chooser_handler(fixed_for3083,'site'));
      Lino.tickets.PublicTickets.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "sortable": false, "tooltip": "(tickets.PublicTickets.overview) ", "width": Lino.chars2width(51) }, { "colIndex": 1, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3063, "filter": { "type": "string" }, "header": "Lipikuliik", "sortable": false, "tooltip": "(tickets.PublicTickets.ticket_type) ", "width": Lino.chars2width(11) }, { "colIndex": 2, "dataIndex": "topic", "editable": true, "editor": topic3064, "filter": { "type": "string" }, "header": "Teema", "sortable": false, "tooltip": "(tickets.PublicTickets.topic) ", "width": Lino.chars2width(11) }, { "align": "right", "colIndex": 3, "dataIndex": "priority", "editable": true, "editor": priority3065, "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": id3066, "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": "user", "editable": true, "editor": user3069, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.user) ", "width": Lino.chars2width(21) }, { "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": "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": 10, "dataIndex": "planned_time", "editable": true, "editor": planned_time3072, "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": 11, "dataIndex": "project", "editable": true, "editor": project3073, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.project) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "site", "editable": true, "editor": site3074, "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": 13, "dataIndex": "summary", "editable": true, "editor": summary3075, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description3076, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3077, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3078, "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": 17, "dataIndex": "end_user", "editable": true, "editor": end_user3079, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 18, "dataIndex": "state", "editable": true, "editor": state3080, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline3081, "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": 20, "dataIndex": "reported_for", "editable": true, "editor": reported_for3082, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3083, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "reporter", "editable": true, "editor": reporter3084, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3085, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.PublicTickets.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.PublicTickets.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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();
};
Lino.tickets.PublicTickets.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.PublicTickets.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/PublicTickets", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/Entries','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/blogs/Entries','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/Entries','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 20,
  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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "body" }, { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 56,
  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 id3094 = new Ext.form.NumberField({ "selectOnFocus": true });
    var pub_date3095 = new Lino.DateField({ "selectOnFocus": true });
    var user3096 = 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_type3097 = 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 title3098 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var owner_type3099 = 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_id3100 = 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_time3101 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var language3102 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp3103 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var workflow_buttons_disp3104 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3105 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3106 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var body3107 = new Lino.RichTextPanel({ "containing_panel": this, "selectOnFocus": true, "title": "Body" });
    this.before_row_edit = function(record) {
      owner_id3100.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body3107.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type3099.on('change',Lino.chooser_handler(owner_id3100,'owner_type'));
      Lino.blogs.Entries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3094, "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_date3095, "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": user3096, "filter": { "type": "string" }, "header": "Autor", "sortable": false, "tooltip": "(blogs.Entries.user) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "entry_type", "editable": true, "editor": entry_type3097, "filter": { "type": "string" }, "header": "Blog Entry Type", "sortable": false, "tooltip": "(blogs.Entries.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 4, "dataIndex": "title", "editable": true, "editor": title3098, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.Entries.title) ", "width": Lino.chars2width(22) }, { "colIndex": 5, "dataIndex": "owner_type", "editable": true, "editor": owner_type3099, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 6, "dataIndex": "owner_id", "editable": true, "editor": owner_id3100, "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_time3101, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.Entries.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "language", "editable": true, "editor": language3102, "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": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.Entries.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "body", "editable": true, "editor": body3107, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.Entries.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/Entries", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/LatestEntries','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/blogs/LatestEntries','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/LatestEntries','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Latest blog entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 20,
  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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "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.blogs.LatestEntries.detail;
    this.ls_insert_handler = Lino.blogs.LatestEntries.insert;
    var ww = this.containing_window;
    var pub_date3109 = new Lino.DateField({ "selectOnFocus": true });
    var title3110 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3111 = 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 id3112 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type3113 = 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_id3114 = 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 body3115 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var pub_time3116 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var entry_type3117 = 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 language3118 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp3119 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var workflow_buttons_disp3120 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3121 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3122 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      owner_id3114.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body3115.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type3113.on('change',Lino.chooser_handler(owner_id3114,'owner_type'));
      Lino.blogs.LatestEntries.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "pub_date", "editable": true, "editor": pub_date3109, "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": title3110, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.LatestEntries.title) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3111, "filter": { "type": "string" }, "header": "Autor", "sortable": false, "tooltip": "(blogs.LatestEntries.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id3112, "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_type3113, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id3114, "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": body3115, "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_time3116, "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_type3117, "filter": { "type": "string" }, "header": "Blog Entry Type", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "language", "editable": true, "editor": language3118, "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": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.LatestEntries.description_column) ", "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.LatestEntries.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/LatestEntries", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/users/Register','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/users/Register','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "print_labels", "menu_item_text": "Labels", "overflowText": "Labels", "panel_btn_handler": Lino.list_action_handler('/users/Register','print_labels','GET',Lino.get_current_grid_config), "text": "Labels", "tooltip": "Generate mailing labels for these recipients" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/users/Register','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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,
  disabled_actions_index : 61,
  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": "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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "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 : 10,
  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 username3124 = new Ext.form.TextField({ "maxLength": 30, "selectOnFocus": true });
    var profile3125 = new Lino.ChoicesFieldElement({ "forceSelection": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.users.UserTypes) });
    var first_name3126 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var last_name3127 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var id3128 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var email3129 = new Ext.form.TextField({ "hidden": true, "maxLength": 254, "selectOnFocus": true });
    var language3130 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var url3131 = new Lino.URLField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var phone3132 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gsm3133 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var fax3134 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var country3135 = 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 city3136 = 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_code3137 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var region3138 = 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 addr13139 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_prefix3140 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street3141 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var street_no3142 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var street_box3143 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var addr23144 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var name3145 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var remarks3146 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "M\u00e4rkused" });
    var title3147 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var middle_name3148 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var gender3149 = new Lino.ChoicesFieldElement({ "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": [['','<br>']].concat(Lino.system.Genders) });
    var birth_date3150 = new Lino.IncompleteDateField({ "hidden": true, "selectOnFocus": true });
    var modified3151 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3152 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var password3153 = new Ext.form.TextField({ "allowBlank": false, "hidden": true, "maxLength": 128, "selectOnFocus": true });
    var last_login3154 = new Ext.form.DisplayField({ "hidden": true, "selectOnFocus": true, "value": "<br>" });
    var timezone3155 = new Lino.SimpleRemoteComboFieldElement({ "hidden": true, "selectOnFocus": true, "store": new Lino.ComplexRemoteComboStore({ "proxy": new Ext.data.HttpProxy({ "method": "GET", "url": "/choices/users/Register/timezone" }) }) });
    var initials3156 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(10), "hidden": true, "maxLength": 10, "selectOnFocus": true });
    var callme_mode3157 = new Ext.form.Checkbox({ "checked": true, "hidden": true, "selectOnFocus": true });
    var verification_code3158 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var user_state3159 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.users.UserStates });
    var access_class3160 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.cal.AccessClasses });
    var event_type3161 = 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_ticket3162 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var notify_myself3163 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var mail_mode3164 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.notify.MailModes });
    var about_me_htmlbox3165 = 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_disp3166 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3167 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3168 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3169 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3170 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var age_disp3171 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var mti_navigator_disp3172 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var address_column_disp3173 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    this.before_row_edit = function(record) {
      city3136.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      city3136.setContextValue('region', record ? record.data['regionHidden'] : undefined);
      region3138.setContextValue('country', record ? record.data['countryHidden'] : undefined);
      remarks3146.refresh();
      timezone3155.setContextValue('partner', record ? record.data['partner'] : undefined);
      about_me_htmlbox3165.refresh();
    };
    this.onRender = function(ct, position) {
      country3135.on('change',Lino.chooser_handler(city3136,'country'));
      region3138.on('change',Lino.chooser_handler(city3136,'region'));
      country3135.on('change',Lino.chooser_handler(region3138,'country'));
      Lino.users.Register.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "username", "editable": true, "editor": username3124, "filter": { "type": "string" }, "header": "Kasutajanimi", "sortable": true, "tooltip": "(users.Register.username) ", "width": Lino.chars2width(22) }, { "colIndex": 1, "dataIndex": "profile", "editable": true, "editor": profile3125, "filter": { "type": "string" }, "header": "Kasutajaliik", "sortable": false, "tooltip": "(users.Register.profile) ", "width": Lino.chars2width(26) }, { "colIndex": 2, "dataIndex": "first_name", "editable": true, "editor": first_name3126, "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_name3127, "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": id3128, "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": email3129, "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": language3130, "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": url3131, "filter": { "type": "string" }, "header": "URL", "hidden": true, "sortable": true, "tooltip": "(users.Register.url) ", "width": Lino.chars2width(22) }, { "colIndex": 8, "dataIndex": "phone", "editable": true, "editor": phone3132, "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": gsm3133, "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": fax3134, "filter": { "type": "string" }, "header": "Fax", "hidden": true, "sortable": true, "tooltip": "(users.Register.fax) ", "width": Lino.chars2width(22) }, { "colIndex": 11, "dataIndex": "country", "editable": true, "editor": country3135, "filter": { "type": "string" }, "header": "Riik", "hidden": true, "sortable": false, "tooltip": "(users.Register.country) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "city", "editable": true, "editor": city3136, "filter": { "type": "string" }, "header": "Linn", "hidden": true, "sortable": false, "tooltip": "(users.Register.city) A pointer to Place.", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "zip_code", "editable": true, "editor": zip_code3137, "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": region3138, "filter": { "type": "string" }, "header": "Maakond", "hidden": true, "sortable": false, "tooltip": "(users.Register.region) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "addr1", "editable": true, "editor": addr13139, "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_prefix3140, "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": street3141, "filter": { "type": "string" }, "header": "Street", "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_no3142, "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_box3143, "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": addr23144, "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": name3145, "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": remarks3146, "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": title3147, "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_name3148, "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": gender3149, "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_date3150, "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": "modified", "editable": false, "header": "Muudatud", "hidden": true, "sortable": true, "tooltip": "(users.Register.modified) ", "width": Lino.chars2width(17) }, { "colIndex": 28, "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": 29, "dataIndex": "password", "editable": true, "editor": password3153, "filter": { "type": "string" }, "header": "password", "hidden": true, "sortable": true, "tooltip": "(users.Register.password) ", "width": Lino.chars2width(22) }, { "colIndex": 30, "dataIndex": "last_login", "editable": true, "editor": last_login3154, "header": "last login", "hidden": true, "sortable": true, "tooltip": "(users.Register.last_login) ", "width": Lino.chars2width(17) }, { "colIndex": 31, "dataIndex": "timezone", "editable": true, "editor": timezone3155, "filter": { "type": "string" }, "header": "Time zone", "hidden": true, "sortable": false, "tooltip": "(users.Register.timezone) ", "width": Lino.chars2width(11) }, { "colIndex": 32, "dataIndex": "initials", "editable": true, "editor": initials3156, "filter": { "type": "string" }, "header": "Initials", "hidden": true, "sortable": true, "tooltip": "(users.Register.initials) ", "width": Lino.chars2width(12) }, { "colIndex": 33, "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": 34, "dataIndex": "verification_code", "editable": true, "editor": verification_code3158, "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": 35, "dataIndex": "user_state", "editable": true, "editor": user_state3159, "filter": { "type": "string" }, "header": "User state", "hidden": true, "sortable": false, "tooltip": "(users.Register.user_state) The registration state of this user.", "width": Lino.chars2width(12) }, { "colIndex": 36, "dataIndex": "access_class", "editable": true, "editor": access_class3160, "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": 37, "dataIndex": "event_type", "editable": true, "editor": event_type3161, "filter": { "type": "string" }, "header": "Default Event Type", "hidden": true, "sortable": false, "tooltip": "(users.Register.event_type) The default event type for your calendar events.", "width": Lino.chars2width(21) }, { "colIndex": 38, "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": 39, "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": 40, "dataIndex": "mail_mode", "editable": true, "editor": mail_mode3164, "filter": { "type": "string" }, "header": "Email notification mode", "hidden": true, "sortable": false, "tooltip": "(users.Register.mail_mode) ", "width": Lino.chars2width(10) }, { "colIndex": 41, "dataIndex": "about_me", "editable": false, "header": "About me", "hidden": true, "sortable": false, "tooltip": "(users.Register.about_me) ", "width": Lino.chars2width(31) }, { "colIndex": 42, "dataIndex": "name_column", "editable": false, "header": "Nimi", "hidden": true, "sortable": false, "tooltip": "(users.Register.name_column) ", "width": Lino.chars2width(16) }, { "colIndex": 43, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(users.Register.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 44, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(users.Register.overview) ", "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": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(users.Register.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 47, "dataIndex": "age", "editable": false, "header": "Vanus", "hidden": true, "sortable": false, "tooltip": "(users.Register.age) ", "width": Lino.chars2width(31) }, { "colIndex": 48, "dataIndex": "mti_navigator", "editable": false, "header": "N\u00e4ita kui ", "hidden": true, "sortable": false, "tooltip": "(users.Register.mti_navigator) ", "width": Lino.chars2width(31) }, { "colIndex": 49, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "GET", pk, "as_pdf_p", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.users.Register.print_labels = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/users/Register", "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.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: [  ],
  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.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.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.detailPanel = Ext.extend(Lino.users.Users.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/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 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/DuplicatesByTicket','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/DuplicatesByTicket','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/DuplicatesByTicket','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Duplicates",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "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": "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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "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 : 42,
  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 id1405 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary1406 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var modified1407 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created1408 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var user1409 = 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 private1410 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority1411 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed1412 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time1413 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project1414 = 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 site1415 = 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 topic1416 = 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 description1417 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes1418 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type1419 = 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_user1420 = 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 state1421 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline1422 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for1423 = 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_for1424 = 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 reporter1425 = 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_for1426 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback1427 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby1428 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp1429 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp1430 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1431 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1432 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1433 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp1434 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var duplicate_of1435 = 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) {
      description1417.refresh();
      reported_for1423.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for1424.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site1415.on('change',Lino.chooser_handler(reported_for1423,'site'));
      site1415.on('change',Lino.chooser_handler(fixed_for1424,'site'));
      Lino.tickets.DuplicatesByTicket.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id1405, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary1406, "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": "user", "editable": true, "editor": user1409, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.user) ", "width": Lino.chars2width(21) }, { "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" }, { "align": "right", "colIndex": 6, "dataIndex": "priority", "editable": true, "editor": priority1411, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "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": 8, "dataIndex": "planned_time", "editable": true, "editor": planned_time1413, "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": 9, "dataIndex": "project", "editable": true, "editor": project1414, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.project) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "site", "editable": true, "editor": site1415, "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": 11, "dataIndex": "topic", "editable": true, "editor": topic1416, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "description", "editable": true, "editor": description1417, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes1418, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type1419, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "end_user", "editable": true, "editor": end_user1420, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 16, "dataIndex": "state", "editable": true, "editor": state1421, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.state) ", "width": Lino.chars2width(12) }, { "colIndex": 17, "dataIndex": "deadline", "editable": true, "editor": deadline1422, "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": 18, "dataIndex": "reported_for", "editable": true, "editor": reported_for1423, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for1424, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "reporter", "editable": true, "editor": reporter1425, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for1426, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.DuplicatesByTicket.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 23, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.overview) ", "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": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.DuplicatesByTicket.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of1435, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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();
};
Lino.tickets.DuplicatesByTicket.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.DuplicatesByTicket.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/DuplicatesByTicket", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByEndUser','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByEndUser','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByEndUser','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  ls_store_fields : [ { "name": "overview" }, { "name": "workflow_buttons" }, { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "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": "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": "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 : 42,
  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_disp1820 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var workflow_buttons_disp1821 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var id1822 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified1823 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created1824 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var user1825 = 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 private1826 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority1827 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed1828 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time1829 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project1830 = 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 site1831 = 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 topic1832 = 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 summary1833 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var description1834 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes1835 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type1836 = 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_of1837 = 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 state1838 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline1839 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for1840 = 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_for1841 = 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 reporter1842 = 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_for1843 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback1844 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby1845 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp1846 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp1847 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1848 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp1849 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var end_user1850 = 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) {
      description1834.refresh();
      reported_for1840.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for1841.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site1831.on('change',Lino.chooser_handler(reported_for1840,'site'));
      site1831.on('change',Lino.chooser_handler(fixed_for1841,'site'));
      Lino.tickets.TicketsByEndUser.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "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": id1822, "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": "user", "editable": true, "editor": user1825, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.user) ", "width": Lino.chars2width(21) }, { "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" }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority1827, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "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": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time1829, "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": 10, "dataIndex": "project", "editable": true, "editor": project1830, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site1831, "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": 12, "dataIndex": "topic", "editable": true, "editor": topic1832, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "summary", "editable": true, "editor": summary1833, "filter": { "type": "string" }, "header": "Summary", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.summary) Short summary of the problem.", "width": Lino.chars2width(22) }, { "colIndex": 14, "dataIndex": "description", "editable": true, "editor": description1834, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.description) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes1835, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 16, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type1836, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of1837, "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": 18, "dataIndex": "state", "editable": true, "editor": state1838, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.state) ", "width": Lino.chars2width(12) }, { "colIndex": 19, "dataIndex": "deadline", "editable": true, "editor": deadline1839, "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": 20, "dataIndex": "reported_for", "editable": true, "editor": reported_for1840, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for1841, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "reporter", "editable": true, "editor": reporter1842, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 23, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for1843, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByEndUser.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 24, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 26, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByEndUser.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "end_user", "editable": true, "editor": end_user1850, "filter": { "type": "string" }, "header": "End user", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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.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.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();
};
Lino.tickets.TicketsByEndUser.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByEndUser.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByEndUser", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByType','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByType','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByType','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  ls_store_fields : [ { "name": "summary" }, { "name": "state" }, 'stateHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "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": "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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "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 : 42,
  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 summary2763 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var state2764 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var id2765 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified2766 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created2767 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var user2768 = 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 private2769 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority2770 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed2771 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time2772 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project2773 = 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 site2774 = 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 topic2775 = 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 description2776 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes2777 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var duplicate_of2778 = 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_user2779 = 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 deadline2780 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for2781 = 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_for2782 = 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 reporter2783 = 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_for2784 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback2785 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby2786 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp2787 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp2788 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp2789 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp2790 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp2791 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp2792 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var ticket_type2793 = 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) {
      description2776.refresh();
      reported_for2781.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for2782.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site2774.on('change',Lino.chooser_handler(reported_for2781,'site'));
      site2774.on('change',Lino.chooser_handler(fixed_for2782,'site'));
      Lino.tickets.TicketsByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "summary", "editable": true, "editor": summary2763, "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": state2764, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(tickets.TicketsByType.state) ", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id2765, "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": "user", "editable": true, "editor": user2768, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.user) ", "width": Lino.chars2width(21) }, { "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" }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority2770, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "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": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time2772, "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": 10, "dataIndex": "project", "editable": true, "editor": project2773, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site2774, "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": 12, "dataIndex": "topic", "editable": true, "editor": topic2775, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 13, "dataIndex": "description", "editable": true, "editor": description2776, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.description) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes2777, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 15, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of2778, "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": 16, "dataIndex": "end_user", "editable": true, "editor": end_user2779, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "deadline", "editable": true, "editor": deadline2780, "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": 18, "dataIndex": "reported_for", "editable": true, "editor": reported_for2781, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for2782, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "reporter", "editable": true, "editor": reporter2783, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for2784, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByType.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 23, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.overview) ", "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": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByType.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type2793, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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.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.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();
};
Lino.tickets.TicketsByType.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByType.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByType", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByTopic','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByTopic','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByTopic','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Lipikud",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  ls_store_fields : [ { "name": "summary" }, { "name": "state" }, 'stateHidden', { "name": "id", "type": "int" }, { "name": "modified" }, { "name": "created" }, { "name": "user" }, 'userHidden', { "name": "private", "type": "boolean" }, { "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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "topic" }, 'topicHidden', { "name": "disabled_fields" }, { "name": "disabled_actions" }, { "name": "disable_editing" } ],
  pk_index : 3,
  ls_grid_configs : [  ],
  content_type : 42,
  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 summary1320 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var state1321 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var id1322 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var modified1323 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created1324 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var user1325 = 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 private1326 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority1327 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed1328 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time1329 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project1330 = 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 site1331 = 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 description1332 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes1333 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type1334 = 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_of1335 = 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_user1336 = 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 deadline1337 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for1338 = 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_for1339 = 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 reporter1340 = 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_for1341 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback1342 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby1343 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp1344 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp1345 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp1346 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1347 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1348 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp1349 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var topic1350 = 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) {
      description1332.refresh();
      reported_for1338.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for1339.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site1331.on('change',Lino.chooser_handler(reported_for1338,'site'));
      site1331.on('change',Lino.chooser_handler(fixed_for1339,'site'));
      Lino.tickets.TicketsByTopic.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "summary", "editable": true, "editor": summary1320, "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": state1321, "filter": { "type": "string" }, "header": "Staatus", "sortable": false, "tooltip": "(tickets.TicketsByTopic.state) ", "width": Lino.chars2width(12) }, { "align": "right", "colIndex": 2, "dataIndex": "id", "editable": true, "editor": id1322, "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": "user", "editable": true, "editor": user1325, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.user) ", "width": Lino.chars2width(21) }, { "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" }, { "align": "right", "colIndex": 7, "dataIndex": "priority", "editable": true, "editor": priority1327, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 8, "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": 9, "dataIndex": "planned_time", "editable": true, "editor": planned_time1329, "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": 10, "dataIndex": "project", "editable": true, "editor": project1330, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.project) ", "width": Lino.chars2width(21) }, { "colIndex": 11, "dataIndex": "site", "editable": true, "editor": site1331, "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": 12, "dataIndex": "description", "editable": true, "editor": description1332, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes1333, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type1334, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of1335, "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": 16, "dataIndex": "end_user", "editable": true, "editor": end_user1336, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "deadline", "editable": true, "editor": deadline1337, "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": 18, "dataIndex": "reported_for", "editable": true, "editor": reported_for1338, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 19, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for1339, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "reporter", "editable": true, "editor": reporter1340, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for1341, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByTopic.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 23, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.overview) ", "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": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByTopic.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "topic", "editable": true, "editor": topic1350, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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.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.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();
};
Lino.tickets.TicketsByTopic.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByTopic.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByTopic", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsFixed','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsFixed','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsFixed','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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 : 42,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "modified" }, { "name": "created" }, { "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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "fixed_for" }, 'fixed_forHidden', { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 42,
  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 id3175 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3176 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3177 = 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 modified3178 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3179 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var private3180 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3181 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3182 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3183 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3184 = 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 site3185 = 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 topic3186 = 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 description3187 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3188 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3189 = 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_of3190 = 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_user3191 = 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 state3192 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3193 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3194 = 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 reporter3195 = 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_for3196 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3197 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3198 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3199 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3200 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3201 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3202 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3203 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3204 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var fixed_for3205 = 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) {
      description3187.refresh();
    };
    this.onRender = function(ct, position) {
      site3185.on('change',Lino.chooser_handler(reported_for3194,'site'));
      site3185.on('change',Lino.chooser_handler(fixed_for3205,'site'));
      Lino.tickets.TicketsFixed.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3175, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsFixed.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3176, "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": user3177, "filter": { "type": "string" }, "header": "Autor", "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": "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": 6, "dataIndex": "priority", "editable": true, "editor": priority3181, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "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": 8, "dataIndex": "planned_time", "editable": true, "editor": planned_time3183, "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": 9, "dataIndex": "project", "editable": true, "editor": project3184, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.project) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "site", "editable": true, "editor": site3185, "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": 11, "dataIndex": "topic", "editable": true, "editor": topic3186, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "description", "editable": true, "editor": description3187, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3188, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3189, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3190, "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": 16, "dataIndex": "end_user", "editable": true, "editor": end_user3191, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "state", "editable": true, "editor": state3192, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.state) ", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline3193, "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": 19, "dataIndex": "reported_for", "editable": true, "editor": reported_for3194, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "reporter", "editable": true, "editor": reporter3195, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3196, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsFixed.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 23, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.overview) ", "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": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsFixed.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3205, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "as_pdf_p", 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();
};
Lino.tickets.TicketsFixed.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsFixed.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsFixed", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsReported','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsReported','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsReported','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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 : 42,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "user" }, 'userHidden', { "name": "modified" }, { "name": "created" }, { "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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "reported_for" }, 'reported_forHidden', { "name": "disabled_actions" } ],
  pk_index : 0,
  ls_grid_configs : [  ],
  content_type : 42,
  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 id3207 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3208 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3209 = 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 modified3210 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3211 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var private3212 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3213 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3214 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3215 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3216 = 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 site3217 = 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 topic3218 = 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 description3219 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3220 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3221 = 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_of3222 = 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_user3223 = 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 state3224 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3225 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var fixed_for3226 = 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 reporter3227 = 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_for3228 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3229 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3230 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3231 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3232 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var workflow_buttons_disp3233 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3234 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3235 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3236 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var reported_for3237 = 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) {
      description3219.refresh();
    };
    this.onRender = function(ct, position) {
      site3217.on('change',Lino.chooser_handler(fixed_for3226,'site'));
      site3217.on('change',Lino.chooser_handler(reported_for3237,'site'));
      Lino.tickets.TicketsReported.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3207, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsReported.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3208, "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": user3209, "filter": { "type": "string" }, "header": "Autor", "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": "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": 6, "dataIndex": "priority", "editable": true, "editor": priority3213, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "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": 8, "dataIndex": "planned_time", "editable": true, "editor": planned_time3215, "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": 9, "dataIndex": "project", "editable": true, "editor": project3216, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.project) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "site", "editable": true, "editor": site3217, "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": 11, "dataIndex": "topic", "editable": true, "editor": topic3218, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "description", "editable": true, "editor": description3219, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3220, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3221, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3222, "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": 16, "dataIndex": "end_user", "editable": true, "editor": end_user3223, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "state", "editable": true, "editor": state3224, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.state) ", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline3225, "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": 19, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3226, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "reporter", "editable": true, "editor": reporter3227, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3228, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsReported.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 22, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 23, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 25, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.overview) ", "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": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsReported.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "reported_for", "editable": true, "editor": reported_for3237, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "as_pdf_p", 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();
};
Lino.tickets.TicketsReported.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsReported.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsReported", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByReporter','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByReporter','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsByReporter','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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,
  disabled_actions_index : 43,
  ls_store_fields : [ { "name": "id", "type": "int" }, { "name": "summary" }, { "name": "workflow_buttons" }, { "name": "modified" }, { "name": "created" }, { "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": "overview" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "user" }, 'userHidden', { "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.TicketsByReporter.detail;
    this.ls_insert_handler = Lino.tickets.TicketsByReporter.insert;
    var ww = this.containing_window;
    var id3239 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3240 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var workflow_buttons_disp3241 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var modified3242 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3243 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var private3244 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3245 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3246 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3247 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var project3248 = 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 site3249 = 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 topic3250 = 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 description3251 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3252 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3253 = 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_of3254 = 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_user3255 = 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 state3256 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3257 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3258 = 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_for3259 = 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 reporter3260 = 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_for3261 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3262 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3263 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3264 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3265 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3266 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3267 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3268 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var user3269 = 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) {
      description3251.refresh();
      reported_for3258.setContextValue('site', record ? record.data['siteHidden'] : undefined);
      fixed_for3259.setContextValue('site', record ? record.data['siteHidden'] : undefined);
    };
    this.onRender = function(ct, position) {
      site3249.on('change',Lino.chooser_handler(reported_for3258,'site'));
      site3249.on('change',Lino.chooser_handler(fixed_for3259,'site'));
      Lino.tickets.TicketsByReporter.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3239, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsByReporter.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3240, "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": "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": 6, "dataIndex": "priority", "editable": true, "editor": priority3245, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 7, "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": 8, "dataIndex": "planned_time", "editable": true, "editor": planned_time3247, "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": 9, "dataIndex": "project", "editable": true, "editor": project3248, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.project) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "site", "editable": true, "editor": site3249, "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": 11, "dataIndex": "topic", "editable": true, "editor": topic3250, "filter": { "type": "string" }, "header": "Teema", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.topic) ", "width": Lino.chars2width(21) }, { "colIndex": 12, "dataIndex": "description", "editable": true, "editor": description3251, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3252, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3253, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3254, "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": 16, "dataIndex": "end_user", "editable": true, "editor": end_user3255, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "state", "editable": true, "editor": state3256, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.state) ", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline3257, "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": 19, "dataIndex": "reported_for", "editable": true, "editor": reported_for3258, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3259, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter3260, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3261, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsByReporter.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsByReporter.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "user", "editable": true, "editor": user3269, "filter": { "type": "string" }, "header": "Autor", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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.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.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();
};
Lino.tickets.TicketsByReporter.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsByReporter.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsByReporter", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsBySite','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsBySite','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/tickets/TicketsBySite','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Known problems",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 43,
  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": "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": "overview" }, { "name": "description_column" }, { "name": "created_natural" }, { "name": "site" }, 'siteHidden', { "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.TicketsBySite.detail;
    this.ls_insert_handler = Lino.tickets.TicketsBySite.insert;
    var ww = this.containing_window;
    var id3271 = new Ext.form.NumberField({ "selectOnFocus": true });
    var summary3272 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3273 = 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 topic3274 = 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_disp3275 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project3276 = 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 modified3277 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var created3278 = new Ext.form.DisplayField({ "disabled": true, "hidden": true, "value": "<br>" });
    var private3279 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var priority3280 = new Ext.form.NumberField({ "allowBlank": false, "hidden": true, "selectOnFocus": true, "value": 100 });
    var closed3281 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var planned_time3282 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var description3283 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Kirjeldus" });
    var upgrade_notes3284 = new Ext.form.TextArea({ "growMax": 2000, "hidden": true, "selectOnFocus": true });
    var ticket_type3285 = 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_of3286 = 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_user3287 = 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 state3288 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "hidden": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var deadline3289 = new Lino.DateField({ "hidden": true, "selectOnFocus": true });
    var reported_for3290 = 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_for3291 = 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 reporter3292 = 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_for3293 = new Ext.form.TextField({ "hidden": true, "maxLength": 200, "selectOnFocus": true });
    var feedback3294 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var standby3295 = new Ext.form.Checkbox({ "checked": false, "hidden": true, "selectOnFocus": true });
    var needed_skills_disp3296 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var suppliers_disp3297 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3298 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3299 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var created_natural_disp3300 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var site3301 = 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) {
      description3283.refresh();
      var bp = this.get_base_params();
      reported_for3290.setContextValue('mk',bp['mk']);
      reported_for3290.setContextValue('mt',bp['mt']);
      var bp = this.get_base_params();
      fixed_for3291.setContextValue('mk',bp['mk']);
      fixed_for3291.setContextValue('mt',bp['mt']);
    };
    this.onRender = function(ct, position) {
      site3301.on('change',Lino.chooser_handler(reported_for3290,'site'));
      site3301.on('change',Lino.chooser_handler(fixed_for3291,'site'));
      Lino.tickets.TicketsBySite.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "align": "right", "colIndex": 0, "dataIndex": "id", "editable": true, "editor": id3271, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(tickets.TicketsBySite.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "summary", "editable": true, "editor": summary3272, "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": user3273, "filter": { "type": "string" }, "header": "Autor", "sortable": false, "tooltip": "(tickets.TicketsBySite.user) ", "width": Lino.chars2width(11) }, { "colIndex": 3, "dataIndex": "topic", "editable": true, "editor": topic3274, "filter": { "type": "string" }, "header": "Teema", "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": project3276, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "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": "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": 9, "dataIndex": "priority", "editable": true, "editor": priority3280, "filter": { "type": "numeric" }, "format": "0", "header": "Priority", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.priority) ", "width": Lino.chars2width(6) }, { "colIndex": 10, "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": 11, "dataIndex": "planned_time", "editable": true, "editor": planned_time3282, "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": 12, "dataIndex": "description", "editable": true, "editor": description3283, "filter": { "type": "string" }, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.description) ", "width": Lino.chars2width(61) }, { "colIndex": 13, "dataIndex": "upgrade_notes", "editable": true, "editor": upgrade_notes3284, "filter": { "type": "string" }, "header": "Resolution", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.upgrade_notes) ", "width": Lino.chars2width(61) }, { "colIndex": 14, "dataIndex": "ticket_type", "editable": true, "editor": ticket_type3285, "filter": { "type": "string" }, "header": "Lipikuliik", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.ticket_type) ", "width": Lino.chars2width(21) }, { "colIndex": 15, "dataIndex": "duplicate_of", "editable": true, "editor": duplicate_of3286, "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": 16, "dataIndex": "end_user", "editable": true, "editor": end_user3287, "filter": { "type": "string" }, "header": "End user", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.end_user) ", "width": Lino.chars2width(21) }, { "colIndex": 17, "dataIndex": "state", "editable": true, "editor": state3288, "filter": { "type": "string" }, "header": "Staatus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.state) ", "width": Lino.chars2width(12) }, { "colIndex": 18, "dataIndex": "deadline", "editable": true, "editor": deadline3289, "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": 19, "dataIndex": "reported_for", "editable": true, "editor": reported_for3290, "filter": { "type": "string" }, "header": "Reported for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.reported_for) Milestone for which this ticket has been reported.", "width": Lino.chars2width(21) }, { "colIndex": 20, "dataIndex": "fixed_for", "editable": true, "editor": fixed_for3291, "filter": { "type": "string" }, "header": "Fixed for", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.fixed_for) The milestone for which this ticket has been fixed.", "width": Lino.chars2width(21) }, { "colIndex": 21, "dataIndex": "reporter", "editable": true, "editor": reporter3292, "filter": { "type": "string" }, "header": "Reporter", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.reporter) ", "width": Lino.chars2width(21) }, { "colIndex": 22, "dataIndex": "waiting_for", "editable": true, "editor": waiting_for3293, "filter": { "type": "string" }, "header": "Waiting for", "hidden": true, "sortable": true, "tooltip": "(tickets.TicketsBySite.waiting_for) ", "width": Lino.chars2width(22) }, { "colIndex": 23, "dataIndex": "feedback", "editable": true, "filter": { "type": "boolean" }, "header": "Feedback", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.feedback) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 24, "dataIndex": "standby", "editable": true, "filter": { "type": "boolean" }, "header": "Standby", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.standby) ", "width": Lino.chars2width(11), "xtype": "checkcolumn" }, { "colIndex": 25, "dataIndex": "needed_skills", "editable": false, "header": "Needed skills", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.needed_skills) ", "width": Lino.chars2width(31) }, { "colIndex": 26, "dataIndex": "suppliers", "editable": false, "header": "Suppliers", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.suppliers) ", "width": Lino.chars2width(31) }, { "colIndex": 27, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 28, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 29, "dataIndex": "created_natural", "editable": false, "header": "Loodud", "hidden": true, "sortable": false, "tooltip": "(tickets.TicketsBySite.created_natural) ", "width": Lino.chars2width(31) }, { "colIndex": 30, "dataIndex": "site", "editable": true, "editor": site3301, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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.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.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();
};
Lino.tickets.TicketsBySite.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.tickets.TicketsBySite.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/tickets/TicketsBySite", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/clocking/TicketsByReport','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/clocking/TicketsByReport','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/clocking/TicketsByReport','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "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 : 42,
  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 id3303 = new Ext.form.NumberField({ "selectOnFocus": true });
    var overview_disp3304 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "value": "<br/>" });
    var project3305 = 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 state3306 = new Lino.ChoicesFieldElement({ "allowBlank": false, "forceSelection": true, "selectOnFocus": true, "store": Lino.tickets.TicketStates });
    var vc03307 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc13308 = new Ext.form.TextField({ "boxMinWidth": Lino.chars2width(6), "disabled": true, "maxLength": 6 });
    var vc23309 = 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": id3303, "filter": { "type": "numeric" }, "format": "0", "header": "ID", "sortable": true, "tooltip": "(clocking.TicketsByReport.id) ", "width": Lino.chars2width(6) }, { "colIndex": 1, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "sortable": false, "tooltip": "(clocking.TicketsByReport.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 2, "dataIndex": "project", "editable": true, "editor": project3305, "filter": { "type": "string" }, "header": "Eesm\u00e4rk", "sortable": false, "tooltip": "(clocking.TicketsByReport.project) ", "width": Lino.chars2width(21) }, { "colIndex": 3, "dataIndex": "state", "editable": true, "editor": state3306, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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();
};
Lino.clocking.TicketsByReport.wf1 = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "wf1", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.mark_talk = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "mark_talk", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.mark_opened = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "mark_opened", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.mark_started = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "mark_started", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.mark_ready = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "mark_ready", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.mark_closed = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "mark_closed", params, null);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.clocking.TicketsByReport.mark_refused = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/clocking/TicketsByReport", "GET", pk, "mark_refused", 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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByType','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByType','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByType','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 20,
  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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "entry_type" }, 'entry_typeHidden', { "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.blogs.EntriesByType.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByType.insert;
    var ww = this.containing_window;
    var pub_date1620 = new Lino.DateField({ "selectOnFocus": true });
    var title1621 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user1622 = 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 id1623 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type1624 = 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_id1625 = 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 body1626 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var pub_time1627 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var language1628 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var owner_disp1629 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    var workflow_buttons_disp1630 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp1631 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp1632 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var entry_type1633 = 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_id1625.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body1626.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type1624.on('change',Lino.chooser_handler(owner_id1625,'owner_type'));
      Lino.blogs.EntriesByType.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "pub_date", "editable": true, "editor": pub_date1620, "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": title1621, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.EntriesByType.title) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user1622, "filter": { "type": "string" }, "header": "Autor", "sortable": false, "tooltip": "(blogs.EntriesByType.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id1623, "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_type1624, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id1625, "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": body1626, "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_time1627, "header": "Publication time", "hidden": true, "sortable": true, "tooltip": "(blogs.EntriesByType.pub_time) ", "width": Lino.chars2width(9) }, { "colIndex": 8, "dataIndex": "language", "editable": true, "editor": language1628, "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": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByType.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "dataIndex": "entry_type", "editable": true, "editor": entry_type1633, "filter": { "type": "string" }, "header": "Blog Entry Type", "hidden": true, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByType.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByType", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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.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" }, { "iconCls": "x-tbar-page_white_acrobat", "menu": [ { "auto_save": true, "itemId": "as_pdf", "menu_item_text": "Table (landscape)", "overflowText": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByController','as_pdf','GET',Lino.get_current_grid_config), "text": "Table (landscape)", "tooltip": "Show this table as a pdf document" }, { "auto_save": true, "itemId": "as_pdf_p", "menu_item_text": "Table (portrait)", "overflowText": "Table (portrait)", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByController','as_pdf_p','GET',Lino.get_current_grid_config), "text": "Table (portrait)", "tooltip": "Show this table as a pdf document" } ], "menu_item_text": "Table (landscape)", "panel_btn_handler": Lino.list_action_handler('/blogs/EntriesByController','as_pdf','GET',Lino.get_current_grid_config), "text": null, "xtype": "splitbutton" }, { "auto_save": true, "iconCls": "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-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 : "Blog Entries",
  page_length : 20,
  params_panel_hidden : true,
  stripeRows : true,
  disabled_actions_index : 20,
  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": "workflow_buttons" }, { "name": "overview" }, { "name": "description_column" }, { "name": "owner" }, { "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.blogs.EntriesByController.detail;
    this.ls_insert_handler = Lino.blogs.EntriesByController.insert;
    var ww = this.containing_window;
    var pub_date3311 = new Lino.DateField({ "selectOnFocus": true });
    var title3312 = new Ext.form.TextField({ "maxLength": 200, "selectOnFocus": true });
    var user3313 = 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 id3314 = new Ext.form.NumberField({ "hidden": true, "selectOnFocus": true });
    var owner_type3315 = 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_id3316 = 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 body3317 = new Lino.RichTextPanel({ "containing_panel": this, "hidden": true, "selectOnFocus": true, "title": "Body" });
    var pub_time3318 = new Lino.TimeField({ "hidden": true, "selectOnFocus": true });
    var entry_type3319 = 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 language3320 = new Lino.ChoicesFieldElement({ "hidden": true, "selectOnFocus": true, "store": [ [ "en", "inglise" ], [ "et", "eesti" ] ] });
    var workflow_buttons_disp3321 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var overview_disp3322 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var description_column_disp3323 = new Ext.form.DisplayField({ "always_enabled": true, "disabled": true, "hidden": true, "value": "<br/>" });
    var owner_disp3324 = new Ext.form.DisplayField({ "disabled": true, "hidden": true });
    this.before_row_edit = function(record) {
      owner_id3316.setContextValue('owner_type', record ? record.data['owner_typeHidden'] : undefined);
      body3317.refresh();
    };
    this.onRender = function(ct, position) {
      owner_type3315.on('change',Lino.chooser_handler(owner_id3316,'owner_type'));
      Lino.blogs.EntriesByController.GridPanel.superclass.onRender.call(this, ct, position);
    }
    this.ls_columns = [ { "colIndex": 0, "dataIndex": "pub_date", "editable": true, "editor": pub_date3311, "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": title3312, "filter": { "type": "string" }, "header": "Heading", "sortable": true, "tooltip": "(blogs.EntriesByController.title) ", "width": Lino.chars2width(22) }, { "colIndex": 2, "dataIndex": "user", "editable": true, "editor": user3313, "filter": { "type": "string" }, "header": "Autor", "sortable": false, "tooltip": "(blogs.EntriesByController.user) ", "width": Lino.chars2width(21) }, { "align": "right", "colIndex": 3, "dataIndex": "id", "editable": true, "editor": id3314, "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_type3315, "filter": { "type": "string" }, "header": "Controlled by (type)", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.owner_type) ", "width": Lino.chars2width(21) }, { "colIndex": 5, "dataIndex": "owner_id", "editable": true, "editor": owner_id3316, "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": body3317, "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_time3318, "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_type3319, "filter": { "type": "string" }, "header": "Blog Entry Type", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.entry_type) ", "width": Lino.chars2width(21) }, { "colIndex": 9, "dataIndex": "language", "editable": true, "editor": language3320, "filter": { "type": "string" }, "header": "Keel", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.language) ", "width": Lino.chars2width(21) }, { "colIndex": 10, "dataIndex": "workflow_buttons", "editable": false, "header": "Actions", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.workflow_buttons) ", "width": Lino.chars2width(31) }, { "colIndex": 11, "dataIndex": "overview", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.overview) ", "width": Lino.chars2width(31) }, { "colIndex": 12, "dataIndex": "description_column", "editable": false, "header": "Kirjeldus", "hidden": true, "sortable": false, "tooltip": "(blogs.EntriesByController.description_column) ", "width": Lino.chars2width(31) }, { "colIndex": 13, "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.as_pdf = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "as_pdf", params, Lino.get_current_grid_config);
  };
  var panel = Ext.getCmp(rp);
  if(panel) panel.do_when_clean(true, h); else h();
};
Lino.blogs.EntriesByController.as_pdf_p = function(rp, pk, params) { 
  var h = function() { 
    Lino.run_row_action(rp, "/blogs/EntriesByController", "GET", pk, "as_pdf_p", 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: [  ],
  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: [  ],
  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();
};

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);
});
