Commit 53930fc8 by qiaoyanqi

代码优化

parent 968f104e
......@@ -29,6 +29,13 @@ export default {
} else {
GAMS.Common.messagePrompt('请在单据中录入数据');
}
c.$nextTick(()=>{
component.addListener({
close: function() {
GMS.$hideContainer.remove(name);
}
});
})
});
} else {
GAMS.Common.messagePrompt('缺少参数');
......
......@@ -29,6 +29,13 @@ export default {
c.modal_visible = true;
GMS.editSubIndex = bill.getSubFocus();
console.log('param',param,obj);
c.$nextTick(()=>{
component.addListener({
close: function() {
GMS.$hideContainer.remove(name);
}
});
})
});
} else {
GAMS.Common.messagePrompt('缺少参数');
......
......@@ -30,7 +30,13 @@ export default {
c.billId = obj[BILLID];
c.subBillData = obj.BILLDETAILOBJ;
c.modal_visible = true;
console.log('param',param,obj);
c.$nextTick(()=>{
component.addListener({
close: function() {
GMS.$hideContainer.remove(name);
}
});
})
});
} else {
GAMS.Common.messagePrompt('无详情参数');
......
......@@ -7,7 +7,6 @@ export default {
let BILLID = param.param.billId||'BILLID';
let BILLNAME = param.param.billName||'BILLNAME';
let BILLEDITNAME = param.param.billDefineName||'BILLEDITNAME';
GMS.showDetailAction = true;//详情,点击确定按钮。记录此参数
component = c;
c.bill = bill;
......@@ -32,7 +31,13 @@ export default {
c.billId = obj[BILLID];
c.subBillData = obj.BILLDETAILOBJ;
c.modal_visible = true;
console.log('param',param,obj);
c.$nextTick(()=>{
component.addListener({
close: function() {
GMS.$hideContainer.remove(name);
}
});
})
});
} else {
GAMS.Common.messagePrompt('无详情参数');
......
......@@ -614,7 +614,6 @@ export default {
path: billPath,
});
window.open(routeData.href, "_blank");
//this.close();
},
handleAddAssetsSave() {
this.chekData(
......
......@@ -198,24 +198,6 @@ export default {
this.hasFocus = true
this.getBaseDataList()
},
// handleBlur() {
// if (!this.onResultList) {
// this.hasFocus = false
// this.dataListShow = false
// }
// this.selectValue = String(this.selectValue)
// if (this.value === null) {
// this.selectValue = ''
// this.selectIndex = -1
// this.selectedItem = {}
// } else {
// this.selectValue = this.value.name
// this.selectedItem = this.value
// this.findIndex()
// }
// this.$emit('data-change', this.value)
// },
// 输入查询时
handleChange() {
if (this.selectValue === '' || this.selectValue === null) {
......
......@@ -110,7 +110,21 @@ export default {
.catch((XMLHttpRequest, textStatus, errorThrown) => {});
},
handleCancel() {
this.close();
},
addListener(l) {
this.listener = l;
},
close() {
this.modal_visible = false;
if (this.listener) {
this.$nextTick(
function() {
this.$destroy();
this.listener.close();
}.bind(this)
);
}
},
},
watch: {},
......
......@@ -2,9 +2,7 @@ import mcon from './mcon';
import emcon from './emcon';
import './styles/common/normalize.less'
import Vue from 'vue';
// import ElementUI from 'element-ui';
import { Popover } from 'element-ui';
// import 'element-ui/lib/theme-chalk/index.css';
Vue.use(Popover)
export default {
install: function(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment