修改bug
This commit is contained in:
parent
9d688408cd
commit
fca971fa37
@ -31,7 +31,7 @@ export default {
|
||||
created() {
|
||||
},
|
||||
activated() {
|
||||
this.getDataList();
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
// 获取数据列表
|
||||
|
@ -2,7 +2,7 @@
|
||||
* @Author: zwq
|
||||
* @Date: 2023-01-04 10:29:40
|
||||
* @LastEditors: zhp
|
||||
* @LastEditTime: 2023-06-30 16:39:46
|
||||
* @LastEditTime: 2023-07-07 13:51:05
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
@ -50,13 +50,18 @@ const tableBtn = [
|
||||
type: "synchronous",
|
||||
btnName: "同步",
|
||||
showParam: {
|
||||
type: "&",
|
||||
type: "|",
|
||||
data: [
|
||||
{
|
||||
type: "equal",
|
||||
name: "controlCodeId",
|
||||
value:null,
|
||||
},
|
||||
{
|
||||
type: "equal",
|
||||
name: "controlCodeId",
|
||||
value: '0',
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
@ -71,6 +76,11 @@ const tableBtn = [
|
||||
name: "controlCodeId",
|
||||
value: null,
|
||||
},
|
||||
{
|
||||
type: "unequal",
|
||||
name: "controlCodeId",
|
||||
value: '0',
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-02-14 15:02:26
|
||||
* @LastEditTime: 2023-04-12 15:54:19
|
||||
* @LastEditTime: 2023-07-07 15:48:03
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -23,8 +23,11 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<base-table border :table-props="tableProps" :table-data="tableData"
|
||||
:add-button-show="addButtonShow" @emitFun="inputChange" @emitButtonClick="emitButtonClick" />
|
||||
<base-table v-if="editShow" border :table-props="tableProps" :table-data="tableData"
|
||||
:add-button-show="addButtonShow" @emitFun="inputChange" @emitButtonClick="emitButtonClick" >
|
||||
<method-btn v-if="tableBtn.length" slot="handleBtn" :width="100" label="操作" :method-list="tableBtn"
|
||||
@clickBtn="handleClick" />
|
||||
</base-table>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@ -34,12 +37,10 @@ import debounce from "lodash/debounce"
|
||||
import inputArea from './inputArea'
|
||||
import selectArea from './selectArea'
|
||||
import i18n from "@/i18n"
|
||||
import { kStringMaxLength } from "buffer"
|
||||
const tableProps = [
|
||||
{
|
||||
prop: 'step',
|
||||
label: i18n.t("disqualification.step"),
|
||||
subcomponent: inputArea
|
||||
},
|
||||
{
|
||||
prop: 'teamId',
|
||||
@ -47,6 +48,12 @@ const tableProps = [
|
||||
subcomponent: selectArea
|
||||
}
|
||||
]
|
||||
const tableBtn = [
|
||||
{
|
||||
type: "delete",
|
||||
btnName: "删除",
|
||||
},
|
||||
];
|
||||
export default {
|
||||
// mixins: [basicAdd],
|
||||
data() {
|
||||
@ -59,9 +66,11 @@ export default {
|
||||
},
|
||||
supplierList:[],
|
||||
productList: [],
|
||||
tableBtn,
|
||||
typeList: [],
|
||||
teamList: [],
|
||||
tableData: [],
|
||||
editShow:false,
|
||||
listQuery: {
|
||||
limit: 999,
|
||||
page: 1,
|
||||
@ -117,6 +126,30 @@ export default {
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
handleClick(val) {
|
||||
console.log(val);
|
||||
if (val.type === "delete") {
|
||||
this.$confirm(`确定对[名称=${val.data.step}]进行删除操作?`, "提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
})
|
||||
.then(() => {
|
||||
this.$nextTick(() => {
|
||||
for (let i = 0; i < this.tableData.length; i++) {
|
||||
console.log();
|
||||
if (this.tableData[i].step === val.data.step) {
|
||||
this.tableData.splice(i, 1)
|
||||
}
|
||||
}
|
||||
for (let i = val.data.step - 1; i < this.tableData.length; i++) {
|
||||
this.tableData[i].step = i + 1
|
||||
}
|
||||
})
|
||||
})
|
||||
.catch(() => { })
|
||||
}
|
||||
},
|
||||
inputChange(val) {
|
||||
console.log('=======')
|
||||
console.log(val)
|
||||
@ -126,14 +159,25 @@ export default {
|
||||
emitButtonClick() {
|
||||
console.log('emitButtonClick')
|
||||
let obj = {}
|
||||
for (let i of this.tableProps) {
|
||||
obj[i.prop] = ''
|
||||
// for (let i of this.tableProps) {
|
||||
// console.log(i.prop)
|
||||
// obj[i.prop] = ''
|
||||
// }
|
||||
if (this.tableData.length !== 0) {
|
||||
obj['step'] = this.tableData[this.tableData.length - 1].step + 1
|
||||
obj['teamId'] = ''
|
||||
} else {
|
||||
for (let i = 0; i <= this.tableData.length; i++) {
|
||||
obj['step'] = i + 1
|
||||
obj['teamId'] = ''
|
||||
}
|
||||
}
|
||||
this.tableData.push(obj)
|
||||
// this.dataForm.qmsApprovalProcessStepDetailDTOList.push(obj)
|
||||
// console.log(this.dataForm)
|
||||
},
|
||||
init(id, ) {
|
||||
init(id, flag) {
|
||||
this.editShow = flag || false
|
||||
this.dataForm.id = id || ""
|
||||
this.listQuery.approvalProcessId = id || ""
|
||||
this.editData.id = id || ""
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-02-14 15:02:26
|
||||
* @LastEditTime: 2023-04-07 10:20:53
|
||||
* @LastEditTime: 2023-07-07 14:06:27
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -27,8 +27,8 @@
|
||||
</el-form-item>
|
||||
<el-form-item prop="approvalProcessId" :label="$t('disqualification.approvalProcessName')">
|
||||
<el-select v-model="dataForm.approvalProcessId" :placeholder="$t('disqualification.approvalProcessName')">
|
||||
<el-option v-for="item in approvalProcessList" :key="item.approvalProcessId" :label="item.approvalProcessName"
|
||||
:value="item.approvalProcessId">
|
||||
<el-option v-for="item in approvalProcessList" :key="item.id" :label="item.approvalProcessName"
|
||||
:value="item.id">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@ -198,7 +198,7 @@ export default {
|
||||
})
|
||||
.then(({ data: res }) => {
|
||||
if (res.code === 0) {
|
||||
console.log(res.data);
|
||||
console.log(res.data,'11111111111');
|
||||
this.approvalProcessList= res.data.list
|
||||
}
|
||||
})
|
||||
|
@ -2,17 +2,17 @@
|
||||
* @Author: zwq
|
||||
* @Date: 2023-01-04 10:29:40
|
||||
* @LastEditors: zhp
|
||||
* @LastEditTime: 2023-04-13 15:03:39
|
||||
* @LastEditTime: 2023-07-07 09:16:23
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
<el-form :model="dataForm" ref="dataForm" @keyup.enter.native="dataFormSubmitHandle()" label-width="120px">
|
||||
<el-form-item prop="approvalProcessCode" :label="$t('disqualification.approvalProcessCode')">
|
||||
<el-input v-model="dataForm.approvalProcessCode" :placeholder="$t('disqualification.approvalProcessCode')">
|
||||
<el-form-item prop="code" :label="$t('disqualification.approvalProcessCode')">
|
||||
<el-input v-model="dataForm.code" :placeholder="$t('disqualification.approvalProcessCode')">
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<el-form-item prop="approvalProcessName" :label="$t('disqualification.approvalProcessName')">
|
||||
<el-input v-model="dataForm.approvalProcessName" :placeholder="$t('disqualification.approvalProcessName')">
|
||||
<el-form-item prop="name" :label="$t('disqualification.approvalProcessName')">
|
||||
<el-input v-model="dataForm.name" :placeholder="$t('disqualification.approvalProcessName')">
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
@ -36,8 +36,8 @@ export default {
|
||||
visible: false,
|
||||
customerTypeList:{},
|
||||
dataForm: {
|
||||
approvalProcessName: null,
|
||||
approvalProcessCode:null
|
||||
name: null,
|
||||
code:null
|
||||
},
|
||||
productList:[]
|
||||
};
|
||||
|
@ -1,14 +1,14 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-01-31 09:49:36
|
||||
* @LastEditTime: 2023-04-13 14:52:42
|
||||
* @LastEditTime: 2023-07-07 09:55:32
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
<div id="detailList">
|
||||
<span v-for="(item,index) in injectData.qmsApprovalProcessStepDetailDTOList" :key="item.teamName">
|
||||
<el-button type="text">{{item.teamName}}} </el-button>
|
||||
<span v-for="(item,index) in injectData.qmsApprovalProcessStepDetailDTOList" :key="index">
|
||||
{{item.teamName}}
|
||||
<i v-if="index <+ injectData.qmsApprovalProcessStepDetailDTOList.length-1" class="el-icon-right"></i>
|
||||
</span>
|
||||
</div>
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-01-11 09:24:58
|
||||
* @LastEditTime: 2023-06-20 15:35:20
|
||||
* @LastEditTime: 2023-07-07 09:20:18
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -159,8 +159,8 @@ export default {
|
||||
});
|
||||
},
|
||||
conditionSearchSubmit(dataForm) {
|
||||
this.listQuery.approvalProcessCode = dataForm.approvalProcessCode
|
||||
this.listQuery.approvalProcessName = dataForm.approvalProcessName
|
||||
this.listQuery.code = dataForm.code
|
||||
this.listQuery.name = dataForm.name
|
||||
this.listQuery.page = 1
|
||||
this.getDataList()
|
||||
this.searchOrUpdateVisible = false
|
||||
@ -196,7 +196,7 @@ export default {
|
||||
this.addOrEditTitle = this.$t('edit')
|
||||
this.addOrUpdateVisible = true;
|
||||
this.$nextTick(() => {
|
||||
this.$refs.addOrUpdate.init(val.data.id);
|
||||
this.$refs.addOrUpdate.init(val.data.id,true)
|
||||
});
|
||||
}
|
||||
},
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-01-11 09:24:58
|
||||
* @LastEditTime: 2023-06-20 15:34:19
|
||||
* @LastEditTime: 2023-07-07 14:23:29
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -9,7 +9,7 @@
|
||||
<el-card shadow="never" class="aui-card--fill">
|
||||
<div class="mod-sys__user">
|
||||
<SearchBar :formConfigs="formConfig" ref="ruleForm" @headBtnClick="buttonClick">
|
||||
<el-badge :value="1" class="item">
|
||||
<el-badge :value="2" class="item">
|
||||
<el-button type="primary" size="small" @click="conditionSearch">条件搜索</el-button>
|
||||
</el-badge>
|
||||
</SearchBar>
|
||||
@ -135,6 +135,10 @@ export default {
|
||||
// components: {
|
||||
// AddOrUpdate,
|
||||
// },
|
||||
deactivated () {
|
||||
this.listQuery.inspectionTypeId = null
|
||||
this.listQuery.productId = null
|
||||
},
|
||||
methods: {
|
||||
//search-bar点击
|
||||
handleProductCancel() {
|
||||
@ -199,6 +203,8 @@ export default {
|
||||
case "search":
|
||||
// this.listQuery.paramCode = val.paramCode;
|
||||
this.listQuery.page = 1;
|
||||
this.listQuery.inspectionTypeId = null
|
||||
this.listQuery.productId = null
|
||||
this.getDataList();
|
||||
break;
|
||||
case "add":
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!--
|
||||
* @Author: zhp
|
||||
* @Date: 2023-01-11 09:24:58
|
||||
* @LastEditTime: 2023-06-20 15:34:38
|
||||
* @LastEditTime: 2023-07-07 14:11:27
|
||||
* @LastEditors: zhp
|
||||
* @Description:
|
||||
-->
|
||||
@ -156,7 +156,7 @@ export default {
|
||||
handleClick(val) {
|
||||
console.log(val);
|
||||
if (val.type === "delete") {
|
||||
this.$confirm(`确定对[名称=${val.data.failureTypeName}]进行删除操作?`, "提示", {
|
||||
this.$confirm(`确定对[处理团队=${val.data.teamName}]进行删除操作?`, "提示", {
|
||||
confirmButtonText: "确定",
|
||||
cancelButtonText: "取消",
|
||||
type: "warning",
|
||||
|
Loading…
Reference in New Issue
Block a user