Merge remote-tracking branch 'origin/dev_2nd_LCYH' into dev_2nd_LCYH
This commit is contained in:
+7
@@ -10,6 +10,7 @@ import com.alibaba.fastjson.JSONObject;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.system.query.QueryGenerator;
|
||||
import com.jero.modules.project.entity.ProjectCertificationInventoryEO;
|
||||
import com.jero.modules.project.entity.ProjectLawsInventoryEO;
|
||||
import com.jero.modules.project.service.IProjectCertificationInventoryEOService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
@@ -249,6 +250,12 @@ public class ProjectCertificationInventoryEOController extends JeroController<Pr
|
||||
return this.projectCertificationInventoryEOService.updateConfigItemBatch(json);
|
||||
}
|
||||
|
||||
@ApiOperation(value="项目库-认证清单表-模板下载", notes="项目库-认证清单表-模板下载")
|
||||
@GetMapping(value = "/exportTemplate")
|
||||
public void exportTemplate(ProjectCertificationInventoryEO projectCertificationInventoryEO, HttpServletResponse response, HttpServletRequest request) throws Exception {
|
||||
projectCertificationInventoryEOService.exportTemplate(projectCertificationInventoryEO,response,request);
|
||||
}
|
||||
|
||||
@AutoLog(value = "项目库-认证清单表-调取添加")
|
||||
@ApiOperation(value="项目库-认证清单表-调取添加", notes="项目库-认证清单表-调取添加")
|
||||
@PostMapping(value = "/callAdd")
|
||||
|
||||
+10
@@ -12,6 +12,8 @@ import com.jero.modules.system.entity.SysRole;
|
||||
import com.jero.modules.todoCenter.entity.ProcessInfoDetailEO;
|
||||
import com.jero.modules.todoCenter.entity.ProcessInfoEO;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -161,6 +163,14 @@ public interface IProjectCertificationInventoryEOService extends IService<Projec
|
||||
|
||||
Map<String,Object> getStandNameAndItemName(List<ProjectCertificationInventoryEO> projectCertificationInventoryEOList);
|
||||
|
||||
/**
|
||||
* 模板下载
|
||||
* @param projectCertificationInventoryEO
|
||||
* @param response
|
||||
* @param request
|
||||
*/
|
||||
void exportTemplate(ProjectCertificationInventoryEO projectCertificationInventoryEO, HttpServletResponse response, HttpServletRequest request);
|
||||
|
||||
/**
|
||||
* 批量修改配置项
|
||||
* @param json
|
||||
|
||||
+123
@@ -2,6 +2,7 @@ package com.jero.modules.project.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.aliyuncs.utils.IOUtils;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
@@ -40,6 +41,15 @@ import com.jero.modules.todoCenter.enums.TodoCenterStatusEnum;
|
||||
import com.jero.modules.todoCenter.service.IProcessInfoDetailEOService;
|
||||
import com.jero.modules.todoCenter.service.IProcessInfoEOService;
|
||||
import com.jero.modules.wkflow.enums.FlowTypeEnum;
|
||||
import org.apache.poi.hssf.usermodel.HSSFCellStyle;
|
||||
import org.apache.poi.hssf.usermodel.HSSFRichTextString;
|
||||
import org.apache.poi.hssf.usermodel.HSSFSheet;
|
||||
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
||||
import org.apache.poi.ss.usermodel.Cell;
|
||||
import org.apache.poi.ss.usermodel.HorizontalAlignment;
|
||||
import org.apache.poi.ss.usermodel.Row;
|
||||
import org.apache.poi.ss.usermodel.VerticalAlignment;
|
||||
import org.apache.poi.ss.util.CellRangeAddress;
|
||||
import org.apache.shiro.SecurityUtils;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
@@ -48,7 +58,9 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.OutputStream;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@@ -57,6 +69,9 @@ import org.springframework.transaction.annotation.Propagation;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.util.ObjectUtils;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
/**
|
||||
* @Description: 项目库-认证清单表
|
||||
* @Author: jero-boot
|
||||
@@ -95,6 +110,8 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
|
||||
@Value(value = "${jero.backUrl}")
|
||||
private String backUrl;
|
||||
@Value(value = "${jero.path.upload}")
|
||||
private String uploadpath;
|
||||
|
||||
/**
|
||||
* 保存
|
||||
@@ -1810,4 +1827,110 @@ public class ProjectCertificationInventoryEOServiceImpl extends ServiceImpl<Proj
|
||||
|
||||
return Result.OK("调取成功!");
|
||||
}
|
||||
/**
|
||||
* 模板下载
|
||||
* @param projectCertificationInventoryEO
|
||||
* @param response
|
||||
* @param request
|
||||
*/
|
||||
@Override
|
||||
public void exportTemplate(ProjectCertificationInventoryEO projectCertificationInventoryEO, HttpServletResponse response, HttpServletRequest request) {
|
||||
OutputStream os = null;
|
||||
HSSFWorkbook workbook = new HSSFWorkbook();
|
||||
String fileOriName = "认证清单导入模板.xls";
|
||||
String filePath = uploadpath + File.separator + fileOriName;
|
||||
|
||||
try {
|
||||
String title = "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
title = "类别,检验项目,配置项,WVTA ID," +
|
||||
"*标注编号,*责任领域,工程接口人,责任人," +
|
||||
"交付物类型,交付结果,截止日期,流程状态," +
|
||||
"报告编号,产品型号,生产企业名称,认证进度";
|
||||
}else {
|
||||
title = "Category,Inspection Items,Configuration Item,WVTA ID," +
|
||||
"*Standard No,*Responsible Field,Eng. Interface,Assignee," +
|
||||
"Deliverable Type,Deliverables Result,Due Date,Process Status," +
|
||||
"Report No,Product Model,Name Of Manufacturer,Homologation Progress";
|
||||
}
|
||||
|
||||
List<String> list = Arrays.asList(title.split(","));
|
||||
int index = 0;
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
index = list.indexOf("认证进度") + 1;
|
||||
}else{
|
||||
index = list.indexOf("Homologation Progress") + 1;
|
||||
}
|
||||
|
||||
//创建临时文件夹
|
||||
File nowFile = new File(filePath);
|
||||
if (nowFile.exists()) {
|
||||
nowFile.delete();
|
||||
}
|
||||
nowFile.mkdirs();
|
||||
HSSFSheet sheet = workbook.createSheet("认证清单导入模板");
|
||||
sheet.setDefaultColumnWidth(16);//列宽
|
||||
// HSSFCellStyle cellStyle = workbook.createCellStyle();
|
||||
// cellStyle.setWrapText(true);//自动换行
|
||||
// cellStyle.setAlignment(HorizontalAlignment.CENTER);//垂直居中
|
||||
// cellStyle.setVerticalAlignment(VerticalAlignment.CENTER);//水平居中
|
||||
|
||||
HSSFCellStyle cellStyleTemp = workbook.createCellStyle();
|
||||
cellStyleTemp.setWrapText(true);//自动换行
|
||||
|
||||
CellRangeAddress region =
|
||||
new CellRangeAddress(1, 1, 0, 15); //参数1:起始行 参数2:终止行 参数3:起始列 参数4:终止列
|
||||
sheet.addMergedRegion(region);
|
||||
String explain= "";
|
||||
if(CutEnum.CN.getValue().equals(projectCertificationInventoryEO.getCut())){
|
||||
explain = "填写说明\n" +
|
||||
"1.导入数据从第三行开始\n" +
|
||||
"2.所有带*号的字段必须填写\n"+
|
||||
"3.责任人,交付物类型,工程接口人,字段是单选属性,必须和系统中的对应字段选项相匹配\n" +
|
||||
"4.编号,责任领域,字段是多选属性,必须和系统中的对应字段选项相匹配,填写多个时采用英文或中文逗号分割\n" +
|
||||
"5.类别,WVTA ID,检验项目,填写文本内容\n" +
|
||||
"6.交付物模板字段为文件属性,填写时需要在本文件同级目录下以标准号为名称建立文件夹,并在文件夹下放置文件,假设在AAA标准号下放置了B.docx,则应填写AAA/B.docx";
|
||||
}else{
|
||||
explain = "Filling explanation\n" +
|
||||
"1.Import data starts at the fourth line\n" +
|
||||
"2.All fields marked with * must be filled in\n"+
|
||||
"3.Assignee,Deliverable Type,Deliverable Type,Eng. Interface,Fields are radio attributes that must match the corresponding field option in the system\n" +
|
||||
"4.Standard No,Responsible Field, field is a multi-select attribute and must match the corresponding field in the system. If multiple fields are filled in, separate them by commas (,)\n" +
|
||||
"5.Category,WVTA ID,Inspection Items,Fill in the text\n" +
|
||||
"6.Deliverable Template,When filling in the field, you need to create a folder in the directory of the same level as the file with the name of the standard number and place the file in the folder. If b. diocx is stored under the AAA standard number, enter AAA/B. diocx";
|
||||
}
|
||||
for(int i = 0; i < 2; i++){
|
||||
//表头
|
||||
Row row = sheet.createRow(i);//开始创建标题行
|
||||
String[] headerArr = title.split(",");
|
||||
if(i == 0 ){
|
||||
for (int m = 0; m < headerArr.length; m++) {
|
||||
if(m < index){
|
||||
row.createCell(m).setCellValue(headerArr[m]);
|
||||
}else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}else {
|
||||
short height = (short) (7 * 252);
|
||||
row.setHeight((short) height);
|
||||
Cell cell = row.createCell(0);
|
||||
cell.setCellStyle(cellStyleTemp);
|
||||
cell.setCellValue(new HSSFRichTextString(explain));
|
||||
}
|
||||
}
|
||||
response.setHeader("Content-Disposition",
|
||||
"attachment; filename=\"" + fileOriName + ".xls");
|
||||
response.setContentType("application/force-download");
|
||||
response.flushBuffer();
|
||||
os = response.getOutputStream();
|
||||
workbook.write(os);
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
throw new JeroBootException("下载文件失败,请重试");
|
||||
}finally {
|
||||
IOUtils.closeQuietly(os);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+157
-53
@@ -93,7 +93,46 @@
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
|
||||
</div>
|
||||
<a-form-model-item
|
||||
class="itemModel"
|
||||
:prop="'dataList.'+index+'.configItem'"
|
||||
:rules="[{ required: true, message: $t('configurationItem') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||
>
|
||||
<j-dict-select-tag class="box-input" v-model="item.configItem"
|
||||
@input="handleInput('dataList.'+index+'.configItem')"
|
||||
:placeholder="$t('PleaseSelect')+$t('configurationItem')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'ren4_zheng4_qing1_dan1_-_pei4_zhi4_xiang4'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text"
|
||||
:title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.dutyTerritory'"
|
||||
:rules="[{ required: true, message: $t('areaOfResponsibility') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||
>
|
||||
<j-dict-select-tag class="box-input" v-model="item.dutyTerritory"
|
||||
@input="handleInput('dataList.'+index+'.dutyTerritory')"
|
||||
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'duty_territory'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
@@ -141,25 +180,6 @@
|
||||
</a-row>
|
||||
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text"
|
||||
:title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.dutyTerritory'"
|
||||
:rules="[{ required: true, message: $t('areaOfResponsibility') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||
>
|
||||
<j-dict-select-tag class="box-input" v-model="item.dutyTerritory"
|
||||
@input="handleInput('dataList.'+index+'.dutyTerritory')"
|
||||
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'duty_territory'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
@@ -180,30 +200,52 @@
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('personLiable')">{{$t('personLiable')}}</span>
|
||||
<span class="title-text-text" :title="$t('closingDate')">{{$t('closingDate')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel-multi"
|
||||
:prop="'dataList.'+index+'.dutyPersonName'"
|
||||
:rules="[{ required: true, message: $t('personLiable') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.endTime'"
|
||||
:rules="[{ required: true, message: $t('closingDate') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||
>
|
||||
<PersonnelSelection
|
||||
:query="{db_field_name:'dutyPerson',db_field_txt:$t('personLiable'),subscript:index}"
|
||||
:personneQuery="item"
|
||||
:isSingleChoice="true"
|
||||
@change="PersonnelSelectionChange"
|
||||
:disabled="disabled"
|
||||
v-model="item.dutyPersonName"/>
|
||||
<a-date-picker class="box-input"
|
||||
:placeholder="$t('PleaseSelect')+$t('closingDate')"
|
||||
@change="dateChange({db_field_name:'endTime'},index)"
|
||||
format="YYYY-MM-DD"
|
||||
:disabledDate="disabledDate"
|
||||
:getCalendarContainer="(trigger) => trigger.parentNode"
|
||||
v-model="item.endTime"
|
||||
style="width: 100%"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
|
||||
<!-- <a-row :gutter="24">-->
|
||||
<!-- <a-col :span="12">-->
|
||||
<!-- <div class="box-title-text">-->
|
||||
<!-- <div class="title-text">-->
|
||||
<!-- <span class="Required">*</span>-->
|
||||
<!-- <span class="title-text-text" :title="$t('personLiable')">{{$t('personLiable')}}</span>-->
|
||||
<!-- </div>-->
|
||||
<!-- <a-form-model-item class="itemModel-multi"-->
|
||||
<!-- :prop="'dataList.'+index+'.dutyPersonName'"-->
|
||||
<!-- :rules="[{ required: true, message: $t('personLiable') + $t('cannotEmpty'), trigger: 'change'},]"-->
|
||||
<!-- >-->
|
||||
<!-- <PersonnelSelection-->
|
||||
<!-- :query="{db_field_name:'dutyPerson',db_field_txt:$t('personLiable'),subscript:index}"-->
|
||||
<!-- :personneQuery="item"-->
|
||||
<!-- :isSingleChoice="true"-->
|
||||
<!-- @change="PersonnelSelectionChange"-->
|
||||
<!-- :disabled="disabled"-->
|
||||
<!-- v-model="item.dutyPersonName"/>-->
|
||||
<!-- </a-form-model-item>-->
|
||||
<!-- </div>-->
|
||||
<!-- </a-col>-->
|
||||
<!-- </a-row>-->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -240,7 +282,44 @@
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
|
||||
</div>
|
||||
<a-form-model-item
|
||||
class="itemModel"
|
||||
:prop="'configItem'"
|
||||
>
|
||||
<j-dict-select-tag class="box-input" v-model="formInline.configItem"
|
||||
@input="handleInput('configItem')"
|
||||
:placeholder="$t('PleaseSelect')+$t('configurationItem')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'ren4_zheng4_qing1_dan1_-_pei4_zhi4_xiang4'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text"
|
||||
:title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dutyTerritory'"
|
||||
>
|
||||
<j-dict-select-tag class="box-input" v-model="formInline.dutyTerritory"
|
||||
@input="handleInput('dutyTerritory')"
|
||||
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'duty_territory'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
@@ -286,24 +365,6 @@
|
||||
</a-row>
|
||||
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text"
|
||||
:title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dutyTerritory'"
|
||||
>
|
||||
<j-dict-select-tag class="box-input" v-model="formInline.dutyTerritory"
|
||||
@input="handleInput('dutyTerritory')"
|
||||
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'duty_territory'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
@@ -323,6 +384,26 @@
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('closingDate')">{{$t('closingDate')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'endTime'"
|
||||
>
|
||||
<a-date-picker class="box-input"
|
||||
:placeholder="$t('PleaseSelect')+$t('closingDate')"
|
||||
@change="dateChange({db_field_name:'endTime'})"
|
||||
format="YYYY-MM-DD"
|
||||
:disabledDate="disabledDate"
|
||||
:getCalendarContainer="(trigger) => trigger.parentNode"
|
||||
v-model="formInline.endTime"
|
||||
style="width: 100%"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
|
||||
<a-row :gutter="24">
|
||||
@@ -377,6 +458,7 @@
|
||||
import uploadFile from '@/components/uploadFile/file'
|
||||
import { getAction, postAction, downloadFile, putAction } from '@/api/manage'
|
||||
import { mapGetters } from 'vuex'
|
||||
import moment from 'moment'
|
||||
|
||||
export default {
|
||||
name: 'addModel',
|
||||
@@ -450,7 +532,17 @@
|
||||
message: this.$t('personLiable') + this.$t('cannotEmpty'),
|
||||
trigger: 'change'
|
||||
}
|
||||
]
|
||||
],
|
||||
endTime:[
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('closingDate') + this.$t('cannotEmpty'),
|
||||
trigger: 'change'
|
||||
}
|
||||
],
|
||||
configItem:[
|
||||
{ required: true, message: this.$t('configurationItem') + this.$t('cannotEmpty'), trigger: 'change' },
|
||||
],
|
||||
},
|
||||
disabled: false,
|
||||
projectNameList: [],
|
||||
@@ -471,6 +563,18 @@
|
||||
},
|
||||
methods: {
|
||||
...mapGetters(['userInfo']),
|
||||
disabledDate(current) {
|
||||
return current && current < moment().subtract(1, 'day')
|
||||
},
|
||||
dateChange(item,index) {
|
||||
if (index){
|
||||
this.formInline.dataList[index][item.db_field_name] = this.formInline.dataList[index][item.db_field_name] ? moment(this.formInline.dataList[index][item.db_field_name]).format('YYYY-MM-DD') : ''
|
||||
|
||||
}else{
|
||||
this.formInline[item.db_field_name] = this.formInline[item.db_field_name] ? moment(this.formInline[item.db_field_name]).format('YYYY-MM-DD') : ''
|
||||
|
||||
}
|
||||
},
|
||||
getDeliverableTree() {
|
||||
getAction('/sys/category/getDeliverableTree', {}).then((res) => {
|
||||
if (res.success) {
|
||||
|
||||
+93
-40
@@ -17,19 +17,11 @@
|
||||
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-select :placeholder="$t('PleaseSelect')+$t('configurationItem')"
|
||||
class="box-input"
|
||||
allowClear
|
||||
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||
v-model="formInline.configItem">
|
||||
<a-select-option v-for="(item, key) in configurationItemList"
|
||||
:key="item.key"
|
||||
:value="item.value">
|
||||
<span style="display: inline-block;width: 100%" :title=" item.label ">
|
||||
{{ item.label }}
|
||||
</span>
|
||||
</a-select-option>
|
||||
</a-select>
|
||||
<j-dict-select-tag class="box-input" v-model="formInline.configItem"
|
||||
@input="handleInput('configItem')"
|
||||
:placeholder="$t('PleaseSelect')+$t('configurationItem')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'ren4_zheng4_qing1_dan1_-_pei4_zhi4_xiang4'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -74,15 +66,20 @@
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text" :title="$t('personLiable')">{{$t('personLiable')}}</span>
|
||||
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel-multi">
|
||||
<PersonnelSelection :query="{db_field_name:'dutyPerson',db_field_txt:$t('personLiable')}"
|
||||
:isSingleChoice="true"
|
||||
:personneQuery="formInline"
|
||||
v-if="visible"
|
||||
@change="PersonnelSelectionChange"
|
||||
v-model="formInline.dutyPersonName"/>
|
||||
<a-tree-select
|
||||
tree-node-filter-prop="title"
|
||||
v-model="formInline.deliverableType"
|
||||
:maxTagCount="1"
|
||||
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||
class="box-input"
|
||||
style="width: 100%"
|
||||
:tree-data="DeliverableTreeList"
|
||||
tree-checkable
|
||||
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
|
||||
/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -91,25 +88,52 @@
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
|
||||
<span class="title-text-text" :title="$t('closingDate')">{{$t('closingDate')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-select :placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
|
||||
class="box-input"
|
||||
allowClear
|
||||
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||
v-model="formInline.deliverableType">
|
||||
<a-select-option v-for="(item, key) in typeOfDeliverablesList"
|
||||
:key="item.key"
|
||||
:value="item.value">
|
||||
<span style="display: inline-block;width: 100%" :title=" item.label ">
|
||||
{{ item.label }}
|
||||
</span>
|
||||
</a-select-option>
|
||||
</a-select>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'endTime'"
|
||||
>
|
||||
<a-date-picker class="box-input"
|
||||
:placeholder="$t('PleaseSelect')+$t('closingDate')"
|
||||
@change="dateChange({db_field_name:'endTime'})"
|
||||
format="YYYY-MM-DD"
|
||||
:disabledDate="disabledDate"
|
||||
:getCalendarContainer="(trigger) => trigger.parentNode"
|
||||
v-model="formInline.endTime"
|
||||
style="width: 100%"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12" v-if="roleSwitchingCode == 2">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text"
|
||||
:title="$t('CertificationProgress')">{{$t('CertificationProgress')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<j-dict-select-tag class="box-input" v-model="formInline.certificationProgress"
|
||||
@input="handleInput('certificationProgress')"
|
||||
:placeholder="$t('PleaseSelect')+$t('CertificationProgress')"
|
||||
:type="'select'"
|
||||
:triggerChange="false" :dictCode="'certification_progress'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24" v-if="name == $t('BatchSetting') && roleSwitchingCode == 2">
|
||||
<a-col :span="24">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="title-text-text"
|
||||
:title="$t('remarks')">{{$t('remarks')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" :prop="'certificationProgressRemark'">
|
||||
<a-textarea
|
||||
:placeholder="$t('PleaseEnter')+$t('remarks')"
|
||||
v-model="formInline.certificationProgressRemark" :rows="4"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</a-form-model>
|
||||
</a-modal>
|
||||
@@ -122,7 +146,7 @@
|
||||
|
||||
export default {
|
||||
name: 'batSetting',
|
||||
props: ['url'],
|
||||
props: ['url','roleSwitchingCode'],
|
||||
components: {
|
||||
PersonnelSelection
|
||||
},
|
||||
@@ -131,19 +155,36 @@
|
||||
visible: false,
|
||||
confirmLoading: false,
|
||||
formInline: {},
|
||||
rules: {},
|
||||
rules: {
|
||||
|
||||
},
|
||||
ids: [],
|
||||
configurationItemList: [],
|
||||
engineeringInterfacePersonList: [],
|
||||
typeOfDeliverablesList: [],
|
||||
name: ''
|
||||
name: '',
|
||||
DeliverableTreeList: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
disabledDate(current) {
|
||||
return current && current < moment().subtract(1, 'day')
|
||||
},
|
||||
|
||||
getDeliverableTree() {
|
||||
getAction('/sys/category/getDeliverableTree', {}).then((res) => {
|
||||
if (res.success) {
|
||||
this.DeliverableTreeList = res.result
|
||||
} else {
|
||||
this.DeliverableTreeList = []
|
||||
}
|
||||
})
|
||||
},
|
||||
edit(data, name) {
|
||||
this.visible = true
|
||||
this.getDeliverableTree()
|
||||
this.$nextTick(() => {
|
||||
this.ids = data || []
|
||||
this.formInline = {}
|
||||
@@ -163,12 +204,24 @@
|
||||
},
|
||||
handleOkOne() {
|
||||
let ids = JSON.parse(JSON.stringify(this.ids))
|
||||
let formInline = JSON.parse(JSON.stringify(this.formInline))
|
||||
Object.keys(formInline).forEach(res => {
|
||||
if (formInline[res] && formInline[res] instanceof Array) {
|
||||
formInline[res] = formInline[res].join(',')
|
||||
}
|
||||
})
|
||||
let query = {
|
||||
ids: ids.join(','),
|
||||
...this.formInline
|
||||
...formInline
|
||||
}
|
||||
let url = ''
|
||||
this.confirmLoading = true
|
||||
postAction(this.url.setBatch, query).then((res) => {
|
||||
if (this.name == this.$t('changeSetting')) {
|
||||
url = '/project/projectCertificationInventoryEO/updateConfigItemBatch'
|
||||
} else {
|
||||
url = this.url.setBatch
|
||||
}
|
||||
postAction(url, query).then((res) => {
|
||||
if (res.success) {
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.visible = false
|
||||
|
||||
@@ -54,10 +54,10 @@
|
||||
<a-button class="box-button" type="primary" @click="searchQuery">{{ $t('query') }}</a-button>
|
||||
<a-button class="box-button" style="margin-left: 8px"
|
||||
@click="searchReset">{{ $t('reset') }}</a-button>
|
||||
<a @click="handleToggleSearch" style="margin-left: 8px">
|
||||
{{ !toggleSearchStatus ? $t('open') : $t('away') }}
|
||||
<a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
|
||||
</a>
|
||||
<!-- <a @click="handleToggleSearch" style="margin-left: 8px">-->
|
||||
<!-- {{ !toggleSearchStatus ? $t('open') : $t('away') }}-->
|
||||
<!-- <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>-->
|
||||
<!-- </a>-->
|
||||
</a-col>
|
||||
</span>
|
||||
</a-row>
|
||||
@@ -347,7 +347,7 @@
|
||||
</div>
|
||||
<transferList :url="url" @transferListForm="transferListForm" ref="transferListRef"/>
|
||||
<certificationDirectory :isDisplayNum="isDisplayNum" :url="url" ref="certificationDirectoryRef"/>
|
||||
<batSetting :url="url" ref="batSettingRef" @batSettingForm="batSettingForm"/>
|
||||
<batSetting :url="url" ref="batSettingRef" :roleSwitchingCode="roleSwitchingCode" @batSettingForm="batSettingForm"/>
|
||||
<addModel ref="addModelRef" @addModelForm="addModelForm"/>
|
||||
<modifyHistory ref="modifyHistoryRef"/>
|
||||
<uploadFile ref="uploadFile" :isMultiple="true" :disabled="disabled" @uploadSuccess="uploadSuccess"></uploadFile>
|
||||
@@ -473,7 +473,51 @@
|
||||
'NA': 'notInvolvedColor',
|
||||
'Not start': 'submittedColor'
|
||||
},
|
||||
fieldList: [],
|
||||
fieldList: [
|
||||
{
|
||||
type: 'string',
|
||||
value: 'category',
|
||||
text: this.$t('category')
|
||||
},
|
||||
{
|
||||
type: 'string',
|
||||
value: 'inspectionItem',
|
||||
text: this.$t('inspectionItems')
|
||||
},
|
||||
{
|
||||
type: '',
|
||||
value: 'configItem',
|
||||
text: this.$t('configurationItem'),
|
||||
dictCode: 'ren4_zheng4_qing1_dan1_-_pei4_zhi4_xiang4'//只要 dictCode 有值,无论 type 是什么,都显示为字典下拉框
|
||||
},
|
||||
{
|
||||
type: 'string',
|
||||
value: 'wvtaId',
|
||||
text: 'WVTA ID'
|
||||
},
|
||||
{
|
||||
type: 'string',
|
||||
value: 'serialNumber',
|
||||
text: this.$t('standardNo')
|
||||
},
|
||||
{
|
||||
type: 'Personnel',
|
||||
value: 'sdt',
|
||||
valueName: 'sdtName',
|
||||
text: this.$t('engineeringInterfacePerson')
|
||||
},
|
||||
{
|
||||
type: 'Personnel',
|
||||
value: 'dutyPerson',
|
||||
valueName: 'dutyPersonName',
|
||||
text: this.$t('personLiable')
|
||||
},
|
||||
{
|
||||
type: 'date',
|
||||
value: 'endTime',
|
||||
text: this.$t('closingDate')
|
||||
},
|
||||
],
|
||||
disabled: false,
|
||||
queryParamQuery: {},
|
||||
formInline: {},
|
||||
@@ -538,7 +582,7 @@
|
||||
{
|
||||
title: this.$t('configurationItem'),
|
||||
align: 'left',
|
||||
dataIndex: 'configItem',
|
||||
dataIndex: 'configItem_dictText',
|
||||
width: 180,
|
||||
ellipsis: true
|
||||
},
|
||||
@@ -1187,6 +1231,8 @@
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.visibleRoleSwitching = false
|
||||
this.confirmLoadingRoleSwitching = false
|
||||
this.selectedRowKeysList = []
|
||||
this.selectedRowKeys = []
|
||||
this.getList()
|
||||
this.$emit('getRoleSwitch', this.roleSwitchingCode)
|
||||
} else {
|
||||
|
||||
@@ -15,14 +15,22 @@
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('regulationNo')">{{$t('regulationNo')}}</span>
|
||||
<span class="title-text-text" :title="$t ('regulationNo')">{{$t('regulationNo')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="regulationNo">
|
||||
<j-dict-select-tag class="box-input"
|
||||
:disabled="disabled"
|
||||
:placeholder="$t('PleaseSelect')+$t('regulationNo')"
|
||||
:type="'select'"
|
||||
:triggerChange="false"/>
|
||||
<a-form-model-item class="itemModel" prop="serialNumber">
|
||||
<a-select showSearch
|
||||
allowClear
|
||||
:placeholder="$t('PleaseSelect')+$t('regulationNo')"
|
||||
@change="serialNumberChange"
|
||||
v-model="formInline.bussDocumentLibraryId">
|
||||
<a-select-option v-for="(item, key) in projectNameList"
|
||||
:key="key"
|
||||
:value="item.id">
|
||||
<span style="display: inline-block;width: 100%" :title=" item.serialNumber ">
|
||||
{{ item.serialNumber}}
|
||||
</span>
|
||||
</a-select-option>
|
||||
</a-select>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -32,12 +40,13 @@
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('areaOfResponsibility')">{{$t('areaOfResponsibility')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-form-model-item class="itemModel" prop="dutyTerritory">
|
||||
<j-dict-select-tag class="box-input"
|
||||
:disabled="disabled"
|
||||
v-model="formInline.dutyTerritory"
|
||||
:placeholder="$t('PleaseSelect')+$t('areaOfResponsibility')"
|
||||
:type="'select'"
|
||||
:triggerChange="false"/>
|
||||
:triggerChange="false" :dictCode="'duty_territory'"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -49,9 +58,9 @@
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="'WVTA ID'">WVTA ID</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel">
|
||||
<a-form-model-item class="itemModel" prop="wvtaId">
|
||||
<a-input class="box-input"
|
||||
v-model='formInline.dddd'
|
||||
v-model='formInline.wvtaId'
|
||||
:disabled="disabled"
|
||||
:placeholder="$t('PleaseEnter')+'WVTA ID'"/>
|
||||
</a-form-model-item>
|
||||
@@ -59,15 +68,12 @@
|
||||
</a-col>
|
||||
</a-row>
|
||||
<div v-for="(item,index) in formInline.dataList" :key="index">
|
||||
<div class="header-text">
|
||||
<span>{{$t('itemInformation')}}</span>
|
||||
<div class="box-title-text" style="margin-left: 10px">
|
||||
<a-button @click='addClick(index)' style="margin-right: .8rem" icon="plus">
|
||||
</a-button>
|
||||
<a-button v-if="formInline.dataList.length > 1" @click="deleteClick(index)" type="primary" icon="minus">
|
||||
</a-button>
|
||||
<div class="header-text">
|
||||
{{$t('itemInformation')}}
|
||||
<a-icon class="icon-text" @click="addClick(index)" type="plus-circle"/>
|
||||
<a-icon class="icon-text" v-if="formInline.dataList.length > 1" @click="deleteClick(index)"
|
||||
type="minus-circle"/>
|
||||
</div>
|
||||
</div>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
@@ -75,13 +81,14 @@
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('category')">{{$t('category')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="category">
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.category'"
|
||||
:rules="[{ required: true, message: $t('category') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('category') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'}]"
|
||||
>
|
||||
<a-input class="box-input"
|
||||
v-model="item.category"
|
||||
:disabled="disabled"
|
||||
:placeholder="$t('PleaseSelect')+$t('category')"
|
||||
:type="'select'"
|
||||
:triggerChange="false"/>
|
||||
v-model="item.category"
|
||||
:placeholder="$t('PleaseEnter')+$t('category')"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -91,13 +98,14 @@
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('inspectionItems')">{{$t('inspectionItems')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="inspectionItems">
|
||||
<j-dict-select-tag class="box-input"
|
||||
v-model="item.inspectionItems"
|
||||
:disabled="disabled"
|
||||
:placeholder="$t('PleaseSelect')+$t('inspectionItems')"
|
||||
:type="'select'"
|
||||
:triggerChange="false"/>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.inspectionItem'"
|
||||
:rules="[{ required: true, message: $t('inspectionItems') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('inspectionItems') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'}]"
|
||||
>
|
||||
<a-input class="box-input"
|
||||
v-model="item.inspectionItem"
|
||||
:placeholder="$t('PleaseEnter')+$t('inspectionItems')"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -107,15 +115,40 @@
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('Deliverables')">{{$t('Deliverables')}}</span>
|
||||
<span class="title-text-text" :title="$t('configurationItem')">{{$t('configurationItem')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="Deliverables">
|
||||
<j-dict-select-tag class="box-input"
|
||||
v-model="item.Deliverables"
|
||||
:disabled="disabled"
|
||||
:placeholder="$t('PleaseSelect')+$t('Deliverables')"
|
||||
:type="'select'"
|
||||
:triggerChange="false"/>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.configItem'"
|
||||
:rules="[{ required: true, message: $t('configurationItem') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('configurationItem') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'
|
||||
}]">
|
||||
<a-input class="box-input"
|
||||
v-model="item.configItem"
|
||||
:placeholder="$t('PleaseEnter')+$t('configurationItem')"/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="box-title-text">
|
||||
<div class="title-text">
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('typeOfDeliverables')">{{$t('typeOfDeliverables')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.deliverableType'"
|
||||
:rules="[{ required: true, message: $t('typeOfDeliverables') + $t('cannotEmpty'), trigger: 'change'},]"
|
||||
>
|
||||
<a-tree-select
|
||||
tree-node-filter-prop="title"
|
||||
v-model="item.deliverableType"
|
||||
:maxTagCount="1"
|
||||
:getPopupContainer="triggerNode=> triggerNode.parentNode"
|
||||
class="box-input"
|
||||
style="width: 100%"
|
||||
:tree-data="DeliverableTreeList"
|
||||
tree-checkable
|
||||
:placeholder="$t('PleaseSelect')+$t('typeOfDeliverables')"
|
||||
/>
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
</a-col>
|
||||
@@ -132,6 +165,7 @@
|
||||
|
||||
<script>
|
||||
import { getAction, postAction } from '@/api/manage'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
name:"addModel",
|
||||
@@ -142,18 +176,44 @@ export default {
|
||||
disabled: false,
|
||||
formInline: {},
|
||||
confirmLoading: false,
|
||||
projectNameList: [],
|
||||
DeliverableTreeList: [],
|
||||
rules: {
|
||||
regulationNo: [
|
||||
// {
|
||||
// required: true,
|
||||
// message: this.$t('regulationNo') + this.$t('cannotEmpty'),
|
||||
// trigger: 'change'
|
||||
// }
|
||||
]
|
||||
serialNumber: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('entryName') + this.$t('regulationNo'),
|
||||
trigger: 'change'
|
||||
}
|
||||
],
|
||||
dutyTerritory: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('entryName') + this.$t('areaOfResponsibility'),
|
||||
trigger: 'change'
|
||||
}
|
||||
],
|
||||
wvtaId: [
|
||||
{
|
||||
required: true,
|
||||
message: 'WVTA ID' + this.$t('regulationNo'),
|
||||
trigger: 'change'
|
||||
},
|
||||
{
|
||||
max: 300,
|
||||
message: 'WVTA ID' + this.$t('cannotExceed') + 300 + this.$t('Characters'),
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
},
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.getDeliverableTree()
|
||||
this.getRegulationNo()
|
||||
},
|
||||
methods: {
|
||||
...mapGetters(['userInfo']),
|
||||
addModel() {
|
||||
this.visible = true
|
||||
this.formInline = {}
|
||||
@@ -170,13 +230,6 @@ export default {
|
||||
this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
let query = JSON.parse(JSON.stringify(this.formInline))
|
||||
query.dataList.forEach(val => {
|
||||
Object.keys(query).forEach(res => {
|
||||
if (query[res] && query[res] instanceof Array) {
|
||||
query[res] = query[res].join(',')
|
||||
}
|
||||
})
|
||||
})
|
||||
this.confirmLoading = true
|
||||
postAction(this.url.addModel, query).then((res) => {
|
||||
if (res.success) {
|
||||
@@ -199,7 +252,36 @@ export default {
|
||||
deleteClick(index) {
|
||||
this.formInline.dataList.splice(index, 1)
|
||||
this.formInline = { ...this.formInline }
|
||||
}
|
||||
},
|
||||
getRegulationNo() {
|
||||
let query = {
|
||||
projectLibraryId: this.$route.query.id,
|
||||
roleCode: 0
|
||||
}
|
||||
getAction(this.url.number, query).then((res) => {
|
||||
if (res.success) {
|
||||
this.projectNameList = res.result || []
|
||||
} else {
|
||||
this.projectNameList = []
|
||||
}
|
||||
})
|
||||
},
|
||||
serialNumberChange(value) {
|
||||
let content = this.projectNameList.filter(res => {
|
||||
return res.id === value
|
||||
})
|
||||
this.formInline.bussDocumentLibraryId = content[0].id
|
||||
this.formInline.serialNumber = content[0].serialNumber
|
||||
},
|
||||
getDeliverableTree() {
|
||||
getAction('/sys/category/getDeliverableTree', {}).then((res) => {
|
||||
if (res.success) {
|
||||
this.DeliverableTreeList = res.result
|
||||
} else {
|
||||
this.DeliverableTreeList = []
|
||||
}
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -246,12 +328,7 @@ export default {
|
||||
|
||||
.header-text {
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
margin-left: 15px;
|
||||
/*border-bottom: 1px #d9d9d9 dashed;*/
|
||||
height: 30px;
|
||||
margin-bottom: 30px;
|
||||
display: flex;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.drawer-bootom-button {
|
||||
@@ -266,4 +343,9 @@ export default {
|
||||
background: #fff;
|
||||
border-radius: 0 0 2px 2px;
|
||||
}
|
||||
|
||||
.icon-text {
|
||||
font-size: 16px;
|
||||
margin-right: 4px;
|
||||
}
|
||||
</style>
|
||||
+1
@@ -266,6 +266,7 @@ export default {
|
||||
deleteBatch: '/authDummy/authDummyInventoryInfoEO/deleteBatch',//批量删除
|
||||
editModel: '/authDummy/authDummyInventoryInfoEO/edit',//编辑
|
||||
setBatch: '/authDummy/authDummyInventoryInfoEO/setBatch',//批量设置
|
||||
number: '/project/projectLawsInventoryEO/list',
|
||||
},
|
||||
queryParam: {},
|
||||
orderByField: '',
|
||||
|
||||
Reference in New Issue
Block a user