You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
DS7/DSWeb/Areas/MvcShipping/Viewsjs/Comm/DsMemo.js

90 lines
2.3 KiB
JavaScript

3 years ago
Ext.namespace('Shipping');
Shipping.DsMemo = function (config) {
Ext.applyIf(this, config);
this.initUIComponents();
Shipping.DsMemo.superclass.constructor.call(this);
};
Ext.extend(Shipping.DsMemo, Ext.Window, {
StoreList: null,
memoname: '',
start: 0,
limit: 100,
condition: '',
returnsql: null,
initUIComponents: function () {
// BEGIN OF CODE GENERATION PARTS, DON'T DELETE CODE BELOW
this.formMemo = Ext.widget('form', {
frame: true,
region: 'center',
bodyPadding: 5,
fieldDefaults: {
margins: '2 2 2 2',
labelAlign: 'right',
flex: 1,
labelWidth: 60,
msgTarget: 'qtip'
},
items: [{
xtype: 'textareafield',
grow: true,
labelWidth: 0,
height: 330,
name: 'DSMEMO',
id: 'DSMEMO',
anchor: '100%'
}],
buttons: [{
text: "确定",
id: 'btnQuery',
handler: function (button, event) {
_thisQuery.execSql();
},
scope: this
}, {
text: "关闭",
handler: function (button, event) {
var win = this.up("window");
win.close();
}
}]
});
Ext.apply(this, {
height: 350,
closable: true,
draggable: true,
defaultButton: 'btnQuery',
resizable: false,
items: [this.formMeMo],
layout: "border",
width: 480,
xtype: "window",
id: "DsMemoWin",
listeners: {
scope: this,
'beforeshow': function (thewin, eOpts) {
var memo = Ext.getCmp(this.memoname);
var dsmemo = Ext.getCmp('DSMEMO');
dsmemo.value = memo.value;
}
}
});
}, //onDeleteClick
execSql: function () {
var memo = Ext.getCmp(this.memoname);
var dsmemo = Ext.getCmp('DSMEMO');
memo.value = dsmemo.value;
var win = Ext.getCmp("DsMemoWin");
win.close();
}
});