📄 dc0040.js
字号:
this.fields.add("IS_INSERTED", new Ext.ux.form.XCheckbox ({xtype: "xcheckbox",name:"IS_INSERTED",id:"DC0040F_IS_INSERTED",dataIndex:"IS_INSERTED",width:50,allowBlank:true,fieldLabel: this.resourceBundle.FieldLabel.IS_INSERTED||"Is_inserted",insert_allowed:true,update_allowed:true}) );
this.fields.add("IS_POSTED", new Ext.ux.form.XCheckbox ({xtype: "xcheckbox",name:"IS_POSTED",id:"DC0040F_IS_POSTED",dataIndex:"IS_POSTED",width:50,allowBlank:true,fieldLabel: this.resourceBundle.FieldLabel.IS_POSTED||"Is_posted",insert_allowed:true,update_allowed:true}) );
this.fields.add("CREATEDON", new Ext.form.DateField ({xtype: "datefield",name:"CREATEDON",id:"DC0040F_CREATEDON",dataIndex:"CREATEDON",width:100,allowBlank:false,labelSeparator:":*" ,fieldLabel: this.resourceBundle.FieldLabel.CREATEDON||"CreatedOn",disabled:true,format:Ext.DATE_FORMAT}) );
this.fields.add("CREATEDBY", new Ext.form.TextField ({xtype: "textfield",name:"CREATEDBY",id:"DC0040F_CREATEDBY",dataIndex:"CREATEDBY",width:80,allowBlank:false,labelSeparator:":*" ,fieldLabel: this.resourceBundle.FieldLabel.CREATEDBY||"CreatedBy",disabled:true}) );
this.fields.add("MODIFIEDON", new Ext.form.DateField ({xtype: "datefield",name:"MODIFIEDON",id:"DC0040F_MODIFIEDON",dataIndex:"MODIFIEDON",width:100,allowBlank:false,labelSeparator:":*" ,fieldLabel: this.resourceBundle.FieldLabel.MODIFIEDON||"ModifiedOn",disabled:true,format:Ext.DATE_FORMAT}) );
this.fields.add("MODIFIEDBY", new Ext.form.TextField ({xtype: "textfield",name:"MODIFIEDBY",id:"DC0040F_MODIFIEDBY",dataIndex:"MODIFIEDBY",width:80,allowBlank:false,labelSeparator:":*" ,fieldLabel: this.resourceBundle.FieldLabel.MODIFIEDBY||"ModifiedBy",disabled:true}) );
this.fields.add("POSTEDON", new Ext.form.DateField ({xtype: "datefield",name:"POSTEDON",id:"DC0040F_POSTEDON",dataIndex:"POSTEDON",width:100,allowBlank:true,fieldLabel: this.resourceBundle.FieldLabel.POSTEDON||"Postedon",disabled:true,format:Ext.DATE_FORMAT}) );
this.fields.add("POSTEDBY", new Ext.form.TextField ({xtype: "textfield",name:"POSTEDBY",id:"DC0040F_POSTEDBY",dataIndex:"POSTEDBY",width:80,allowBlank:false,labelSeparator:":*" ,fieldLabel: this.resourceBundle.FieldLabel.POSTEDBY||"Postedby",disabled:true}) );
this.layoutItems.add("DC0042",
new Ext.Window({ xtype:"window", modal:true, title:N21.DataComp.DC0042.prototype.resourceBundle.DcProperty.Title, closeAction:"hide",closable:true,layout:"fit", width:600, height:500, items:{xtype:"DC0042",id:"DC0042", parentDcRelation:{name:"DC0040F",relation:[{parent:"ID",child:"ACCDOC_ID"}]} }} ) );
this.layoutItems.add("Processing",
{ xtype:"fieldset", title:this.resourceBundle.FieldsetTitle.Processing||"Processing",autoHeight:true,collapsible: true,width:"90%",items:[ this.fields.get("IS_GENERATED"),this.fields.get("IS_INSERTED"),this.fields.get("IS_POSTED")]});
this.layoutItems.add("Modified",
{ xtype:"fieldset", title:this.resourceBundle.FieldsetTitle.Modified||"Modified",autoHeight:true,collapsible: true,collapsed:true,width:"90%",items:[ this.fields.get("CREATEDON"),this.fields.get("CREATEDBY"),this.fields.get("MODIFIEDON"),this.fields.get("MODIFIEDBY"),this.fields.get("POSTEDON"),this.fields.get("POSTEDBY")]});
this.layoutItems.add("C2",
{ layout:"form",columnWidth:.5, items:[ this.layoutItems.get("Processing"),this.layoutItems.get("Modified")]});
this.layoutItems.add("C1",
{ layout:"form",columnWidth:.5, items:[ this.fields.get("ID"),this.fields.get("CLIENT_ID"),this.fields.get("CLIENT_NAME"),this.fields.get("ACCPERIOD_NAME"),this.fields.get("DOC_NO"),this.fields.get("DOC_DATE"),this.fields.get("BASEDOC_TYPE"),this.fields.get("BASEDOC_NO"),this.fields.get("BASEDOC_DATE"),this.fields.get("BASEDOC_ID"),this.fields.get("NOTES")]});
Ext.apply(this, {
items:[this.fields.get("_p_record_status"),this.layoutItems.get("C1"),this.layoutItems.get("C2")]
,border:false
,layout:"column"
,defaults:{labelWidth:110}
,frame:true
,width: "100%"
,dataComponentName:"DC0040F"
,firstFocusFieldName:"DOC_NO"
,childDCs: [{name:"DC0042",relation:[{parent:"ID",child:"ACCDOC_ID"}]}]
,buttons: [{xtype:"button",text:"AccdocItems",scope:this,handler:function() {this.show_window("DC0042");} }]
,buttonAlign:"left"
,toolbarConfig:"STANDARD"
});
N21.DataComp.DC0040F.superclass.initComponent.apply(this, arguments);
}
,onRender:function() {
N21.DataComp.DC0040F.superclass.onRender.apply(this, arguments);
}
,newDataRecord:function() {
return new this.dataRecordMeta({_p_record_status:"insert"
,ID:""
,CLIENT_ID:""
,CLIENT_NAME:""
,ACCPERIOD_NAME:""
,DB_AMOUNT:""
,CR_AMOUNT:""
,DOC_NO:""
,DOC_DATE:""
,BASEDOC_TYPE:""
,BASEDOC_NO:""
,BASEDOC_DATE:""
,BASEDOC_ID:""
,NOTES:""
,IS_GENERATED:""
,IS_INSERTED:""
,IS_POSTED:""
,CREATEDON:""
,CREATEDBY:""
,MODIFIEDON:""
,MODIFIEDBY:""
,POSTEDON:""
,POSTEDBY:""});
}
,change_CLIENT_ID:function(fld, newVal, oldVal) {
this.getField("ACCPERIOD_NAME").setParamValue("p_client_id",newVal);
this.getField("ACCPERIOD_NAME").setValue("");
}
});
Ext.reg("DC0040F", N21.DataComp.DC0040F);
/**
* DataControl: Grid with Edit Form
* Code: DC0040
* Title: Accounting doc.
*/
Ext.ns("N21.DataComp");
N21.DataComp.DC0040 = Ext.extend(N21.Base.GridEditForm, {
initComponent:function() {
Ext.apply(this, {
autoScroll:false
,layout:"border"
,dataComponentName:"DC0040"
,masterName:"DC0040G"
,detailName:"DC0040F"
,mdLayout:"card"
,border: false
,items: [
{
xtype:"panel"
,layout:"card"
,id:"MDTab"
,region:"center"
,defaults:{layout:"fit"}
,activeItem:0
,tabPosition: "bottom"
,items: [{
xtype: "DC0040G"
,id: "DC0040G"
,height:350
},{
xtype:"DC0040F"
,id:"DC0040F"
,height:350
,frame:true
,autoScroll:true
,layout:"form"
}]
}
]
,tbar: new Array(
new Ext.Toolbar.Button({ id:"tlb_FILTER" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/g_rec_src.png" ,tooltip:"Apply filter" ,handler: this.executeQuery ,scope :this})
,new Ext.Toolbar.Separator()
,new Ext.Toolbar.Button({ id:"tlb_SAVE" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/g_rec_commit.png" ,tooltip:"Save changes <Ctrl+S>" ,handler: this.commitForm ,scope :this})
,new Ext.Toolbar.Button({ id:"tlb_NEW" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/g_rec_new.png" ,tooltip:"Create new record <Ctrl+N>" ,handler: this.createNewRecord ,scope :this})
,new Ext.Toolbar.Button({ id:"tlb_DELETE" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/g_rec_del.png" ,tooltip:"Delete record <Ctrl+D>" ,handler: this.deleteRecord ,scope :this})
,new Ext.Toolbar.Separator()
,new Ext.Toolbar.Button({ id:"tlb_LIST_EDITOR_MODE" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/g_rec_upd.png" ,tooltip:"Editor<Enter>, List<Ctrl+Q>" ,handler: this.toggleEditMode ,scope :this})
,new Ext.Toolbar.Button({ id:"tlb_REFRESH_RECORD" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/g_rec_refresh.gif" ,tooltip:"Refresh record" ,handler: this.reloadRecord ,scope :this})
,new Ext.Toolbar.Separator()
,new Ext.Toolbar.Button({ id:"tlb_PREV_REC" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/f_rec_prev.gif" ,tooltip:"Previous record" ,handler: this.goToPrevRecord ,scope :this})
,new Ext.Toolbar.Button({ id:"tlb_NEXT_REC" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/f_rec_next.gif" ,tooltip:"Next record" ,handler: this.goToNextRecord ,scope :this})
,new Ext.Toolbar.Separator()
,new Ext.Toolbar.Button({ id:"tlb_PRINT" ,xtype:"button" ,cls:"x-btn-icon" ,icon:"_static/icon/print.png" ,tooltip:"Print list" ,handler: this.exportList ,scope :this})
)
});
N21.DataComp.DC0040.superclass.initComponent.apply(this, arguments);
}
});
Ext.reg("DC0040", N21.DataComp.DC0040);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -