gx.evt.autoSkip=false;function tgst106(){this.ServerClass="TGst106";this.PackageName="";this.setObjectType("trn");this.hasEnterEvent=true;this.SetStandaloneVars=function(){this.Gx_mode=gx.fn.getControlValue("vMODE")};this.Valid_Usucod=function(){gx.ajax.validSrvEvt("dyncall","valid_Usucod",["gx.O.A968UsuCod","gx.O.A983UsuNom","gx.O.A980UsuIndPriv"],["A983UsuNom","A980UsuIndPriv","Gx_mode","Z968UsuCod","Z983UsuNom","Z980UsuIndPriv","Grid1",["BTN_GET","Enabled"],["BTN_ENTER","Enabled"],["BTN_CHECK","Enabled"]]);
return true};this.Valid_Usuindpriv=function(){try{var a=gx.util.balloon.getNew("USUINDPRIV");this.AnyError=0;if(!(this.A980UsuIndPriv=="S"||this.A980UsuIndPriv=="N")){try{a.setError("Campo Privilegiado? fora da faixa");this.AnyError=1}catch(b){}}}catch(b){}try{if(a==null){return true}return a.show()}catch(b){}return true};this.Valid_Dircod=function(){this.sMode99=this.Gx_mode;this.Gx_mode=gx.fn.getGridRowMode(99,35);this.standaloneModal2H99();this.standaloneNotModal2H99();if(gx.fn.currentGridRowImpl(35)===0){return true
}var a=gx.util.balloon.getNew("DIRCOD",gx.fn.currentGridRowImpl(35));if(gx.fn.gridDuplicateKey(37)){a.setError(gx.text.format(gx.getMessage("GXM_1004"),"Level1"));this.AnyError=1;return a.show()}gx.ajax.validSrvEvt("dyncall","valid_Dircod",["gx.O.A205DirCod","gx.O.A206DirDes","gx.O.A207DirIndSegu"],["A206DirDes","A207DirIndSegu"]);this.Gx_mode=this.sMode99;return true};this.standaloneModal2H99=function(){try{if(this.Gx_mode!="INS"){gx.fn.setCtrlProperty("DIRCOD","Enabled",0)}else{gx.fn.setCtrlProperty("DIRCOD","Enabled",1)
}}catch(a){}return true};this.standaloneNotModal2H99=function(){return true};this.e112h86_client=function(){this.executeServerEvent("ENTER",true)};this.e122h86_client=function(){this.executeServerEvent("CANCEL",true)};this.GXValidFnc=[];this.GXCtrlIds=[2,15,18,20,24,26,29,31,36,37,38,39,40,41];this.GXLastCtrlId=41;this.Grid1Container=new gx.grid.grid(this,99,"Level1",35,"Grid1","Grid1","Grid1Container",this.CmpContext,this.IsMasterPage,"tgst106",[205],false,1,false,true,5,false,false,false,"",0,"px","Novo registro",true,false,false,null,null,false,"");
this.Grid1Container.addSingleLineEdit("nRcdDeleted_99",36,"vNRCDDELETED_99","","","nRcdDeleted_99","int",0,"px",4,4,"right",null,[],"nRcdDeleted_99","nRcdDeleted_99",true,0,false,false);this.Grid1Container.addSingleLineEdit(205,37,"DIRCOD","Direito","","DirCod","char",0,"px",7,7,"left",null,[],205,"DirCod",true,0,false,false);this.Grid1Container.addBitmap("prompt_205","PROMPT_205",49,0,"",0,"",null,"","");this.Grid1Container.addSingleLineEdit(206,38,"DIRDES","Descrição","","DirDes","char",0,"px",40,40,"left",null,[],206,"DirDes",true,0,false,false);
this.Grid1Container.addSingleLineEdit(207,39,"DIRINDSEGU","Tem Seguranca","","DirIndSegu","char",0,"px",2,1,"left",null,[],207,"DirIndSegu",true,0,false,false);this.Grid1Container.addSingleLineEdit(965,40,"USPINDACES","Acessa programa","","UspIndAces","char",0,"px",2,1,"left",null,[],965,"UspIndAces",true,0,false,false);this.Grid1Container.addSingleLineEdit(966,41,"USPTIPACES","Tipo de acesso","","UspTipAces","char",0,"px",2,1,"left",null,[],966,"UspTipAces",true,0,false,false);this.setGrid(this.Grid1Container);
this.GXValidFnc[2]={fld:"TABLE1",grid:0};this.GXValidFnc[15]={fld:"TABLE2",grid:0};this.GXValidFnc[18]={fld:"TEXTBLOCK1",format:0,grid:0};this.GXValidFnc[20]={lvl:0,type:"char",len:6,dec:0,sign:false,ro:0,grid:0,gxgrid:null,fnc:this.Valid_Usucod,isvalid:null,fld:"USUCOD",gxz:"Z968UsuCod",gxold:"O968UsuCod",gxvar:"A968UsuCod",ucs:[],op:[31,26],ip:[31,26,20],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A968UsuCod=a},v2z:function(a){gx.O.Z968UsuCod=a},v2c:function(){gx.fn.setControlValue("USUCOD",gx.O.A968UsuCod,0)
},c2v:function(){gx.O.A968UsuCod=this.val()},val:function(){return gx.fn.getControlValue("USUCOD")},nac:function(){return false}};this.GXValidFnc[24]={fld:"TEXTBLOCK2",format:0,grid:0};this.GXValidFnc[26]={lvl:0,type:"char",len:50,dec:0,sign:false,ro:0,grid:0,gxgrid:null,fnc:null,isvalid:null,fld:"USUNOM",gxz:"Z983UsuNom",gxold:"O983UsuNom",gxvar:"A983UsuNom",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A983UsuNom=a},v2z:function(a){gx.O.Z983UsuNom=a},v2c:function(){gx.fn.setControlValue("USUNOM",gx.O.A983UsuNom,0)
},c2v:function(){gx.O.A983UsuNom=this.val()},val:function(){return gx.fn.getControlValue("USUNOM")},nac:function(){return false}};this.GXValidFnc[29]={fld:"TEXTBLOCK3",format:0,grid:0};this.GXValidFnc[31]={lvl:0,type:"char",len:1,dec:0,sign:false,ro:0,grid:0,gxgrid:null,fnc:this.Valid_Usuindpriv,isvalid:null,fld:"USUINDPRIV",gxz:"Z980UsuIndPriv",gxold:"O980UsuIndPriv",gxvar:"A980UsuIndPriv",ucs:[],op:[31],ip:[31],nacdep:[],ctrltype:"combo",v2v:function(a){gx.O.A980UsuIndPriv=a},v2z:function(a){gx.O.Z980UsuIndPriv=a
},v2c:function(){gx.fn.setComboBoxValue("USUINDPRIV",gx.O.A980UsuIndPriv)},c2v:function(){gx.O.A980UsuIndPriv=this.val()},val:function(){return gx.fn.getControlValue("USUINDPRIV")},nac:function(){return false}};this.GXValidFnc[36]={lvl:99,type:"int",len:4,dec:0,sign:false,pic:"9999",ro:0,grid:35,gxgrid:this.Grid1Container,fnc:null,isvalid:null,rgrid:[],fld:"vNRCDDELETED_99",gxz:"ZnRcdDeleted_99",gxold:"OnRcdDeleted_99",gxvar:"nRcdDeleted_99",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.nRcdDeleted_99=gx.num.intval(a)
},v2z:function(a){gx.O.ZnRcdDeleted_99=gx.num.intval(a)},v2c:function(){gx.fn.setGridControlValue("vNRCDDELETED_99",gx.fn.currentGridRowImpl(35),gx.O.nRcdDeleted_99,0)},c2v:function(){gx.O.nRcdDeleted_99=this.val()},val:function(){return gx.fn.getGridIntegerValue("vNRCDDELETED_99",gx.fn.currentGridRowImpl(35),".")},nac:function(){return false}};this.GXValidFnc[37]={lvl:99,type:"char",len:7,dec:0,sign:false,ro:0,grid:35,gxgrid:this.Grid1Container,fnc:this.Valid_Dircod,isvalid:null,fld:"DIRCOD",gxz:"Z205DirCod",gxold:"O205DirCod",gxvar:"A205DirCod",ucs:[],op:[39,38],ip:[39,38,37],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A205DirCod=a
},v2z:function(a){gx.O.Z205DirCod=a},v2c:function(){gx.fn.setGridControlValue("DIRCOD",gx.fn.currentGridRowImpl(35),gx.O.A205DirCod,0)},c2v:function(){gx.O.A205DirCod=this.val()},val:function(){return gx.fn.getGridControlValue("DIRCOD",gx.fn.currentGridRowImpl(35))},nac:function(){return false}};this.GXValidFnc[38]={lvl:99,type:"char",len:40,dec:0,sign:false,ro:1,grid:35,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"DIRDES",gxz:"Z206DirDes",gxold:"O206DirDes",gxvar:"A206DirDes",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A206DirDes=a
},v2z:function(a){gx.O.Z206DirDes=a},v2c:function(){gx.fn.setGridControlValue("DIRDES",gx.fn.currentGridRowImpl(35),gx.O.A206DirDes,0)},c2v:function(){gx.O.A206DirDes=this.val()},val:function(){return gx.fn.getGridControlValue("DIRDES",gx.fn.currentGridRowImpl(35))},nac:function(){return false}};this.GXValidFnc[39]={lvl:99,type:"char",len:1,dec:0,sign:false,ro:1,grid:35,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"DIRINDSEGU",gxz:"Z207DirIndSegu",gxold:"O207DirIndSegu",gxvar:"A207DirIndSegu",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A207DirIndSegu=a
},v2z:function(a){gx.O.Z207DirIndSegu=a},v2c:function(){gx.fn.setGridControlValue("DIRINDSEGU",gx.fn.currentGridRowImpl(35),gx.O.A207DirIndSegu,0)},c2v:function(){gx.O.A207DirIndSegu=this.val()},val:function(){return gx.fn.getGridControlValue("DIRINDSEGU",gx.fn.currentGridRowImpl(35))},nac:function(){return false}};this.GXValidFnc[40]={lvl:99,type:"char",len:1,dec:0,sign:false,ro:0,grid:35,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"USPINDACES",gxz:"Z965UspIndAces",gxold:"O965UspIndAces",gxvar:"A965UspIndAces",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A965UspIndAces=a
},v2z:function(a){gx.O.Z965UspIndAces=a},v2c:function(){gx.fn.setGridControlValue("USPINDACES",gx.fn.currentGridRowImpl(35),gx.O.A965UspIndAces,0)},c2v:function(){gx.O.A965UspIndAces=this.val()},val:function(){return gx.fn.getGridControlValue("USPINDACES",gx.fn.currentGridRowImpl(35))},nac:function(){return false}};this.GXValidFnc[41]={lvl:99,type:"char",len:1,dec:0,sign:false,ro:0,grid:35,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"USPTIPACES",gxz:"Z966UspTipAces",gxold:"O966UspTipAces",gxvar:"A966UspTipAces",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A966UspTipAces=a
},v2z:function(a){gx.O.Z966UspTipAces=a},v2c:function(){gx.fn.setGridControlValue("USPTIPACES",gx.fn.currentGridRowImpl(35),gx.O.A966UspTipAces,0)},c2v:function(){gx.O.A966UspTipAces=this.val()},val:function(){return gx.fn.getGridControlValue("USPTIPACES",gx.fn.currentGridRowImpl(35))},nac:function(){return false}};this.A968UsuCod="";this.Z968UsuCod="";this.O968UsuCod="";this.A983UsuNom="";this.Z983UsuNom="";this.O983UsuNom="";this.A980UsuIndPriv="";this.Z980UsuIndPriv="";this.O980UsuIndPriv="";this.ZnRcdDeleted_99=0;
this.OnRcdDeleted_99=0;this.Z205DirCod="";this.O205DirCod="";this.Z206DirDes="";this.O206DirDes="";this.Z207DirIndSegu="";this.O207DirIndSegu="";this.Z965UspIndAces="";this.O965UspIndAces="";this.Z966UspTipAces="";this.O966UspTipAces="";this.A205DirCod="";this.A206DirDes="";this.A207DirIndSegu="";this.A965UspIndAces="";this.A966UspTipAces="";this.ServerEvents=["e112h86_client","e122h86_client"];this.setPrompt("PROMPT_205",[37]);this.EnterCtrl=["BTN_ENTER"];this.CheckCtrl=["BTN_CHECK"];this.VarControlMap.Gx_mode={id:"vMODE",grid:0,type:"char"};
this.SetStandaloneVars()}tgst106.prototype=new gx.GxObject;gx.setParentObj(new tgst106());