| | |
| | | created() { |
| | | if(!this.disableMixinCreated){ |
| | | console.log(' -- mixin created -- ') |
| | | // 此处需在loadData函数之前将参数设置为所需要的值,在组件中的created中无法设置,因为mixin的生命周期函数执行顺序优先于组件的生命周期函数 |
| | | const { equipmentId } = this.$route.params |
| | | if(equipmentId) this.$set(this.queryParam,'equipmentNum',equipmentId) |
| | | this.loadData(); |
| | | //初始化字典配置 在自己页面定义 |
| | | this.initDictConfig(); |
| | |
| | | sqp['superQueryMatchType'] = this.superQueryMatchType |
| | | } |
| | | var param = Object.assign(sqp, this.queryParam, this.isorter ,this.filters); |
| | | param.field = this.getQueryField(); |
| | | if(this.columns) param.field = this.getQueryField(); |
| | | param.pageNo = this.ipagination.current; |
| | | param.pageSize = this.ipagination.pageSize; |
| | | //获取用户定制的参数属性 |
| | |
| | | description:res.message |
| | | }); |
| | | that.loadData(); |
| | | that.clearSelected() |
| | | } else { |
| | | // that.$message.warning(res.message); |
| | | that.$notification.warning({ |
| | |
| | | ) |
| | | }) |
| | | } else { |
| | | this.$message.success(info.file.response.message || `${info.file.name} 文件上传成功`) |
| | | // this.$message.success(info.file.response.message || `${info.file.name} 文件上传成功`) |
| | | this.$notification.success({ |
| | | message:'消息', |
| | | description:info.file.response.message || `${info.file.name} 文件上传成功` |
| | | }); |
| | | } |
| | | this.loadData() |
| | | } else { |
| | | this.$message.error(`${info.file.name} ${info.file.response.message}.`); |
| | | // this.$message.error(`${info.file.name} ${info.file.response.message}.`); |
| | | this.$notification.error({ |
| | | message:'消息', |
| | | description:`${info.file.name} ${info.file.response.message}.` |
| | | }); |
| | | } |
| | | } else if (info.file.status === 'error') { |
| | | this.loading = false; |
| | |
| | | }) |
| | | } |
| | | } else { |
| | | this.$message.error(`文件上传失败: ${info.file.msg} `); |
| | | // this.$message.error(`文件上传失败: ${info.file.msg} `); |
| | | this.$notification.error({ |
| | | message:'消息', |
| | | description:`文件上传失败: ${info.file.msg} ` |
| | | }); |
| | | } |
| | | } |
| | | }, |