修复bug

This commit is contained in:
宋伟佳
2021-07-27 21:14:32 +08:00
parent 51e37b012a
commit 50ee88f7c2
11 changed files with 148 additions and 146 deletions
@@ -1083,7 +1083,7 @@ export default {
}); });
this.fileListName = middle; this.fileListName = middle;
this.fileIds.push(file.response.data.id); this.fileIds.push(file.response.data.id);
if(this.listForm.fileName === null || this.listForm.fileName == undefined){ if(this.listForm.fileName === null || this.listForm.fileName === undefined){
this.listForm.fileName = this.fileListName.join(',') this.listForm.fileName = this.fileListName.join(',')
} else { } else {
this.listForm.fileName = this.listForm.fileName + ',' + this.fileListName.join(','); this.listForm.fileName = this.listForm.fileName + ',' + this.fileListName.join(',');
@@ -369,14 +369,11 @@ export default {
}, },
//提交事件 //提交事件
handleSubmit() { handleSubmit() {
this.listForm.applyUpdUserId = this.listForm.applyUpdUserId; if(this.commentText === null || this.commentText === undefined || this.commentText === ''){
this.listForm.zrUserId = this.listForm.zrUserId; this.$message.warning('请填写会签意见')
this.listForm.jlUserId = this.listForm.jlUserId; }
this.listForm.prcCreateUser = this.$store.getters.userInfo.userId;
this.listForm.prcCreateUserName = this.$store.getters.userInfo.account;
this.listForm.commentText = this.commentText; this.listForm.commentText = this.commentText;
this.listForm.approvalOpinion = ""; this.listForm.approvalOpinion = "";
this.listForm.standId = this.listForm.standId;
this.listForm.signFlag = ""; this.listForm.signFlag = "";
const json = JSON.stringify(this.listForm); const json = JSON.stringify(this.listForm);
this.$http.post("lawss/activiti/completeTask", { this.$http.post("lawss/activiti/completeTask", {
@@ -527,14 +527,6 @@ export default {
}, },
//提交事件 //提交事件
handleSubmit() { handleSubmit() {
this.listForm.applyUpdUserId = this.listForm.applyUpdUserId;
this.listForm.zrUserId = this.listForm.zrUserId;
this.listForm.jlUserId = this.listForm.jlUserId;
this.listForm.prcCreateUser = this.$store.getters.userInfo.userId;
this.listForm.prcCreateUserName = this.$store.getters.userInfo.account;
this.listForm.commentText = this.commentText;
this.listForm.approvalOpinion = "";
this.listForm.standId = this.listForm.standId;
const json = JSON.stringify(this.listForm); const json = JSON.stringify(this.listForm);
this.$http.post('lawss/activiti/completeTask', { this.$http.post('lawss/activiti/completeTask', {
taskIds: this.taskIds, taskIds: this.taskIds,
@@ -376,14 +376,10 @@
}, },
//提交事件 //提交事件
handleSubmit() { handleSubmit() {
this.listForm.applyUpdUserId = this.listForm.applyUpdUserId; if (this.commentText === null || this.commentText === undefined || this.commentText === ''){
this.listForm.zrUserId = this.listForm.zrUserId; this.$message.warning('请填写审批意见')
this.listForm.jlUserId = this.listForm.jlUserId; }
this.listForm.prcCreateUser = this.$store.getters.userInfo.userId;
this.listForm.prcCreateUserName = this.$store.getters.userInfo.account;
this.listForm.commentText = this.commentText; this.listForm.commentText = this.commentText;
this.listForm.signflag = "";
this.listForm.standId = this.listForm.standId;
const json = JSON.stringify(this.listForm); const json = JSON.stringify(this.listForm);
this.$http.post('lawss/activiti/completeTask', { this.$http.post('lawss/activiti/completeTask', {
taskIds: this.taskIds, taskIds: this.taskIds,
@@ -28,16 +28,16 @@
</el-form-item> </el-form-item>
<el-form-item label="标准编号" prop="standNumber" class="add-form-item form-item-disabled"> <el-form-item label="标准编号" prop="standNumber" class="add-form-item form-item-disabled">
<el-input <el-input
disabled
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
disabled
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">
@@ -93,13 +93,22 @@
<el-table-column <el-table-column
prop="distributePerson" prop="distributePerson"
label="分发责任人"> label="分发责任人">
<!-- <template slot-scope="scope">-->
<!-- <el-input v-model="scope.row.distributePerson" v-show="false"></el-input>-->
<!-- <el-input-->
<!-- v-model="dataList.distributePerson"-->
<!-- placeholder="请选择分发责任人"-->
<!-- @click.native="choiceZRR(scope,'distributePerson', '选择分发责任人', roleForm.distributePerson)"-->
<!-- readonly-->
<!-- v-if="dataList[scope.$index].distributePerson==null"-->
<!-- />-->
<!-- </template>-->
<template slot-scope="scope,text" v-if="showColumn"> <template slot-scope="scope,text" v-if="showColumn">
<div> <div>
<div @click="choiceZRR(scope,'distributePerson', '选择分发责任人', roleForm.distributePerson)"> <div @click="choiceZRR(scope,'distributePerson', '选择分发责任人', roleForm.distributePerson)">
{{ listForm.dataList[scope.$index].distributePerson == null ? "请选择分发负责人" : listForm.dataList[scope.$index].distributePerson }} {{ listForm.dataList[scope.$index].distributePerson == null ? "请选择分发负责人" : listForm.dataList[scope.$index].distributePerson }}
</div> </div>
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -241,17 +250,26 @@
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="issueTime" prop="putTime"
label="发布日期"> label="发布日期">
<template slot-scope="scope">
<span>{{ scope.row.putTime ? $moment(scope.row.putTime).format("YYYY-MM-DD") : "" }}</span>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="xcxssrq" prop="xcxssrqgj"
label="新车型实施日期"> label="新车型实施日期">
<template slot-scope="scope">
<span>{{ scope.row.xcxssrqgj ? $moment(scope.row.xcxssrqgj).format("YYYY-MM-DD") : "" }}</span>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
show-overflow-tooltip show-overflow-tooltip
prop="zccssrq" prop="zccssrqgj"
label="在产车实施日期"> label="在产车实施日期">
<template slot-scope="scope">
<span>{{ scope.row.zccssrqgj ? $moment(scope.row.zccssrqgj).format("YYYY-MM-DD") : "" }}</span>
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
show-overflow-tooltip show-overflow-tooltip
@@ -370,20 +388,20 @@ export default {
// 查询相关参数 // 查询相关参数
searching: false, searching: false,
standardSearch: { standardSearch: {
standType:'', standType: "",
standName:'', standName: ""
}, },
standardTypeOptions: [ standardTypeOptions: [
{ {
value: 'INLAND', value: "INLAND",
label: '国内标准法规', label: "国内标准法规",
item:'INLAND', item: "INLAND"
}, },
{ {
value: 'FOREIGN', value: "FOREIGN",
label: '海外标准法规', label: "海外标准法规",
item:'FOREIGN', item: "FOREIGN"
}, }
], ],
nodeList: [], nodeList: [],
defaultProps: { defaultProps: {
@@ -398,10 +416,10 @@ export default {
qualityEngineerName: "", qualityEngineerName: "",
certifiedEngineerName: "", certifiedEngineerName: "",
distributePerson: "", distributePerson: "",
dockUser:'', dockUser: "",
ministerUser: "", ministerUser: "",
dockUserName:'', dockUserName: "",
ministerUserName:"", ministerUserName: ""
}, },
formRules: { formRules: {
standName: [ standName: [
@@ -415,7 +433,7 @@ export default {
], ],
certifiedEngineer: [ certifiedEngineer: [
{ required: true, message: "请选择认证工程师", trigger: "change" } { required: true, message: "请选择认证工程师", trigger: "change" }
], ]
}, },
roleFormRules: { roleFormRules: {
dockUserName: [ dockUserName: [
@@ -423,7 +441,7 @@ export default {
], ],
ministerUserName: [ ministerUserName: [
{ required: true, message: "请选择标准法规部领导", trigger: "change" } { required: true, message: "请选择标准法规部领导", trigger: "change" }
], ]
}, },
ListModel: false, //选择拆分标准抽屉状态 ListModel: false, //选择拆分标准抽屉状态
treeData: [], // 人员数据 treeData: [], // 人员数据
@@ -464,19 +482,19 @@ export default {
distributePersonId: "", //分发责任人id distributePersonId: "", //分发责任人id
id: "", id: "",
sarStandProjectLibraries: [{ sarStandProjectLibraries: [{
projectManager: '', projectManager: "",
projectLevel: '', projectLevel: "",
projectNumber: '', projectNumber: "",
projectEndDate: '', projectEndDate: "",
currentNode: '', currentNode: "",
projectGroup: '', projectGroup: "",
productLine: '', productLine: "",
projectClassification: '', projectClassification: "",
projectStatus: '', projectStatus: "",
projectStartDate: '', projectStartDate: "",
id: '', id: "",
projectName: '', projectName: "",
projectPlatfor: '' projectPlatfor: ""
}] }]
}] }]
}, },
@@ -503,13 +521,14 @@ export default {
this.listForm.certifiedEngineer = data[0].id; this.listForm.certifiedEngineer = data[0].id;
this.listForm.certifiedEngineerName = data[0].name; this.listForm.certifiedEngineerName = data[0].name;
} else if (this.type === "distributePerson") { } else if (this.type === "distributePerson") {
this.listForm.distributePerson = data[0].name; // this.dataList.distributePerson = data[0].id;
this.listForm.dataList[this.dsadadadsada].distributePersonId= data[0].id // this.dataList.distributePersonName = data[0].name;
this.listForm.dataList[this.dsadadadsada].distributePerson= data[0].name this.listForm.dataList[this.dsadadadsada].distributePersonId = data[0].id;
this.listForm.dataList[this.dsadadadsada].distributePerson = data[0].name;
this.showColumn = false; this.showColumn = false;
this.$nextTick(() => { this.$nextTick(() => {
this.showColumn = true this.showColumn = true;
}) });
} }
this.modalshowflag = false; this.modalshowflag = false;
}, },
@@ -521,7 +540,7 @@ export default {
this.active = name; this.active = name;
}, },
typeChange(type) { typeChange(type) {
this.standardSearch.standType = type this.standardSearch.standType = type;
}, },
choiceShow() { choiceShow() {
this.ListModel = true; this.ListModel = true;
@@ -542,14 +561,14 @@ export default {
//点击添加事件 //点击添加事件
addList() { addList() {
this.standModel = true; this.standModel = true;
this.$refs.projectTable.clearSelection() this.$refs.projectTable.clearSelection();
}, },
// 点击批量删除事件 // 点击批量删除事件
deleteList() { deleteList() {
if (this.selectList.length < 1) { if (this.selectList.length < 1) {
this.$message.warning('请选择一条数据进行删除') this.$message.warning("请选择一条数据进行删除");
} else { } else {
this.$confirm('您确认删除这些数据?', '提示', { this.$confirm("您确认删除这些数据?", "提示", {
confirmButtonText: "确认", confirmButtonText: "确认",
confirmButtonClass: "common-button-primary", confirmButtonClass: "common-button-primary",
cancelButtonText: "取消", cancelButtonText: "取消",
@@ -558,15 +577,15 @@ export default {
this.selectList.map(item => { this.selectList.map(item => {
let index; let index;
index = this.dataList.findIndex(items => { index = this.dataList.findIndex(items => {
return items.productLine = item return items.productLine = item;
}) });
if (index > -1) { if (index > -1) {
this.dataList.splice(index, 1); this.dataList.splice(index, 1);
} }
}); });
this.selectList = []; this.selectList = [];
}).catch(() => { }).catch(() => {
}) });
} }
}, },
//取消添加事件 //取消添加事件
@@ -579,16 +598,16 @@ export default {
if (this.dataList.length >= 1) { if (this.dataList.length >= 1) {
this.dataList.forEach(item => { this.dataList.forEach(item => {
if (proData.length === 0) { if (proData.length === 0) {
proData.push(item.productLine) proData.push(item.productLine);
} else if (!proData.includes(item.productLine)) { } else if (!proData.includes(item.productLine)) {
proData.push(item.productLine) proData.push(item.productLine);
} }
}) });
this.standList.forEach(items => { this.standList.forEach(items => {
if (!proData.includes(items.productLine)) { if (!proData.includes(items.productLine)) {
this.dataList.push(items) this.dataList.push(items);
} }
}) });
this.standModel = false; this.standModel = false;
} else { } else {
if (this.standList.length >= 1) { if (this.standList.length >= 1) {
@@ -607,7 +626,7 @@ export default {
let _formData = new FormData(); let _formData = new FormData();
_formData.append("createUser", this.$store.getters.userInfo.userId); _formData.append("createUser", this.$store.getters.userInfo.userId);
_formData.append("createUserName", this.$store.getters.userInfo.uName); _formData.append("createUserName", this.$store.getters.userInfo.uName);
_formData.append("prcType", '5'); _formData.append("prcType", "5");
_formData.append("json", JSON.stringify({ _formData.append("json", JSON.stringify({
prcForm: this.prcForm, prcForm: this.prcForm,
sarAccessInfoList: this.sarAccessInfoList, sarAccessInfoList: this.sarAccessInfoList,
@@ -625,19 +644,17 @@ export default {
}, },
//提交事件 //提交事件
handleSubmit() { handleSubmit() {
if (this.dataList.length < 1) {
this.$message.warning("请添加产品线信息");
}
this.dataList.forEach(item => { this.dataList.forEach(item => {
if(item.distributePerson === '' || item.distributePerson === null || item.distributePerson === undefined){ if (item.distributePerson === "" || item.distributePerson === null || item.distributePerson === undefined) {
this.$message.warning('请选择分发责任人') this.$message.warning("请选择分发责任人");
} else { } else {
var json = Object.assign(this.listForm, this.roleForm) var json = Object.assign(this.listForm, this.roleForm);
json.prcCreateUser = this.$store.getters.userInfo.userId; this.$refs["listForm"].validate((valid) => {
json.prcCreateUserName = this.$store.getters.userInfo.uName;
json.standId = this.listForm.standId;
json.XCXSSRQ = this.sarAccessListDatas[0].xcxssrqgj
json.ZCCSSRQ = this.sarAccessListDatas[0].zccssrqgj
this.$refs['listForm'].validate((valid) => {
if (valid) { if (valid) {
this.$refs['roleForm'].validate((valid) => { this.$refs["roleForm"].validate((valid) => {
if (valid) { if (valid) {
this.$http.get("lawss/activiti/startProcess", { type: "5" }, { this.$http.get("lawss/activiti/startProcess", { type: "5" }, {
_this: this _this: this
@@ -666,7 +683,7 @@ export default {
} }
}); });
} }
}) });
}, },
//选择拆分标准取消事件 //选择拆分标准取消事件
@@ -740,19 +757,19 @@ export default {
}, },
pageChange(page) { pageChange(page) {
this.page = page; this.page = page;
this.getStandData() this.getStandData();
}, },
pageSizeChange(pageSize) { pageSizeChange(pageSize) {
this.pageSize = this.$store.getters.userInfo.configContent; this.pageSize = this.$store.getters.userInfo.configContent;
this.getStandData() this.getStandData();
}, },
pageChangeNo(page) { pageChangeNo(page) {
this.pageNO = page; this.pageNO = page;
this.getProductData() this.getProductData();
}, },
pageSizeChangeNo(pageSize) { pageSizeChangeNo(pageSize) {
this.pageSizeNo = this.$store.getters.userInfo.configContent; this.pageSizeNo = this.$store.getters.userInfo.configContent;
this.getProductData() this.getProductData();
}, },
//获取产品线数据 //获取产品线数据
getProductData() { getProductData() {
@@ -770,26 +787,26 @@ export default {
}, },
//获取标准数据 //获取标准数据
getStandData() { getStandData() {
this.$http.post('SarStandItems/sar-stand-items/findStand',{ this.$http.post("SarStandItems/sar-stand-items/findStand", {
page: this.page, page: this.page,
size: this.pageSize, size: this.pageSize,
...this.standardSearch, ...this.standardSearch
}, { }, {
_this: this, _this: this
}, res => { }, res => {
this.sarAccessListDatas = res.records; this.sarAccessListDatas = res.records;
this.total = res.total this.total = res.total;
}, e => { }, e => {
}) });
}, },
clearSearch() { clearSearch() {
this.standardSearch = { this.standardSearch = {
standName: "", standName: "",
standType:"", standType: ""
}; };
this.getStandData(); this.getStandData();
}, }
}, },
computed: {}, computed: {},
mounted() { mounted() {
@@ -25,14 +25,14 @@
<el-input <el-input
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">
@@ -25,14 +25,14 @@
<el-input <el-input
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">
@@ -25,14 +25,14 @@
<el-input <el-input
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">
@@ -25,14 +25,14 @@
<el-input <el-input
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">
@@ -25,14 +25,14 @@
<el-input <el-input
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">
@@ -25,14 +25,14 @@
<el-input <el-input
v-model="listForm.standNumber" v-model="listForm.standNumber"
placeholder="请输入标准编号" placeholder="请输入标准编号"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled"> <el-form-item label="标准名称" prop="standName" class="add-form-item form-item-disabled">
<el-input <el-input
v-model="listForm.standName" v-model="listForm.standName"
placeholder="请输入标准名称" placeholder="请输入标准名称"
clearable disabled
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled"> <el-form-item label="认证工程师" prop="certifiedEngineerName" class="add-form-item form-item-disabled">