define(function (require, exports, module) { var BaseBiz = require('system/base/biz'); function Biz(dict) { BaseBiz.call(this, dict); } inherits(Biz, BaseBiz); Biz.prototype.initialize = function () { this.dsMaster.onlySaveCurrent = true; }; Biz.prototype.doOp = function (opCode) { var self = this; if (opCode === 'exportmysqlscript') { self.openScriptWindow({ type: 'mysql' }); } if (opCode === 'exportoraclescript') { self.openScriptWindow({ type: 'oracle' }); } this.super('doOp', opCode); } Biz.prototype.openScriptWindow = function (params) { if (!this.dsMaster.currentRow) { Store.messager.err('当前行不能为空'); return; } var ScriptWin = require('./scriptwin5'); var win = new ScriptWin({ dataRow: this.dsMaster.currentRow, scriptType: params.type }); win.open(); return; } Biz.prototype.getOpEnabled = function (opCode) { if (opCode == 'export') { return this.isEdit(); } return this.super('getOpEnabled', opCode); }; return Biz; })