gx.evt.autoSkip=false;function timt080(){this.ServerClass="TImt080";this.PackageName="";this.setObjectType("trn");this.hasEnterEvent=true;this.SetStandaloneVars=function(){this.Gx_BScreen=gx.fn.getIntegerValue("vGXBSCREEN",".");this.Gx_mode=gx.fn.getControlValue("vMODE");this.A184DcpCodAbre=gx.fn.getControlValue("DCPCODABRE")};this.Valid_Docnro=function(){try{var a=gx.util.balloon.getNew("DOCNRO");this.AnyError=0}catch(b){}try{if(a==null){return true}return a.show()}catch(b){}return true};this.Valid_Undcod=function(){try{var a=gx.util.balloon.getNew("UNDCOD");
this.AnyError=0}catch(b){}try{if(a==null){return true}return a.show()}catch(b){}return true};this.Valid_Doenrosequ=function(){gx.ajax.validSrvEvt("dyncall","valid_Doenrosequ",["gx.O.A258DocNro","gx.O.A922UndCod","gx.O.A281DoeNroSequ"],["Gx_mode","Z258DocNro","Z922UndCod","Z281DoeNroSequ","Grid1",["BTN_GET","Enabled"],["BUTTON1","Enabled"]]);return true};this.Valid_Curcod=function(){this.sMode63=this.Gx_mode;this.Gx_mode=gx.fn.getGridRowMode(63,51);this.standaloneModal4463();this.standaloneNotModal4463();
gx.ajax.validSrvEvt("dyncall","valid_Curcod",["gx.O.A169CurCod","gx.O.A170CurNom"],["A170CurNom"]);this.Gx_mode=this.sMode63;return true};this.Valid_Dcpnro=function(){this.sMode63=this.Gx_mode;this.Gx_mode=gx.fn.getGridRowMode(63,51);if(gx.fn.currentGridRowImpl(51)===0){return true}var a=gx.util.balloon.getNew("DCPNRO",gx.fn.currentGridRowImpl(51));if(gx.fn.gridDuplicateKey(54)){a.setError(gx.text.format(gx.getMessage("GXM_1004"),"Level1"));this.AnyError=1;return a.show()}gx.ajax.validSrvEvt("dyncall","valid_Dcpnro",["gx.O.A169CurCod","gx.O.A186DcpNro","gx.O.A184DcpCodAbre","gx.O.A185DcpNom"],["A184DcpCodAbre","A185DcpNom"]);
this.Gx_mode=this.sMode63;return true};this.standaloneModal4463=function(){try{if((this.Gx_mode=="INS")&&(""==this.A182DceTipBibl)&&this.Gx_BScreen==0){this.A182DceTipBibl="B"}}catch(a){}try{if(this.Gx_mode!="INS"){gx.fn.setCtrlProperty("CURCOD","Enabled",0)}else{gx.fn.setCtrlProperty("CURCOD","Enabled",1)}}catch(a){}try{if(this.Gx_mode!="INS"){gx.fn.setCtrlProperty("DCPNRO","Enabled",0)}else{gx.fn.setCtrlProperty("DCPNRO","Enabled",1)}}catch(a){}return true};this.standaloneNotModal4463=function(){return true
};this.e114445_client=function(){this.clearMessages();gx.popup.openUrl(gx.http.formatLink("himh014",[this.A258DocNro,this.A922UndCod]),["A258DocNro","A922UndCod"]);this.refreshOutputs([])};this.e13442_client=function(){this.executeServerEvent("'REPLICAR'",false)};this.e14442_client=function(){this.executeServerEvent("'VOLTAR'",false)};this.e154445_client=function(){this.executeServerEvent("ENTER",true)};this.e164445_client=function(){this.executeServerEvent("CANCEL",true)};this.GXValidFnc=[];this.GXCtrlIds=[3,22,24,27,30,32,35,37,40,42,45,52,53,54,55,56,57];
this.GXLastCtrlId=57;this.Grid1Container=new gx.grid.grid(this,63,"Level1",51,"Grid1","Grid1","Grid1Container",this.CmpContext,this.IsMasterPage,"timt080",[169,186],false,1,false,true,5,false,false,false,"",0,"px","Novo registro",true,false,false,null,null,false,"");this.Grid1Container.addSingleLineEdit("nRcdDeleted_63",52,"vNRCDDELETED_63","Apagar","","nRcdDeleted_63","int",0,"px",4,4,"right",null,[],"nRcdDeleted_63","nRcdDeleted_63",true,0,false,false);this.Grid1Container.addSingleLineEdit(169,53,"CURCOD","Curso","","CurCod","int",0,"px",5,5,"right",null,[],169,"CurCod",true,0,false,false);
this.Grid1Container.addBitmap("prompt_169","PROMPT_169",58,0,"",0,"",null,"","");this.Grid1Container.addSingleLineEdit(186,54,"DCPNRO","Disciplina","","DcpNro","int",0,"px",4,4,"right",null,[],186,"DcpNro",true,0,false,false);this.Grid1Container.addBitmap("prompt_186","PROMPT_186",59,0,"",0,"",null,"","");this.Grid1Container.addComboBox(182,55,"DCETIPBIBL","Bibliografia","DceTipBibl","char",null,0,true,false,0,"px");this.Grid1Container.addSingleLineEdit(170,56,"CURNOM","Nome do curso","","CurNom","char",0,"px",100,100,"left",null,[],170,"CurNom",true,0,false,false);
this.Grid1Container.addSingleLineEdit(185,57,"DCPNOM","Nome da disciplina","","DcpNom","char",0,"px",80,80,"left",null,[],185,"DcpNom",true,0,false,false);this.setGrid(this.Grid1Container);this.GXValidFnc[3]={fld:"TABLE3",grid:0};this.GXValidFnc[22]={fld:"TEXTBLOCK4",format:0,grid:0};this.GXValidFnc[24]={fld:"TABLE1",grid:0};this.GXValidFnc[27]={fld:"TABLE2",grid:0};this.GXValidFnc[30]={fld:"TEXTBLOCK1",format:0,grid:0};this.GXValidFnc[32]={lvl:0,type:"int",len:6,dec:0,sign:false,pic:"ZZZZZ9",ro:1,grid:0,gxgrid:null,fnc:this.Valid_Docnro,isvalid:null,rgrid:[this.Grid1Container],fld:"DOCNRO",gxz:"Z258DocNro",gxold:"O258DocNro",gxvar:"A258DocNro",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A258DocNro=gx.num.intval(a)
},v2z:function(a){gx.O.Z258DocNro=gx.num.intval(a)},v2c:function(){gx.fn.setControlValue("DOCNRO",gx.O.A258DocNro,0)},c2v:function(){gx.O.A258DocNro=this.val()},val:function(){return gx.fn.getIntegerValue("DOCNRO",".")},nac:function(){return false}};this.GXValidFnc[35]={fld:"TEXTBLOCK2",format:0,grid:0};this.GXValidFnc[37]={lvl:0,type:"int",len:3,dec:0,sign:false,pic:"ZZ9",ro:1,grid:0,gxgrid:null,fnc:this.Valid_Undcod,isvalid:null,rgrid:[this.Grid1Container],fld:"UNDCOD",gxz:"Z922UndCod",gxold:"O922UndCod",gxvar:"A922UndCod",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A922UndCod=gx.num.intval(a)
},v2z:function(a){gx.O.Z922UndCod=gx.num.intval(a)},v2c:function(){gx.fn.setControlValue("UNDCOD",gx.O.A922UndCod,0)},c2v:function(){gx.O.A922UndCod=this.val()},val:function(){return gx.fn.getIntegerValue("UNDCOD",".")},nac:function(){return false}};this.GXValidFnc[40]={fld:"TEXTBLOCK3",format:0,grid:0};this.GXValidFnc[42]={fld:"TABLE4",grid:0};this.GXValidFnc[45]={lvl:0,type:"int",len:4,dec:0,sign:false,pic:"ZZZ9",ro:1,grid:0,gxgrid:null,fnc:this.Valid_Doenrosequ,isvalid:null,rgrid:[this.Grid1Container],fld:"DOENROSEQU",gxz:"Z281DoeNroSequ",gxold:"O281DoeNroSequ",gxvar:"A281DoeNroSequ",ucs:[],op:[],ip:[45,37,32],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A281DoeNroSequ=gx.num.intval(a)
},v2z:function(a){gx.O.Z281DoeNroSequ=gx.num.intval(a)},v2c:function(){gx.fn.setControlValue("DOENROSEQU",gx.O.A281DoeNroSequ,0)},c2v:function(){gx.O.A281DoeNroSequ=this.val()},val:function(){return gx.fn.getIntegerValue("DOENROSEQU",".")},nac:function(){return false}};this.GXValidFnc[52]={lvl:63,type:"int",len:4,dec:0,sign:false,pic:"9999",ro:0,grid:51,gxgrid:this.Grid1Container,fnc:null,isvalid:null,rgrid:[],fld:"vNRCDDELETED_63",gxz:"ZnRcdDeleted_63",gxold:"OnRcdDeleted_63",gxvar:"nRcdDeleted_63",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.nRcdDeleted_63=gx.num.intval(a)
},v2z:function(a){gx.O.ZnRcdDeleted_63=gx.num.intval(a)},v2c:function(){gx.fn.setGridControlValue("vNRCDDELETED_63",gx.fn.currentGridRowImpl(51),gx.O.nRcdDeleted_63,0)},c2v:function(){gx.O.nRcdDeleted_63=this.val()},val:function(){return gx.fn.getGridIntegerValue("vNRCDDELETED_63",gx.fn.currentGridRowImpl(51),".")},nac:function(){return false}};this.GXValidFnc[53]={lvl:63,type:"int",len:5,dec:0,sign:false,pic:"ZZZZ9",ro:0,grid:51,gxgrid:this.Grid1Container,fnc:this.Valid_Curcod,isvalid:null,rgrid:[],fld:"CURCOD",gxz:"Z169CurCod",gxold:"O169CurCod",gxvar:"A169CurCod",ucs:[],op:[55,56],ip:[55,56,53],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A169CurCod=gx.num.intval(a)
},v2z:function(a){gx.O.Z169CurCod=gx.num.intval(a)},v2c:function(){gx.fn.setGridControlValue("CURCOD",gx.fn.currentGridRowImpl(51),gx.O.A169CurCod,0)},c2v:function(){gx.O.A169CurCod=this.val()},val:function(){return gx.fn.getGridIntegerValue("CURCOD",gx.fn.currentGridRowImpl(51),".")},nac:function(){return false}};this.GXValidFnc[54]={lvl:63,type:"int",len:4,dec:0,sign:false,pic:"ZZZ9",ro:0,grid:51,gxgrid:this.Grid1Container,fnc:this.Valid_Dcpnro,isvalid:null,rgrid:[],fld:"DCPNRO",gxz:"Z186DcpNro",gxold:"O186DcpNro",gxvar:"A186DcpNro",ucs:[],op:[57],ip:[57,54,53],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A186DcpNro=gx.num.intval(a)
},v2z:function(a){gx.O.Z186DcpNro=gx.num.intval(a)},v2c:function(){gx.fn.setGridControlValue("DCPNRO",gx.fn.currentGridRowImpl(51),gx.O.A186DcpNro,0)},c2v:function(){gx.O.A186DcpNro=this.val()},val:function(){return gx.fn.getGridIntegerValue("DCPNRO",gx.fn.currentGridRowImpl(51),".")},nac:function(){return false}};this.GXValidFnc[55]={lvl:63,type:"char",len:1,dec:0,sign:false,ro:0,grid:51,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"DCETIPBIBL",gxz:"Z182DceTipBibl",gxold:"O182DceTipBibl",gxvar:"A182DceTipBibl",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"combo",v2v:function(a){gx.O.A182DceTipBibl=a
},v2z:function(a){gx.O.Z182DceTipBibl=a},v2c:function(){gx.fn.setGridComboBoxValue("DCETIPBIBL",gx.fn.currentGridRowImpl(51),gx.O.A182DceTipBibl)},c2v:function(){gx.O.A182DceTipBibl=this.val()},val:function(){return gx.fn.getGridControlValue("DCETIPBIBL",gx.fn.currentGridRowImpl(51))},nac:function(){return false}};this.GXValidFnc[56]={lvl:63,type:"char",len:100,dec:0,sign:false,ro:1,grid:51,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"CURNOM",gxz:"Z170CurNom",gxold:"O170CurNom",gxvar:"A170CurNom",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A170CurNom=a
},v2z:function(a){gx.O.Z170CurNom=a},v2c:function(){gx.fn.setGridControlValue("CURNOM",gx.fn.currentGridRowImpl(51),gx.O.A170CurNom,0)},c2v:function(){gx.O.A170CurNom=this.val()},val:function(){return gx.fn.getGridControlValue("CURNOM",gx.fn.currentGridRowImpl(51))},nac:function(){return false}};this.GXValidFnc[57]={lvl:63,type:"char",len:80,dec:0,sign:false,ro:1,grid:51,gxgrid:this.Grid1Container,fnc:null,isvalid:null,fld:"DCPNOM",gxz:"Z185DcpNom",gxold:"O185DcpNom",gxvar:"A185DcpNom",ucs:[],op:[],ip:[],nacdep:[],ctrltype:"edit",v2v:function(a){gx.O.A185DcpNom=a
},v2z:function(a){gx.O.Z185DcpNom=a},v2c:function(){gx.fn.setGridControlValue("DCPNOM",gx.fn.currentGridRowImpl(51),gx.O.A185DcpNom,0)},c2v:function(){gx.O.A185DcpNom=this.val()},val:function(){return gx.fn.getGridControlValue("DCPNOM",gx.fn.currentGridRowImpl(51))},nac:function(){return false}};this.A258DocNro=0;this.Z258DocNro=0;this.O258DocNro=0;this.A922UndCod=0;this.Z922UndCod=0;this.O922UndCod=0;this.A281DoeNroSequ=0;this.Z281DoeNroSequ=0;this.O281DoeNroSequ=0;this.ZnRcdDeleted_63=0;this.OnRcdDeleted_63=0;
this.Z169CurCod=0;this.O169CurCod=0;this.Z186DcpNro=0;this.O186DcpNro=0;this.Z182DceTipBibl="";this.O182DceTipBibl="";this.Z170CurNom="";this.O170CurNom="";this.Z185DcpNom="";this.O185DcpNom="";this.A169CurCod=0;this.A186DcpNro=0;this.A182DceTipBibl="";this.A170CurNom="";this.A184DcpCodAbre="";this.A185DcpNom="";this.AV9UsuCodCorr="";this.Gx_msg="";this.AV13OrigemCurso="";this.Gx_BScreen=0;this.ServerEvents=["e13442_client","e14442_client","e154445_client","e164445_client"];this.setPrompt("PROMPT_169",[53]);
this.setPrompt("PROMPT_186",[54]);this.EnterCtrl=["BUTTON1"];this.VarControlMap.Gx_BScreen={id:"vGXBSCREEN",grid:0,type:"int"};this.VarControlMap.Gx_mode={id:"vMODE",grid:0,type:"char"};this.VarControlMap.A184DcpCodAbre={id:"DCPCODABRE",grid:51,type:"char"};this.SetStandaloneVars()}timt080.prototype=new gx.GxObject;gx.setParentObj(new timt080());