You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
57 lines
1.6 KiB
57 lines
1.6 KiB
define(function (require, exports, module) {
|
|
let BaseBiz = require('apps/rht/base/rhtBiz');
|
|
/**
|
|
* 控制按钮的可用
|
|
* @param opCode 按钮编码
|
|
* @return [description]
|
|
*/
|
|
|
|
function Biz(vm) {
|
|
//继承第一步,构造继承
|
|
BaseBiz.call(this, vm);
|
|
vm.remark =''
|
|
}
|
|
|
|
//继承第二步,方法继承
|
|
inherits(Biz, BaseBiz);
|
|
/*
|
|
//按钮事件控制
|
|
Biz.prototype.doOp = function (opCode) {
|
|
let self = this;
|
|
if (opCode == 'pladd') {
|
|
this.onpladd("1");
|
|
}
|
|
};
|
|
//控制主界面按钮状态
|
|
Biz.prototype.getOpEnabled = function (opCode) {
|
|
let isOk = this.super('getOpEnabled', opCode);
|
|
if (!isOk) {
|
|
return false;
|
|
}
|
|
let curRow = this.dsMaster.currentRow;
|
|
if (opCode == 'pladd'){
|
|
if (!curRow)
|
|
return false;
|
|
|
|
if (!this.isEdit())
|
|
return false;
|
|
}
|
|
return true;
|
|
};
|
|
//批量增加
|
|
Biz.prototype.onpladd = function (sType) {
|
|
let curHRow = this.dsMaster.currentRow;
|
|
let sBillNo = curHRow ? TypeUtil.toString(curHRow['BillNo']) : '';
|
|
let ret= Service.getSlideMenuData("actExecute","onacc", sBillNo,sType,"","","");
|
|
if (ret.result !== 1) {
|
|
Store.messager.err(ret.message);
|
|
return false;
|
|
}
|
|
|
|
this.dsMaster.updateRow();
|
|
Store.messager.tip("处理成功!");
|
|
return true;
|
|
};
|
|
*/
|
|
return Biz;
|
|
}); |