| | |
| | | v-if="showType(a.label, data.selectField) == null&&!showUpload(a.label)&&!showCascader(a.label)" :disabled="isDisabled(a.label)"></el-input> |
| | | <el-select v-model="upData[a.label]" :multiple="data.selectField[a.label].choose" size="small" |
| | | v-if="showType(a.label, data.selectField) != null" style="width: 100%;" :disabled="isDisabled(a.label)" |
| | | clearable> |
| | | clearable filterable> |
| | | <el-option v-for="(b, bi) in data.selectField[a.label].select" :key="bi" :value="b.value" |
| | | :label="b.label"> |
| | | </el-option> |
| | |
| | | v-if="showType(a.label, data.selectField) == null&&!showUpload(a.label)&&!showCascader(a.label)" :disabled="isDisabled(a.label)"></el-input> |
| | | <el-select v-model="upData[a.label]" :multiple="data.selectField[a.label].choose" size="small" |
| | | v-if="showType(a.label, data.selectField) != null" style="width: 100%;" :disabled="isDisabled(a.label)" |
| | | clearable> |
| | | clearable filterable> |
| | | <el-option v-for="(b, bi) in data.selectField[a.label].select" :key="bi" :value="b.value" |
| | | :label="b.label"></el-option> |
| | | </el-select> |
| | |
| | | <el-input v-model="upData[a.label]" size="small" clearable :placeholder="`请输入${a.value}`" |
| | | v-if="showType(a.label, data.selectField) == null&&!showUpload(a.label)&&!showCascader(a.label)"></el-input> |
| | | <el-select v-model="upData[a.label]" size="small" v-if="showType(a.label, data.selectField) != null" |
| | | style="width: 100%;" :placeholder="`请选择${a.value}`" clearable> |
| | | style="width: 100%;" :placeholder="`请选择${a.value}`" clearable filterable> |
| | | <el-option v-for="(b, bi) in data.selectField[a.label].select" :key="bi" :value="b.value" |
| | | :label="b.label"></el-option> |
| | | </el-select> |
| | |
| | | } |
| | | } |
| | | this.addLoad = true |
| | | this.upHead.forEach((item,index)=>{ |
| | | if(this.data.cascaderField&&this.data.cascaderField[item.label]){ |
| | | if(this.upData[item.label]){ |
| | | this.upData[item.label] = this.upData[item.label].join(','); |
| | | }else{ |
| | | this.upData[item.label] = '' |
| | | } |
| | | } |
| | | }) |
| | | this.$axios.post(this.addUrl, this.upData, { |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | |
| | | return count * 15 + 60 + 'px' |
| | | }, |
| | | handleSuccessUp(response,label){ |
| | | if(label){ |
| | | if(typeof label === 'string'){ |
| | | if(response.code==200){ |
| | | this.upData[label] = response.data.url; |
| | | } |
| | |
| | | // 批量删除 |
| | | batchDelete(){ |
| | | if(this.multipleSelection&&this.multipleSelection.length>0){ |
| | | // this.delUrl |
| | | this.$confirm('是否删除选中的数据?', "警告", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.$axios.post(this.delUrl, { |
| | | id: this.multipleSelection.map(item => item.id).join(',') |
| | | ids: JSON.stringify(this.multipleSelection.map(item => item.id)) |
| | | }).then(res => { |
| | | if (res.code === 201) { |
| | | return |