| | |
| | | <template> |
| | | <el-dialog |
| | | width="60%" |
| | | title="参数" |
| | | title="新增" |
| | | top="5vh" |
| | | :visible.sync="innerVisible" |
| | | :show="currshowlist" |
| | |
| | | > |
| | | <ttable |
| | | :table="table" |
| | | @handleSelectionChange="handleSelectionChange" |
| | | @currentChange="Getdata" |
| | | :prelang="prelang" |
| | | :options="options" |
| | | :ajaxFun="ajaxFun" |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | datalistid:"", |
| | | datalistid:{}, |
| | | ajaxFun: customerpage, |
| | | currentRow: false, |
| | | typeOptions: [], |
| | |
| | | }, |
| | | methods: { |
| | | // 获取数据列表 |
| | | getData() { |
| | | this.$refs.paramTable.getDataList() |
| | | }, |
| | | handleSelectionChange(val){ |
| | | let data = val |
| | | data.forEach(el => { |
| | | this.datalistid = el |
| | | }); |
| | | console.log(this.datalistid); |
| | | // getData() { |
| | | // this.$refs.paramTable.getDataList() |
| | | // }, |
| | | Getdata(val){ |
| | | console.log(val); |
| | | this.datalistid = val |
| | | }, |
| | | saveSelectRow() { |
| | | pagedataadd ({customerId:this.datalistid.id,contractNo:this.datalistid.contractNo}).then((res =>{ |
| | | console.log(res); |
| | | let packageBox = { |
| | | customerId:this.datalistid.id, |
| | | contractNo:this.datalistid.contractNo |
| | | } |
| | | pagedataadd (packageBox).then((res =>{ |
| | | this.$emit('way',res ) |
| | | if (res.status === 200) { |
| | | this.$message.success('新增成功') |
| | | }else{ |
| | |
| | | } |
| | | })) |
| | | this.innerVisible = false |
| | | this.$emit('handleSelectionChange',this.innerVisible ) |
| | | this.$emit('wayapi',this.innerVisible ) |
| | | }, |
| | | } |
| | | } |