dev_xds
姜玉琦 2023-09-17 02:07:22 +08:00
commit 4bb491435b
33 changed files with 612 additions and 160 deletions

View File

@ -53,6 +53,9 @@ public @interface Excel
*/ */
public int scale() default -1; public int scale() default -1;
public boolean isLink() default false;
public String linkText() default "";
/** /**
* BigDecimal :BigDecimal.ROUND_HALF_EVEN * BigDecimal :BigDecimal.ROUND_HALF_EVEN
*/ */

View File

@ -27,45 +27,15 @@ import javax.servlet.http.HttpServletResponse;
import org.apache.commons.lang3.ArrayUtils; import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.RegExUtils; import org.apache.commons.lang3.RegExUtils;
import org.apache.commons.lang3.reflect.FieldUtils; import org.apache.commons.lang3.reflect.FieldUtils;
import org.apache.poi.hssf.usermodel.HSSFClientAnchor; import org.apache.poi.common.usermodel.HyperlinkType;
import org.apache.poi.hssf.usermodel.HSSFPicture; import org.apache.poi.hssf.usermodel.*;
import org.apache.poi.hssf.usermodel.HSSFPictureData;
import org.apache.poi.hssf.usermodel.HSSFShape;
import org.apache.poi.hssf.usermodel.HSSFSheet;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.ooxml.POIXMLDocumentPart; import org.apache.poi.ooxml.POIXMLDocumentPart;
import org.apache.poi.ss.usermodel.BorderStyle; import org.apache.poi.ss.usermodel.*;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.CellStyle;
import org.apache.poi.ss.usermodel.CellType;
import org.apache.poi.ss.usermodel.ClientAnchor;
import org.apache.poi.ss.usermodel.DataValidation;
import org.apache.poi.ss.usermodel.DataValidationConstraint;
import org.apache.poi.ss.usermodel.DataValidationHelper;
import org.apache.poi.ss.usermodel.DateUtil;
import org.apache.poi.ss.usermodel.Drawing;
import org.apache.poi.ss.usermodel.FillPatternType;
import org.apache.poi.ss.usermodel.Font;
import org.apache.poi.ss.usermodel.HorizontalAlignment;
import org.apache.poi.ss.usermodel.IndexedColors;
import org.apache.poi.ss.usermodel.Name;
import org.apache.poi.ss.usermodel.PictureData;
import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Sheet;
import org.apache.poi.ss.usermodel.VerticalAlignment;
import org.apache.poi.ss.usermodel.Workbook;
import org.apache.poi.ss.usermodel.WorkbookFactory;
import org.apache.poi.ss.util.CellRangeAddress; import org.apache.poi.ss.util.CellRangeAddress;
import org.apache.poi.ss.util.CellRangeAddressList; import org.apache.poi.ss.util.CellRangeAddressList;
import org.apache.poi.util.IOUtils; import org.apache.poi.util.IOUtils;
import org.apache.poi.xssf.streaming.SXSSFWorkbook; import org.apache.poi.xssf.streaming.SXSSFWorkbook;
import org.apache.poi.xssf.usermodel.XSSFClientAnchor; import org.apache.poi.xssf.usermodel.*;
import org.apache.poi.xssf.usermodel.XSSFDataValidation;
import org.apache.poi.xssf.usermodel.XSSFDrawing;
import org.apache.poi.xssf.usermodel.XSSFPicture;
import org.apache.poi.xssf.usermodel.XSSFShape;
import org.apache.poi.xssf.usermodel.XSSFSheet;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTMarker; import org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTMarker;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
@ -1016,6 +986,7 @@ public class ExcelUtil<T>
{ {
// 创建cell // 创建cell
cell = row.createCell(column); cell = row.createCell(column);
if (isSubListValue(vo) && getListCellValue(vo).size() > 1 && attr.needMerge()) if (isSubListValue(vo) && getListCellValue(vo).size() > 1 && attr.needMerge())
{ {
CellRangeAddress cellAddress = new CellRangeAddress(subMergedFirstRowNum, subMergedLastRowNum, column, column); CellRangeAddress cellAddress = new CellRangeAddress(subMergedFirstRowNum, subMergedLastRowNum, column, column);
@ -1059,7 +1030,20 @@ public class ExcelUtil<T>
// 设置列类型 // 设置列类型
setCellVo(value, attr, cell); setCellVo(value, attr, cell);
} }
if(attr.isLink()){
CreationHelper createHelper= row.getSheet().getWorkbook().getCreationHelper();
XSSFHyperlink link = (XSSFHyperlink) createHelper.createHyperlink(HyperlinkType.URL);
link.setAddress((String) value);
cell.setHyperlink(link);
if( StringUtils.isNotEmpty (attr.linkText())){
cell.setCellValue(attr.linkText());
}else{
cell.setCellValue(value.toString());
}
}
addStatisticsData(column, Convert.toStr(value), attr); addStatisticsData(column, Convert.toStr(value), attr);
} }
} }
catch (Exception e) catch (Exception e)

View File

@ -613,16 +613,6 @@
</el-input> </el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="总投资" prop="totalInvestment">
<el-input v-model="form.totalInvestment" placeholder="请输入总投资">
<i slot="suffix">万元</i>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="建筑面积" prop="floorArea"> <el-form-item label="建筑面积" prop="floorArea">
<el-input v-model="form.floorArea" placeholder="请输入建筑面积"> <el-input v-model="form.floorArea" placeholder="请输入建筑面积">
@ -630,13 +620,11 @@
</el-input> </el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8"> </el-row>
<el-form-item label="开累产值" prop="totalOutputValue">
<el-input v-model="form.totalOutputValue" placeholder="请输入开累产值"> <el-row>
<i slot="suffix">万元</i>
</el-input>
</el-form-item>
</el-col>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="计划完成时间" prop="plannedCompletionTime"> <el-form-item label="计划完成时间" prop="plannedCompletionTime">
<el-date-picker <el-date-picker
@ -648,8 +636,6 @@
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row>
<el-row>
<el-col :span="8"> <el-col :span="8">
<el-form-item label="计划开工时间" prop="scheduledStartTime"> <el-form-item label="计划开工时间" prop="scheduledStartTime">
<el-date-picker <el-date-picker
@ -670,6 +656,10 @@
> >
</el-date-picker> </el-form-item </el-date-picker> </el-form-item
></el-col> ></el-col>
</el-row>
<el-row>
<el-col :span="8" <el-col :span="8"
><el-form-item label="实际完工时间" prop="actualCompletionTime"> ><el-form-item label="实际完工时间" prop="actualCompletionTime">
<el-date-picker <el-date-picker
@ -680,31 +670,6 @@
> >
</el-date-picker> </el-form-item </el-date-picker> </el-form-item
></el-col> ></el-col>
</el-row>
<el-row>
<el-col :span="8"
><el-form-item label="合同总额" prop="contractAmount">
<el-input v-model="form.contractAmount" placeholder="请输入合同总额">
<i slot="suffix">万元</i>
</el-input>
</el-form-item></el-col
>
<el-col :span="8">
<el-form-item label="付款金额" prop="paidAmount">
<el-input v-model="form.paidAmount" placeholder="请输入付款金额">
<i slot="suffix">万元</i>
</el-input>
</el-form-item></el-col
>
<el-col :span="8">
<el-form-item label="挂账金额" prop="onAccountAmount">
<el-input v-model="form.onAccountAmount" placeholder="请输入挂账金额">
<i slot="suffix">万元</i>
</el-input>
</el-form-item></el-col
>
</el-row>
<el-row>
<el-col :span="8" <el-col :span="8"
><el-form-item label="形象进度" prop="projectSchedule"> ><el-form-item label="形象进度" prop="projectSchedule">
<el-select <el-select
@ -721,22 +686,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8">
<el-form-item label="重要等级" prop="weightType">
<el-select
v-model="form.weightType"
placeholder="请选择重要等级"
style="width: 100%"
>
<el-option
v-for="dict in dict.type.sur_project_weight"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
</el-select> </el-form-item
></el-col>
<el-col :span="8"></el-col>
</el-row> </el-row>
<!-- <el-row> <!-- <el-row>
<el-col :span="8" <el-col :span="8"

View File

@ -16,13 +16,15 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="提交用户" prop="createUser"> <el-form-item label="分类" prop="createUser">
<el-input <el-select v-model="queryParams.roleTypes" multiple placeholder="请选择分类" clearable collapse-tags>
v-model="queryParams.createUser" <el-option
placeholder="请输入提交用户手机号" v-for="dict in roleTypeOpts"
clearable :key="dict.value"
@keyup.enter.native="handleQuery" :label="dict.label"
:value="dict.value"
/> />
</el-select>
</el-form-item> </el-form-item>
<el-form-item label="隐患描述" prop="workParts"> <el-form-item label="隐患描述" prop="workParts">
<el-input <el-input
@ -76,6 +78,7 @@
>搜索</el-button >搜索</el-button
> >
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button> <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
<el-button icon="el-icon-download" size="mini" v-hasPermi="['trouble:sspProblemmodify:export']" @click="handleExport"></el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -465,6 +468,7 @@ export default {
createTime: null, createTime: null,
updateUser: null, updateUser: null,
updateTime: null, updateTime: null,
roleTypes:[],
projectDeptId: null, projectDeptId: null,
}, },
depts: null, depts: null,
@ -485,6 +489,13 @@ export default {
ycl: "整改完成0", ycl: "整改完成0",
zgcs: "整改超时0", zgcs: "整改超时0",
}, },
roleTypeOpts:[
{label:'集团',value:3}
,{label:'子公司',value:4}
,{label:'甲方代表',value:5}
,{label:'监理单位',value:6}
,{label:'总包单位',value:7}]
}; };
}, },
created() { created() {
@ -526,9 +537,10 @@ export default {
if (response && response.data) { if (response && response.data) {
let sum = 0; let sum = 0;
this.tabs.dzg = "待整改0"; this.tabs.dzg = "待整改0";
if (response.data.check0) { let chk03=(response.data.check0)+(response.data.check3)
sum += response.data.check0; if (chk03) {
this.tabs.dzg = "待整改(" + response.data.check0 + ""; sum += chk03;
this.tabs.dzg = "待整改(" + chk03 + "";
} }
this.tabs.dqr = "待复检0"; this.tabs.dqr = "待复检0";
if (response.data.check1) { if (response.data.check1) {
@ -596,6 +608,7 @@ export default {
}, },
/** 重置按钮操作 */ /** 重置按钮操作 */
resetQuery() { resetQuery() {
this.queryParams.roleTypes=[];
this.daterangeMarksTime = []; this.daterangeMarksTime = [];
this.resetForm("queryForm"); this.resetForm("queryForm");
this.handleQuery(); this.handleQuery();
@ -672,7 +685,7 @@ export default {
{ {
...this.queryParams, ...this.queryParams,
}, },
`sspProblemmodify_${new Date().getTime()}.xlsx` `安全整改_${new Date().getTime()}.xlsx`
); );
}, },
}, },

View File

@ -16,13 +16,15 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="提交用户" prop="createUser"> <el-form-item label="分类" prop="createUser">
<el-input <el-select v-model="queryParams.roleTypes" multiple placeholder="请选择分类" clearable collapse-tags>
v-model="queryParams.createUser" <el-option
placeholder="请输入提交用户手机号" v-for="dict in roleTypeOpts"
clearable :key="dict.value"
@keyup.enter.native="handleQuery" :label="dict.label"
:value="dict.value"
/> />
</el-select>
</el-form-item> </el-form-item>
<el-form-item label="隐患描述" prop="workParts"> <el-form-item label="隐患描述" prop="workParts">
<el-input <el-input
@ -76,6 +78,7 @@
>搜索</el-button >搜索</el-button
> >
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button> <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
<el-button icon="el-icon-download" size="mini" v-hasPermi="['trouble:sspProblemmodify:export']" @click="handleExport"></el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -459,6 +462,7 @@ export default {
createTime: null, createTime: null,
updateUser: null, updateUser: null,
updateTime: null, updateTime: null,
roleTypes:[],
projectDeptId: null, projectDeptId: null,
}, },
depts: null, depts: null,
@ -479,6 +483,12 @@ export default {
ycl: "整改完成0", ycl: "整改完成0",
zgcs: "整改超时0", zgcs: "整改超时0",
}, },
roleTypeOpts:[
{label:'集团',value:3}
,{label:'子公司',value:4}
,{label:'甲方代表',value:5}
,{label:'监理单位',value:6}
,{label:'总包单位',value:7}]
}; };
}, },
created() { created() {
@ -520,9 +530,10 @@ export default {
if (response && response.data) { if (response && response.data) {
let sum = 0; let sum = 0;
this.tabs.dzg = "待整改0"; this.tabs.dzg = "待整改0";
if (response.data.check0) { let chk03=(response.data.check0)+(response.data.check3)
sum += response.data.check0; if (chk03) {
this.tabs.dzg = "待整改(" + response.data.check0 + ""; sum += chk03;
this.tabs.dzg = "待整改(" + chk03 + "";
} }
this.tabs.dqr = "待复检0"; this.tabs.dqr = "待复检0";
if (response.data.check1) { if (response.data.check1) {
@ -590,6 +601,7 @@ export default {
}, },
/** 重置按钮操作 */ /** 重置按钮操作 */
resetQuery() { resetQuery() {
this.queryParams.roleTypes=[];
this.daterangeMarksTime = []; this.daterangeMarksTime = [];
this.resetForm("queryForm"); this.resetForm("queryForm");
this.handleQuery(); this.handleQuery();
@ -666,7 +678,7 @@ export default {
{ {
...this.queryParams, ...this.queryParams,
}, },
`sspProblemmodify_${new Date().getTime()}.xlsx` `质量整改_${new Date().getTime()}.xlsx`
); );
}, },
}, },

View File

@ -10,7 +10,7 @@
/> />
</el-form-item> </el-form-item>
<el-form-item label="文件归属" prop="fileBelong"> <el-form-item label="文件归属" prop="fileBelong">
<el-select v-model="queryParams.fileBelong" placeholder="请选择文件归属" clearable> <el-select v-model="queryParams.fileBelong" placeholder="请选择文件归属" clearable @change="doFileBelongChange">
<el-option <el-option
v-for="dict in dict.type.work_file_belong" v-for="dict in dict.type.work_file_belong"
:key="dict.value" :key="dict.value"
@ -19,14 +19,15 @@
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="文件状态" prop="isDel"> <el-form-item label="子公司" v-show="queryParams.fileBelong==3">
<el-select v-model="queryParams.isDel" placeholder="请选择文件归属" clearable> <el-select v-model="queryParams.deptId" placeholder="请选择子公司" clearable>
<el-option label="产发集团" :value="0"></el-option>
<el-option <el-option
v-for="dict in dict.type.sys_common_isdel" v-for="dict in depts"
:key="dict.value" :key="dict.deptId"
:label="dict.label" :label="dict.deptName"
:value="dict.value" :value="dict.deptId"
/> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="上传时间"> <el-form-item label="上传时间">
@ -97,7 +98,8 @@
<el-table-column label="主键" align="center" prop="id" v-if="false"/> <el-table-column label="主键" align="center" prop="id" v-if="false"/>
<el-table-column label="文件归属" align="center" width="80" prop="fileBelong"> <el-table-column label="文件归属" align="center" width="80" prop="fileBelong">
<template slot-scope="scope"> <template slot-scope="scope">
<dict-tag :options="dict.type.work_file_belong" :value="scope.row.fileBelong"/> <dict-tag :options="dict.type.work_file_belong" :value="scope.row.fileBelong" v-if="scope.row.fileBelong<3"/>
<span v-else>{{ scope.row.deptName}}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="文件名称" align="left" prop="fileName" show-overflow-tooltip width="300"/> <el-table-column label="文件名称" align="left" prop="fileName" show-overflow-tooltip width="300"/>
@ -169,6 +171,16 @@
:value="dict.value" :value="dict.value"
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item>
<el-form-item label="子公司" v-if="form.fileBelong==3" prop="deptId">
<el-select v-model="form.deptId" placeholder="请选择子公司" clearable>
<el-option
v-for="dict in depts"
:key="dict.deptId"
:label="dict.deptName"
:value="dict.deptId"
></el-option>
</el-select>
</el-form-item> </el-form-item>
<el-form-item label="上传文件" prop="fileData"> <el-form-item label="上传文件" prop="fileData">
<FileUpload @input="fileInput"/> <FileUpload @input="fileInput"/>
@ -217,7 +229,8 @@ export default {
pageSize: 10, pageSize: 10,
fileBelong: null, fileBelong: null,
fileName: null, fileName: null,
isDel:null isDel:null,
deptId:0,
}, },
// //
form: {}, form: {},
@ -226,6 +239,9 @@ export default {
fileBelong: [ fileBelong: [
{ required: true, message: "请选择文件归属", trigger: "blur" } { required: true, message: "请选择文件归属", trigger: "blur" }
], ],
deptId:[
{ required: true, message: "请选择子公司", trigger: "blur" }
],
remark: [ remark: [
{ required: false}, { required: false},
{ max: 200,message: "最多输入200字符" } { max: 200,message: "最多输入200字符" }
@ -233,13 +249,20 @@ export default {
}, },
// //
daterangeMarksTime: [], daterangeMarksTime: [],
fileList: [] fileList: [],
depts: [],
}; };
}, },
created() { created() {
this.getList(); this.getList();
this.$api.publics.getZgsDeptList().then((d) => {
this.depts = d?.data || [];
});
}, },
methods: { methods: {
doFileBelongChange(){
this.queryParams.deptId=0;
},
/** 查询文件传达列表 */ /** 查询文件传达列表 */
getList() { getList() {
this.loading = true; this.loading = true;

View File

@ -41,8 +41,8 @@ module.exports = {
} }
}, },
'/jhapi':{ '/jhapi':{
target: `http://62.234.3.186/jhapi/`, //target: `http://62.234.3.186/jhapi/`,
//target: `http://127.0.0.1:8090/jhapi/`, target: `http://127.0.0.1:8090/jhapi/`,
changeOrigin: true, changeOrigin: true,
pathRewrite: { pathRewrite: {
'^/jhapi':'/' '^/jhapi':'/'

View File

@ -25,9 +25,10 @@ public class BgWorkFileController extends BaseController {
* @return * @return
*/ */
@GetMapping("/getWorkFileList") @GetMapping("/getWorkFileList")
public TableDataInfo getWorkFileList(String fileBelong){ public TableDataInfo getWorkFileList(String fileBelong,long deptId){
WorkFile workFile = new WorkFile(); WorkFile workFile = new WorkFile();
workFile.setFileBelong(fileBelong); workFile.setFileBelong(fileBelong);
workFile.setDeptId(deptId);
return getDataTable(workFileService.selectWorkFileListLimit20(workFile)); return getDataTable(workFileService.selectWorkFileListLimit20(workFile));
} }

View File

@ -176,6 +176,6 @@ public class ProblemmodifyController extends BaseController {
@PostMapping("/listSspProblemmodify") @PostMapping("/listSspProblemmodify")
public AjaxResult listSspProblemmodify(@RequestBody SmzSspProblemmodifyWhere where){ public AjaxResult listSspProblemmodify(@RequestBody SmzSspProblemmodifyWhere where){
return AjaxResult.success(smzSspProblemmodifyService.selectSmzSspProblemmodifyList(where)); return AjaxResult.success(smzSspProblemmodifyService.selectSmzSspProblemmodifyListAndUnitName(where));
} }
} }

View File

@ -28,7 +28,7 @@ public class ProjectCheckDetectionController {
* @param where checkType deptId projectId * @param where checkType deptId projectId
* @return * @return
*/ */
@PostMapping("groupByCheckType") @PostMapping("/groupByCheckType")
public AjaxResult groupByCheckType(@RequestBody SurProjectCheckDetection where){ public AjaxResult groupByCheckType(@RequestBody SurProjectCheckDetection where){
String key="bgscreen_checkDetection_groupMeasureInfo_"+where.getCheckType()+"_"+where.getDeptId()+"_"+where.getProjectId(); String key="bgscreen_checkDetection_groupMeasureInfo_"+where.getCheckType()+"_"+where.getDeptId()+"_"+where.getProjectId();
Object obj=redisCache.getCacheObject(key); Object obj=redisCache.getCacheObject(key);
@ -39,4 +39,15 @@ public class ProjectCheckDetectionController {
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES); redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
return AjaxResult.success(list); return AjaxResult.success(list);
} }
@PostMapping("/getList")
public AjaxResult getList(@RequestBody SurProjectCheckDetection where){
String key="bgscreen_getList_groupMeasureInfo_"+where.getCheckType()+"_"+where.getDeptId()+"_"+where.getProjectId();
Object obj=redisCache.getCacheObject(key);
if(obj!=null){
return AjaxResult.success(obj);
}
List<SurProjectCheckDetection> list=checkDetectionService.getList(where);
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
return AjaxResult.success(list);
}
} }

View File

@ -26,15 +26,26 @@ public class ProjectMeasureController {
* @param where measureType deptId projectId * @param where measureType deptId projectId
* @return * @return
*/ */
@PostMapping("groupMeasureInfo") @PostMapping("/groupMeasureInfo")
public AjaxResult groupMeasureInfo(@RequestBody SurProjectMeasure where){ public AjaxResult groupMeasureInfo(@RequestBody SurProjectMeasure where){
String key="bgscreen_measure_groupMeasureInfo_"+where.getMeasureType()+"_"+where.getDeptId()+"_"+where.getProjectId(); String key="bgscreen_measure_groupMeasureInfo_"+where.getMeasureType()+"_"+where.getDeptId()+"_"+where.getProjectId();
//Object obj=redisCache.getCacheObject(key); Object obj=redisCache.getCacheObject(key);
// if(obj!=null){ if(obj!=null){
// return AjaxResult.success(obj); return AjaxResult.success(obj);
// } }
List<SurProjectMeasure> list=measureService.groupMeasureInfo(where); List<SurProjectMeasure> list=measureService.groupMeasureInfo(where);
//redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES); redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
return AjaxResult.success(list);
}
@PostMapping("/getList")
public AjaxResult getList(@RequestBody SurProjectMeasure where){
String key="bgscreen_measure_getList_"+where.getMeasureType()+"_"+where.getDeptId()+"_"+where.getProjectId();
Object obj=redisCache.getCacheObject(key);
if(obj!=null){
return AjaxResult.success(obj);
}
List<SurProjectMeasure> list=measureService.getList(where);
redisCache.setCacheObject(key, list, Constants.BIGSCREEN_QUERY_CACHE, TimeUnit.MINUTES);
return AjaxResult.success(list); return AjaxResult.success(list);
} }
} }

View File

@ -97,6 +97,25 @@ public class SurProjectCheckDetection extends BaseEntity
private String projectName; private String projectName;
private String deptName; private String deptName;
private String createByName;
private String updateByName;
public String getCreateByName() {
return createByName;
}
public void setCreateByName(String createByName) {
this.createByName = createByName;
}
public String getUpdateByName() {
return updateByName;
}
public void setUpdateByName(String updateByName) {
this.updateByName = updateByName;
}
public void setId(Long id) public void setId(Long id)
{ {
this.id = id; this.id = id;

View File

@ -89,6 +89,24 @@ public class SurProjectMeasure extends BaseEntity
private String deptName; private String deptName;
private String measureTypeName; private String measureTypeName;
private String measureInfoName; private String measureInfoName;
private String createByName;
private String updateByName;
public String getCreateByName() {
return createByName;
}
public void setCreateByName(String createByName) {
this.createByName = createByName;
}
public String getUpdateByName() {
return updateByName;
}
public void setUpdateByName(String updateByName) {
this.updateByName = updateByName;
}
public void setId(Long id) public void setId(Long id)
{ {

View File

@ -85,4 +85,5 @@ public interface SurProjectCheckDetectionMapper
*/ */
public List<Map<String,Object>> findGroupCountByProjectId(Long projectId); public List<Map<String,Object>> findGroupCountByProjectId(Long projectId);
public List<SurProjectCheckDetection> getList(SurProjectCheckDetection where);
} }

View File

@ -70,4 +70,6 @@ public interface SurProjectMeasureMapper
public List<Map<String,Object>> findGroupCountByProjectId(Long projectId); public List<Map<String,Object>> findGroupCountByProjectId(Long projectId);
public List<SurProjectMeasure> groupMeasureInfo(SurProjectMeasure where); public List<SurProjectMeasure> groupMeasureInfo(SurProjectMeasure where);
public List<SurProjectMeasure> getList(SurProjectMeasure where);
} }

View File

@ -84,4 +84,6 @@ public interface ISurProjectCheckDetectionService
* @return * @return
*/ */
public List<Map<String,Object>> findGroupCountByProjectId(Long projectId); public List<Map<String,Object>> findGroupCountByProjectId(Long projectId);
public List<SurProjectCheckDetection> getList(SurProjectCheckDetection where);
} }

View File

@ -70,4 +70,6 @@ public interface ISurProjectMeasureService
public List<Map<String,Object>> findGroupCountByProjectId(Long projectId); public List<Map<String,Object>> findGroupCountByProjectId(Long projectId);
public List<SurProjectMeasure> groupMeasureInfo(SurProjectMeasure where); public List<SurProjectMeasure> groupMeasureInfo(SurProjectMeasure where);
public List<SurProjectMeasure> getList(SurProjectMeasure where);
} }

View File

@ -145,4 +145,9 @@ public class SurProjectCheckDetectionServiceImpl implements ISurProjectCheckDete
public List<Map<String,Object>> findGroupCountByProjectId(Long projectId){ public List<Map<String,Object>> findGroupCountByProjectId(Long projectId){
return surProjectCheckDetectionMapper.findGroupCountByProjectId(projectId); return surProjectCheckDetectionMapper.findGroupCountByProjectId(projectId);
} }
@Override
public List<SurProjectCheckDetection> getList(SurProjectCheckDetection where) {
return surProjectCheckDetectionMapper.getList(where);
}
} }

View File

@ -118,4 +118,9 @@ public class SurProjectMeasureServiceImpl implements ISurProjectMeasureService
public List<SurProjectMeasure> groupMeasureInfo(SurProjectMeasure where) { public List<SurProjectMeasure> groupMeasureInfo(SurProjectMeasure where) {
return surProjectMeasureMapper.groupMeasureInfo(where); return surProjectMeasureMapper.groupMeasureInfo(where);
} }
@Override
public List<SurProjectMeasure> getList(SurProjectMeasure where) {
return surProjectMeasureMapper.getList(where);
}
} }

View File

@ -1,12 +1,16 @@
package com.yanzhu.jh.trouble.controller; package com.yanzhu.jh.trouble.controller;
import java.util.ArrayList;
import java.util.List; import java.util.List;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import com.ruoyi.common.core.domain.entity.SysDictData;
import com.ruoyi.common.core.text.Convert; import com.ruoyi.common.core.text.Convert;
import com.ruoyi.common.enums.SysRoleEnum; import com.ruoyi.common.enums.SysRoleEnum;
import com.ruoyi.system.service.ISysDeptService; import com.ruoyi.system.service.ISysDeptService;
import com.ruoyi.system.service.ISysDictDataService;
import com.yanzhu.jh.trouble.domain.SmzSspAuditinfo; import com.yanzhu.jh.trouble.domain.SmzSspAuditinfo;
import com.yanzhu.jh.trouble.domain.vo.SmzSspProblemmodifyExport;
import com.yanzhu.jh.trouble.domain.where.SmzSspProblemmodifyWhere; import com.yanzhu.jh.trouble.domain.where.SmzSspProblemmodifyWhere;
import com.yanzhu.jh.trouble.service.ISmzSspAuditinfoService; import com.yanzhu.jh.trouble.service.ISmzSspAuditinfoService;
import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.security.access.prepost.PreAuthorize;
@ -47,6 +51,8 @@ public class SmzSspProblemmodifyController extends BaseController
@Autowired @Autowired
private ISmzSspProblemmodifyService smzSspProblemmodifyService; private ISmzSspProblemmodifyService smzSspProblemmodifyService;
/** /**
* *
*/ */
@ -98,9 +104,17 @@ public class SmzSspProblemmodifyController extends BaseController
smzSspProblemmodify.setNowDept(Convert.toStr(getDeptId())); smzSspProblemmodify.setNowDept(Convert.toStr(getDeptId()));
} }
smzSspProblemmodify.setNowUser(getLoginUser().getUsername()); smzSspProblemmodify.setNowUser(getLoginUser().getUsername());
List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSmzSspProblemmodifyList(smzSspProblemmodify); List<SmzSspProblemmodify> list = smzSspProblemmodifyService.selectSmzSspProblemmodifyListAndUnitName(smzSspProblemmodify);
ExcelUtil<SmzSspProblemmodify> util = new ExcelUtil<SmzSspProblemmodify>(SmzSspProblemmodify.class); List<SmzSspProblemmodifyExport> exportList=new ArrayList<>();
util.exportExcel(response, list, "质量整改数据"); for(SmzSspProblemmodify it :list){
exportList.add(SmzSspProblemmodifyExport.newItem(it));
}
ExcelUtil<SmzSspProblemmodifyExport> util = new ExcelUtil<SmzSspProblemmodifyExport>(SmzSspProblemmodifyExport.class);
String name="质量整改数据";
if(smzSspProblemmodify.getInfoType()==0){
name="安全整改数据";
}
util.exportExcel(response, exportList, name);
} }
/** /**

View File

@ -1,7 +1,10 @@
package com.yanzhu.jh.trouble.domain; package com.yanzhu.jh.trouble.domain;
import java.util.Date; import java.util.Date;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonFormat; import com.fasterxml.jackson.annotation.JsonFormat;
import com.yanzhu.jh.project.domain.SurProjectUnitInfo;
import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle; import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.annotation.Excel;
@ -21,15 +24,15 @@ public class SmzSspProblemmodify extends BaseEntity
private Long id; private Long id;
/** 项目id */ /** 项目id */
@Excel(name = "项目id")
private Long projectId; private Long projectId;
/** 信息类型 */ /** 信息类型 */
@Excel(name = "信息类型")
private Long infoType; private Long infoType;
/** 拍摄位置 */ /** 拍摄位置 */
@Excel(name = "拍摄位置") @Excel(name = "项目名称")
private String problemArea; private String problemArea;
/** 问题描述 */ /** 问题描述 */
@ -41,11 +44,11 @@ public class SmzSspProblemmodify extends BaseEntity
private String changeInfo; private String changeInfo;
/** 主送人姓名 */ /** 主送人姓名 */
@Excel(name = "主送人姓名") @Excel(name = "整改人")
private String lordSent; private String lordSent;
/** 主送人手机号 */ /** 主送人手机号 */
@Excel(name = "主送人手机号") @Excel(name = "整改人手机号")
private String lordSentUser; private String lordSentUser;
/** 抄送人姓名 */ /** 抄送人姓名 */
@ -135,6 +138,36 @@ public class SmzSspProblemmodify extends BaseEntity
private String vDel; private String vDel;
private String flag;//整改超时标识 private String flag;//整改超时标识
private String dangerLabel;
private String chkLabel;
public String getDangerLabel() {
return dangerLabel;
}
public void setDangerLabel(String dangerLabel) {
this.dangerLabel = dangerLabel;
}
public String getChkLabel() {
return chkLabel;
}
public void setChkLabel(String chkLabel) {
this.chkLabel = chkLabel;
}
//sur_project_unit_info
private List<SurProjectUnitInfo> unitInfos;
public List<SurProjectUnitInfo> getUnitInfos() {
return unitInfos;
}
public void setUnitInfos(List<SurProjectUnitInfo> unitInfos) {
this.unitInfos = unitInfos;
}
public void setId(Long id) public void setId(Long id)
{ {
this.id = id; this.id = id;

View File

@ -0,0 +1,165 @@
package com.yanzhu.jh.trouble.domain.vo;
import com.ruoyi.common.annotation.Excel;
import com.yanzhu.jh.trouble.domain.SmzSspProblemmodify;
import org.apache.poi.ss.usermodel.HorizontalAlignment;
import org.apache.poi.ss.usermodel.IndexedColors;
import java.util.Date;
public class SmzSspProblemmodifyExport {
@Excel(name = "项目名称",align= HorizontalAlignment.LEFT,width =30 )
private String problemArea;
@Excel(name = "总包单位",align= HorizontalAlignment.LEFT,width =30)
private String deptName;
@Excel(name = "隐患图片",isLink = true,color = IndexedColors.BLUE,linkText="查看图片")
private String marksPicture;
@Excel(name = "隐患类型" ,align= HorizontalAlignment.CENTER,width =24)
private String dangerType;
@Excel(name = "问题描述" ,align= HorizontalAlignment.LEFT,width =32)
private String workParts;
@Excel(name = "整改要求" ,align= HorizontalAlignment.LEFT,width =30)
private String changeInfo;
@Excel(name = "整改截至时间", width = 20, dateFormat = "yyyy-MM-dd HH:ss")
private Date nickedTime;
@Excel(name = "隐患整改人",align= HorizontalAlignment.LEFT,width =30)
private String lordSent;
@Excel(name = "流程状态")
private String checkState;
@Excel(name = "复检人",align= HorizontalAlignment.LEFT,width =30)
private String recheckSend;
@Excel(name = "抄送人",align= HorizontalAlignment.LEFT,width =30)
private String copySend;
@Excel(name = "提交用户",align= HorizontalAlignment.LEFT,width =30)
private String createBy;
@Excel(name = "提交时间", width = 20, dateFormat = "yyyy-MM-dd HH:ss")
private Date createTime;
public static SmzSspProblemmodifyExport newItem(SmzSspProblemmodify it) {
SmzSspProblemmodifyExport d=new SmzSspProblemmodifyExport();
d.problemArea=it.getProblemArea();
d.deptName=it.getDeptName();
d.dangerType=it.getDangerLabel();
d.workParts=it.getWorkParts();
d.changeInfo=it.getChangeInfo();
d.nickedTime=it.getNickedTime();
d.lordSent=it.getLordSent()+" "+it.getLordSentUser();
d.checkState=it.getChkLabel();
d.recheckSend=it.getRecheckSend()+" "+it.getRecheckSendUser();
d.copySend=it.getCopySend()+" "+it.getCopySendUser();
d.createBy=it.getCreateBy()+" "+it.getCreateUser();
d.createTime=it.getCreateTime();
d.marksPicture="http://62.234.3.186"+it.getMarksPicture();
return d;
}
public String getMarksPicture() {
return marksPicture;
}
public void setMarksPicture(String marksPicture) {
this.marksPicture = marksPicture;
}
public String getProblemArea() {
return problemArea;
}
public void setProblemArea(String problemArea) {
this.problemArea = problemArea;
}
public String getDeptName() {
return deptName;
}
public void setDeptName(String deptName) {
this.deptName = deptName;
}
public String getDangerType() {
return dangerType;
}
public void setDangerType(String dangerType) {
this.dangerType = dangerType;
}
public String getWorkParts() {
return workParts;
}
public void setWorkParts(String workParts) {
this.workParts = workParts;
}
public String getChangeInfo() {
return changeInfo;
}
public void setChangeInfo(String changeInfo) {
this.changeInfo = changeInfo;
}
public Date getNickedTime() {
return nickedTime;
}
public void setNickedTime(Date nickedTime) {
this.nickedTime = nickedTime;
}
public String getLordSent() {
return lordSent;
}
public void setLordSent(String lordSent) {
this.lordSent = lordSent;
}
public String getCheckState() {
return checkState;
}
public void setCheckState(String checkState) {
this.checkState = checkState;
}
public String getRecheckSend() {
return recheckSend;
}
public void setRecheckSend(String recheckSend) {
this.recheckSend = recheckSend;
}
public String getCopySend() {
return copySend;
}
public void setCopySend(String copySend) {
this.copySend = copySend;
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy;
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
}

View File

@ -3,6 +3,7 @@ package com.yanzhu.jh.trouble.domain.where;
import com.yanzhu.jh.trouble.domain.SmzSspProblemmodify; import com.yanzhu.jh.trouble.domain.SmzSspProblemmodify;
import java.util.Date; import java.util.Date;
import java.util.List;
public class SmzSspProblemmodifyWhere extends SmzSspProblemmodify { public class SmzSspProblemmodifyWhere extends SmzSspProblemmodify {
public Date getStartDate() { public Date getStartDate() {
@ -33,4 +34,16 @@ public class SmzSspProblemmodifyWhere extends SmzSspProblemmodify {
public void setDeptId(Long deptId) { public void setDeptId(Long deptId) {
this.deptId = deptId; this.deptId = deptId;
} }
public List<Long> getRoleTypes() {
return roleTypes;
}
public void setRoleTypes(List<Long> roleTypes) {
this.roleTypes = roleTypes;
}
private List<Long> roleTypes;
} }

View File

@ -38,6 +38,8 @@ public interface SmzSspProblemmodifyMapper
*/ */
public List<SmzSspProblemmodify> selectSmzSspProblemmodifyList(SmzSspProblemmodifyWhere smzSspProblemmodify); public List<SmzSspProblemmodify> selectSmzSspProblemmodifyList(SmzSspProblemmodifyWhere smzSspProblemmodify);
public List<SmzSspProblemmodify> selectSmzSspProblemmodifyListAndUnitName(SmzSspProblemmodifyWhere smzSspProblemmodify);
/** /**
* *
* *

View File

@ -127,4 +127,6 @@ public interface ISmzSspProblemmodifyService
public List<SmzSspProblemmodify> groupByInfotypeCheckState(SmzSspProblemmodifyWhere where); public List<SmzSspProblemmodify> groupByInfotypeCheckState(SmzSspProblemmodifyWhere where);
public Long countTimeout(SmzSspProblemmodifyWhere where); public Long countTimeout(SmzSspProblemmodifyWhere where);
public List<SmzSspProblemmodify> selectSmzSspProblemmodifyListAndUnitName(SmzSspProblemmodifyWhere where);
} }

View File

@ -231,6 +231,11 @@ public class SmzSspProblemmodifyServiceImpl implements ISmzSspProblemmodifyServi
return (long) smzSspProblemmodifyMapper.countTimeout(where); return (long) smzSspProblemmodifyMapper.countTimeout(where);
} }
@Override
public List<SmzSspProblemmodify> selectSmzSspProblemmodifyListAndUnitName(SmzSspProblemmodifyWhere where) {
return smzSspProblemmodifyMapper.selectSmzSspProblemmodifyListAndUnitName(where);
}
/** /**
* *
* *

View File

@ -58,6 +58,26 @@ public class WorkFile extends BaseEntity
private Long readNum; private Long readNum;
//文件列表 //文件列表
private Long deptId;
private String deptName;
public Long getDeptId() {
return deptId;
}
public void setDeptId(Long deptId) {
this.deptId = deptId;
}
public String getDeptName() {
return deptName;
}
public void setDeptName(String deptName) {
this.deptName = deptName;
}
private List<Map<String,Object>> fileList; private List<Map<String,Object>> fileList;
public void setId(Long id) public void setId(Long id)

View File

@ -80,6 +80,7 @@ public class WorkFileServiceImpl implements IWorkFileService
if(fileList!=null && fileList.size()>0){ if(fileList!=null && fileList.size()>0){
for(Map<String,Object> fileMap:fileList){ for(Map<String,Object> fileMap:fileList){
WorkFile lastingModel = new WorkFile(); WorkFile lastingModel = new WorkFile();
lastingModel.setDeptId(workFile.getDeptId());
lastingModel.setFileBelong(workFile.getFileBelong()); lastingModel.setFileBelong(workFile.getFileBelong());
lastingModel.setFileType(FileUtils.getFileLastNameUpCase(Convert.toStr(fileMap.get("original")))); lastingModel.setFileType(FileUtils.getFileLastNameUpCase(Convert.toStr(fileMap.get("original"))));
lastingModel.setFileName(Convert.toStr(fileMap.get("original"))); lastingModel.setFileName(Convert.toStr(fileMap.get("original")));

View File

@ -32,13 +32,18 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by" /> <result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="remark" column="remark" /> <result property="remark" column="remark" />
<result property="createByName" column="create_by_name"/>
<result property="updateByName" column="update_by_name"/>
</resultMap> </resultMap>
<sql id="selectSurProjectCheckDetectionVo"> <sql id="selectSurProjectCheckDetectionVo">
select spcd.id, spcd.project_id, sp.projectName, spcd.dept_id, sd.dept_name, spcd.check_type, sdd.dict_label as check_type_name, spcd.material_name, spcd.use_position, spcd.sample_num, spcd.qualified_flag, spcd.represen_num, spcd.sample_user, spcd.sample_user_name, spcd.witness_user, spcd.witness_user_name, spcd.laboratory_name, spcd.check_time, spcd.check_state, spcd.detection_result, spcd.detection_file, spcd.create_by, spcd.create_time, spcd.is_del, spcd.update_by, spcd.update_time, spcd.remark from sur_project_check_detection spcd SELECT spcd.id, spcd.project_id, sp.projectName, spcd.dept_id, sd.dept_name, spcd.check_type, sdd.dict_label AS check_type_name, spcd.material_name, spcd.use_position, spcd.sample_num, spcd.qualified_flag, spcd.represen_num, spcd.sample_user, spcd.sample_user_name, spcd.witness_user, spcd.witness_user_name, spcd.laboratory_name, spcd.check_time, spcd.check_state, spcd.detection_result, spcd.detection_file, spcd.create_by, spcd.create_time, spcd.is_del, spcd.update_by, spcd.update_time, spcd.remark ,u1.nick_name create_by_name,u2.nick_name update_by_name
left join sur_project sp on spcd.project_id = sp.id FROM sur_project_check_detection spcd
left join sys_dept sd on sd.dept_id = spcd.dept_id LEFT JOIN sur_project sp ON spcd.project_id = sp.id
left join sys_dict_data sdd on sdd.dict_type = 'check_detection_check_type' and sdd.dict_value = spcd.check_type LEFT JOIN sys_dept sd ON sd.dept_id = spcd.dept_id
LEFT JOIN sys_dict_data sdd ON sdd.dict_type = 'check_detection_check_type' AND sdd.dict_value = spcd.check_type
LEFT JOIN sys_user u1 ON spcd.create_by=u1.phonenumber
LEFT JOIN sys_user u2 ON spcd.update_by=u2.phonenumber
</sql> </sql>
<select id="selectSurProjectCheckDetectionList" parameterType="SurProjectCheckDetection" resultMap="SurProjectCheckDetectionResult"> <select id="selectSurProjectCheckDetectionList" parameterType="SurProjectCheckDetection" resultMap="SurProjectCheckDetectionResult">
@ -264,4 +269,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</if> </if>
</select> </select>
<select id="getList" parameterType="SurProjectCheckDetection" resultMap="SurProjectCheckDetectionResult">
<include refid="selectSurProjectCheckDetectionVo"/>
WHERE spcd.is_del=0
<if test="checkType!=null and checkType>0">AND spcd.check_type= #{checkType}</if>
<if test="deptId !=null and deptId > 0 ">
and spcd.project_id IN (SELECT id FROM sur_project WHERE deptid=#{deptId})
</if>
<if test="projectId !=null and projectId > 0 ">
and spcd.project_id=#{projectId}
</if>
</select>
</mapper> </mapper>

View File

@ -31,6 +31,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="remark" column="remark" /> <result property="remark" column="remark" />
<result property="measureTypeName" column="measure_type_name" /> <result property="measureTypeName" column="measure_type_name" />
<result property="measureInfoName" column="measure_info_name" /> <result property="measureInfoName" column="measure_info_name" />
<result property="createByName" column="create_by_name"/>
<result property="updateByName" column="update_by_name"/>
</resultMap> </resultMap>
<sql id="selectSurProjectMeasureVo"> <sql id="selectSurProjectMeasureVo">
@ -196,4 +198,25 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
) b ) b
ON a.dict_value=b.measure_info ON a.dict_value=b.measure_info
</select> </select>
<select id="getList" parameterType="SurProjectMeasure" resultMap="SurProjectMeasureResult">
SELECT spm.id, spm.project_id, spm.dept_id, spm.main_image, spm.image_urls, spm.measure_type, sdd1.dict_label AS measure_type_name, spm.measure_position, spm.measure_info, sdd2.dict_label AS measure_info_name, spm.measure_time, spm.measure_point_position, spm.measure_result, spm.measure_files, spm.quality_user, spm.quality_user_name, spm.supervise_user, spm.supervise_user_name, spm.is_del, spm.create_by, spm.create_time, spm.update_by, spm.update_time, spm.remark, sp.projectName, sd.dept_name ,u1.nick_name create_by_name,u2.nick_name update_by_name
FROM sur_project_measure spm
LEFT JOIN sur_project sp ON spm.project_id = sp.id
LEFT JOIN sys_dept sd ON sd.dept_id = spm.dept_id
LEFT JOIN sys_dict_data sdd1 ON sdd1.dict_type = 'project_measure_type' AND sdd1.dict_value = spm.measure_type
LEFT JOIN sys_dict_data sdd2 ON sdd2.dict_type = 'project_measure_info_type' AND sdd2.dict_value = spm.measure_info
LEFT JOIN sys_user u1 ON spm.create_by=u1.phonenumber
LEFT JOIN sys_user u2 ON spm.update_by=u2.phonenumber
WHERE IF(spm.is_del IS NULL,0,spm.is_del)=0
<if test='measureType !=null and measureType !="0"'>
and spm.measure_type = #{measureType}
</if>
<if test="deptId !=null and deptId >0">
AND spm.project_id IN (SELECT id FROM sur_project WHERE deptid=#{deptId})
</if>
<if test="projectId !=null and projectId >0">
AND spm.project_id=#{projectId}
</if>
</select>
</mapper> </mapper>

View File

@ -43,6 +43,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="deptName" column="deptName"/> <result property="deptName" column="deptName"/>
<result property="createUserName" column="createUserName"/> <result property="createUserName" column="createUserName"/>
<result property="flag" column="flag"/> <result property="flag" column="flag"/>
<result property="chkLabel" column="chkLabel"></result>
<result property="dangerLabel" column="dangerLabel"></result>
<collection property="unitInfos" ofType="SurProjectUnitInfo">
<id column="unitId" property="id"></id>
<result property="unitName" column="unitName"></result>
</collection>
</resultMap> </resultMap>
<sql id="selectSmzSspProblemmodifyVo"> <sql id="selectSmzSspProblemmodifyVo">
@ -98,6 +104,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test='activeName == "dqr"'> and ssp.checkState in (1)</if> <if test='activeName == "dqr"'> and ssp.checkState in (1)</if>
<if test='activeName == "ycl"'> and ssp.checkState = 4 </if> <if test='activeName == "ycl"'> and ssp.checkState = 4 </if>
<if test='activeName == "zgcs"'> and (date(NOW())<![CDATA[ > ]]> date(ssp.nickedTime) and (ssp.updateTime is null or date(ssp.updateTime) <![CDATA[ > ]]> date(ssp.nickedTime))) </if> <if test='activeName == "zgcs"'> and (date(NOW())<![CDATA[ > ]]> date(ssp.nickedTime) and (ssp.updateTime is null or date(ssp.updateTime) <![CDATA[ > ]]> date(ssp.nickedTime))) </if>
<if test="roleTypes!=null">
and roleType in
<foreach collection="roleTypes" item="item" index="index" open="(" close=")" separator=",">${item}</foreach>
</if>
</where> </where>
order by createTime desc order by createTime desc
</select> </select>
@ -212,6 +222,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test='nowRole == "5" or nowRole == "6" or nowRole == "7"'> and spui.unitId = #{nowDept}</if> <if test='nowRole == "5" or nowRole == "6" or nowRole == "7"'> and spui.unitId = #{nowDept}</if>
<!--普通整改人是我,复检人是我,抄送人是我,提交人是我的数据--> <!--普通整改人是我,复检人是我,抄送人是我,提交人是我的数据-->
<if test='nowRole == "15" or nowRole == "16" or nowRole == "17" or nowRole == "99"'> and (ssp.lordSentUser = #{nowUser} or ssp.copySendUser like concat('%', #{nowUser}, '%') or ssp.recheckSendUser = #{nowUser} or ssp.createUser = #{nowUser} )</if> <if test='nowRole == "15" or nowRole == "16" or nowRole == "17" or nowRole == "99"'> and (ssp.lordSentUser = #{nowUser} or ssp.copySendUser like concat('%', #{nowUser}, '%') or ssp.recheckSendUser = #{nowUser} or ssp.createUser = #{nowUser} )</if>
<if test="roleTypes!=null">
and roleType in
<foreach collection="roleTypes" item="item" index="index" open="(" close=")" separator=",">${item}</foreach>
</if>
GROUP BY checkState GROUP BY checkState
</select> </select>
@ -238,6 +252,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test='nowRole == "5" or nowRole == "6" or nowRole == "7"'> and spui.unitId = #{nowDept}</if> <if test='nowRole == "5" or nowRole == "6" or nowRole == "7"'> and spui.unitId = #{nowDept}</if>
<!--普通整改人是我,复检人是我,抄送人是我,提交人是我的数据--> <!--普通整改人是我,复检人是我,抄送人是我,提交人是我的数据-->
<if test='nowRole == "15" or nowRole == "16" or nowRole == "17" or nowRole == "99"'> and (ssp.lordSentUser = #{nowUser} or ssp.copySendUser like concat('%', #{nowUser}, '%') or ssp.recheckSendUser = #{nowUser} or ssp.createUser = #{nowUser} )</if> <if test='nowRole == "15" or nowRole == "16" or nowRole == "17" or nowRole == "99"'> and (ssp.lordSentUser = #{nowUser} or ssp.copySendUser like concat('%', #{nowUser}, '%') or ssp.recheckSendUser = #{nowUser} or ssp.createUser = #{nowUser} )</if>
<if test="roleTypes!=null">
and roleType in
<foreach collection="roleTypes" item="item" index="index" open="(" close=")" separator=",">${item}</foreach>
</if>
</select> </select>
<select id="selectSmzSspProblemmodifyById" parameterType="Long" resultMap="SmzSspProblemmodifyResult"> <select id="selectSmzSspProblemmodifyById" parameterType="Long" resultMap="SmzSspProblemmodifyResult">
@ -533,4 +552,71 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</if> </if>
</select> </select>
<select id="selectSmzSspProblemmodifyListAndUnitName" parameterType="SmzSspProblemmodifyWhere" resultMap="SmzSspProblemmodifyResult">
select ssp.id, ssp.projectId, ssp.infoType, ssp.problemArea, ssp.workParts, ssp.changeInfo, ssp.lordSent, ssp.lordSentUser, ssp.copySend, ssp.copySendUser, ssp.checkState, ssp.nickedArea, ssp.nickedTime, ssp.projectType, ssp.processName, ssp.projectName, ssp.nickedInfo, ssp.checkUser, ssp.checkUserPhone, ssp.isDel, ssp.createUser, ssp.createTime, ssp.updateUser, ssp.updateTime, ssp.marks_picture, ssp.marks_video, ssp.smark_url, ssp.danger_type,
ssp.recheckSend, ssp.recheckSendUser, ssp.roleType, ssp.createBy
,sp.dept_Name deptName,ssp.dangerLabel,ssp.chkLabel
from (
SELECT c.*,a.dict_label dangerLabel,b.dict_label chkLabel FROM
vw_smz_ssp_problemmodify_audit c,sys_dict_data a,sys_dict_data b WHERE c.danger_Type=a.dict_value AND a.dict_type='ssp_aqyhlx'
AND c.checkState=b.dict_value AND b.dict_type='smz_ssp_checkstate'
) ssp
left join (
SELECT p.dept_Name,p.dept_id,u.phonenumber
FROM sys_user u,sur_project_userinfo p WHERE u.user_id=p.user_id AND p.dept_type=2
) sp on ssp.lordSentUser = sp.phonenumber
<!--监理单位/总包公司/分包单位-->
<if test='nowRole == "5" or nowRole == "6" or nowRole == "7"'> left join sur_project_unit_info spui on spui.projectId = sp.id</if>
<where>
and ssp.isDel=0
<if test="projectId != null "> and ssp.projectId = #{projectId}</if>
<if test="infoType != null "> and ssp.infoType = #{infoType}</if>
<if test="roleType != null and roleType >0 "> and ssp.roleType = #{roleType}</if>
<if test="problemArea != null and problemArea != ''"> and ssp.problemArea like concat('%', #{problemArea}, '%')</if>
<if test="workParts != null and workParts != ''"> and ssp.workParts like concat('%', #{workParts}, '%')</if>
<if test="changeInfo != null and changeInfo != ''"> and ssp.changeInfo like concat('%', #{changeInfo}, '%')</if>
<if test="lordSent != null and lordSent != ''"> and ssp.lordSent = #{lordSent}</if>
<if test="lordSentUser != null and lordSentUser != ''"> and ssp.lordSentUser = #{lordSentUser}</if>
<if test="copySend != null and copySend != ''"> and ssp.copySend = #{copySend}</if>
<if test="copySendUser != null and copySendUser != ''"> and ssp.copySendUser = #{copySendUser}</if>
<if test="checkState != null "> and ssp.checkState = #{checkState}</if>
<if test="nickedArea != null and nickedArea != ''"> and nickedArea = #{nickedArea}</if>
<if test="nickedTime != null "> and ssp.nickedTime = #{nickedTime}</if>
<if test="problemType != null "> and ssp.problemType = #{problemType}</if>
<if test="projectType != null and projectType != ''"> and ssp.projectType = #{projectType}</if>
<if test="processName != null and processName != ''"> and ssp.processName like concat('%', #{processName}, '%')</if>
<if test="projectName != null and projectName != ''"> and ssp.projectName like concat('%', #{projectName}, '%')</if>
<if test="nickedInfo != null and nickedInfo != ''"> and ssp.nickedInfo = #{nickedInfo}</if>
<if test="checkUser != null and checkUser != ''"> and ssp.checkUser = #{checkUser}</if>
<if test="checkUserPhone != null and checkUserPhone != ''"> and ssp.checkUserPhone = #{checkUserPhone}</if>
<if test="isDel != null "> and ssp.isDel = #{isDel}</if>
<if test="startDate!=null">and DATE(ssp.createtime)>=DATE(#{startDate})</if>
<if test="endDate!=null">and DATE(ssp.createtime) &lt;= DATE(#{endDate})</if>
<if test="createUser != null and createUser != ''"> and ssp.createUser like concat('%', #{createUser}, '%')</if>
<if test="createTime != null "> and ssp.createTime = #{createTime}</if>
<if test="updateUser != null and updateUser != ''"> and ssp.updateUser = #{updateUser}</if>
<if test="updateTime != null "> and ssp.updateTime = #{updateTime}</if>
<if test="dangerType != null and dangerType != ''"> and ssp.danger_type = #{dangerType}</if>
<if test="params.beginMarksTime != null and params.beginMarksTime != '' and params.endMarksTime != null and params.endMarksTime != ''"> and ssp.createTime between #{params.beginMarksTime} and #{params.endMarksTime}</if>
<!-- 查询条件-项目部门 -->
<if test="projectDeptId != null "> and sp.deptId = #{projectDeptId}</if>
<!--子部门数据-->
<if test='nowRole == "4"'> and sp.deptId = #{nowDept}</if>
<!--监理单位/总包公司/分包单位查询当前关联数据-->
<if test='nowRole == "5" or nowRole == "6" or nowRole == "7"'> and spui.unitId = #{nowDept}</if>
<!--普通整改人是我,复检人是我,抄送人是我,提交人是我的数据-->
<if test='nowRole == "15" or nowRole == "16" or nowRole == "17" or nowRole == "99"'> and (ssp.lordSentUser = #{nowUser} or ssp.copySendUser like concat('%', #{nowUser}, '%') or ssp.recheckSendUser = #{nowUser} or ssp.createUser = #{nowUser} )</if>
<if test='activeName == "dzg"'> and ssp.checkState in (0,3)</if>
<if test='activeName == "dqr"'> and ssp.checkState in (1)</if>
<if test='activeName == "ycl"'> and ssp.checkState = 4 </if>
<if test='activeName == "zgcs"'> and (date(NOW())<![CDATA[ > ]]> date(ssp.nickedTime) and (ssp.updateTime is null or date(ssp.updateTime) <![CDATA[ > ]]> date(ssp.nickedTime))) </if>
<if test="roleTypes!=null">
and roleType in
<foreach collection="roleTypes" item="item" index="index" open="(" close=")" separator=",">${item}</foreach>
</if>
</where>
order by createTime desc
</select>
</mapper> </mapper>

View File

@ -20,10 +20,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="updateBy" column="update_by" /> <result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="remark" column="remark" /> <result property="remark" column="remark" />
<result property="deptId" column="dept_id"/>
<result property="deptName" column="dept_name"/>
</resultMap> </resultMap>
<sql id="selectWorkFileVo"> <sql id="selectWorkFileVo">
select id, file_belong, file_type, file_name, file_path, file_md5, file_size, is_del, download_num, read_num, create_by, create_time, update_by, update_time, remark from work_file select id, file_belong, file_type, file_name, file_path, file_md5, file_size, is_del, download_num, read_num, create_by, create_time, update_by, update_time, remark,dept_id,dept_name
from ( SELECT a.*,b.dept_name
FROM work_file a LEFT JOIN sys_dept b ON a.dept_id=b.dept_id ) work_file
</sql> </sql>
<select id="selectWorkFileList" parameterType="WorkFile" resultMap="WorkFileResult"> <select id="selectWorkFileList" parameterType="WorkFile" resultMap="WorkFileResult">
@ -31,6 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<where> <where>
<if test="isDel != null "> and is_del = #{isDel}</if> <if test="isDel != null "> and is_del = #{isDel}</if>
<if test="fileBelong != null and fileBelong != ''"> and file_belong = #{fileBelong}</if> <if test="fileBelong != null and fileBelong != ''"> and file_belong = #{fileBelong}</if>
<if test="deptId != null and deptId>0"> and dept_id = #{deptId}</if>
<if test="fileName != null and fileName != ''"> and file_name like concat('%', #{fileName}, '%')</if> <if test="fileName != null and fileName != ''"> and file_name like concat('%', #{fileName}, '%')</if>
<if test="params.beginMarksTime != null and params.beginMarksTime != '' and params.endMarksTime != null and params.endMarksTime != ''"> and create_time between #{params.beginMarksTime} and #{params.endMarksTime}</if> <if test="params.beginMarksTime != null and params.beginMarksTime != '' and params.endMarksTime != null and params.endMarksTime != ''"> and create_time between #{params.beginMarksTime} and #{params.endMarksTime}</if>
</where> </where>
@ -42,6 +47,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<where> <where>
and is_del = 0 and is_del = 0
<if test="fileBelong != null and fileBelong != ''"> and file_belong = #{fileBelong}</if> <if test="fileBelong != null and fileBelong != ''"> and file_belong = #{fileBelong}</if>
<if test="deptId!=null and deptId>0">and dept_id =#{deptId}</if>
</where> </where>
order by create_time desc order by create_time desc
Limit 20 Limit 20
@ -69,6 +75,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="updateBy != null">update_by,</if> <if test="updateBy != null">update_by,</if>
<if test="updateTime != null">update_time,</if> <if test="updateTime != null">update_time,</if>
<if test="remark != null">remark,</if> <if test="remark != null">remark,</if>
<if test="deptId != null">dept_id,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="fileBelong != null">#{fileBelong},</if> <if test="fileBelong != null">#{fileBelong},</if>
@ -85,6 +92,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="updateBy != null">#{updateBy},</if> <if test="updateBy != null">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if> <if test="updateTime != null">#{updateTime},</if>
<if test="remark != null">#{remark},</if> <if test="remark != null">#{remark},</if>
<if test="deptId != null">#{deptId},</if>
</trim> </trim>
</insert> </insert>
@ -105,6 +113,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="updateBy != null">update_by = #{updateBy},</if> <if test="updateBy != null">update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if> <if test="updateTime != null">update_time = #{updateTime},</if>
<if test="remark != null">remark = #{remark},</if> <if test="remark != null">remark = #{remark},</if>
<if test="deptId != null">dept_id = #{deptId},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>