From acb0d0899927ba04302687389895e81ef8f34f0b Mon Sep 17 00:00:00 2001 From: yinq <1345442242@qq.com> Date: Thu, 9 Nov 2023 17:00:08 +0800 Subject: [PATCH] =?UTF-8?q?add=20-=20=E5=A4=9A=E6=95=B0=E6=8D=AE=E6=BA=90?= =?UTF-8?q?=E3=80=81=E7=94=B5=E6=A3=80=E6=95=B0=E6=8D=AE=E8=AE=B0=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/application-dev.yml | 8 +- .../src/main/resources/application-local.yml | 8 +- .../src/main/resources/application-prod.yml | 16 +- .../RecordElectricalInspectionController.java | 99 +++++++++++++ .../domain/DetailElectricalinspection.java | 131 ++++++++++++++++ .../domain/RecordElectricalInspection.java | 131 ++++++++++++++++ .../RecordElectricalInspectionMapper.java | 91 ++++++++++++ .../IRecordElectricalInspectionService.java | 61 ++++++++ ...RecordElectricalInspectionServiceImpl.java | 131 ++++++++++++++++ .../RecordElectricalInspectionMapper.xml | 140 ++++++++++++++++++ 10 files changed, 800 insertions(+), 16 deletions(-) create mode 100644 aucma-report/src/main/java/com/aucma/report/controller/RecordElectricalInspectionController.java create mode 100644 aucma-report/src/main/java/com/aucma/report/domain/DetailElectricalinspection.java create mode 100644 aucma-report/src/main/java/com/aucma/report/domain/RecordElectricalInspection.java create mode 100644 aucma-report/src/main/java/com/aucma/report/mapper/RecordElectricalInspectionMapper.java create mode 100644 aucma-report/src/main/java/com/aucma/report/service/IRecordElectricalInspectionService.java create mode 100644 aucma-report/src/main/java/com/aucma/report/service/impl/RecordElectricalInspectionServiceImpl.java create mode 100644 aucma-report/src/main/resources/mapper/report/RecordElectricalInspectionMapper.xml diff --git a/aucma-admin/src/main/resources/application-dev.yml b/aucma-admin/src/main/resources/application-dev.yml index 3dd3296..f5fadb9 100644 --- a/aucma-admin/src/main/resources/application-dev.yml +++ b/aucma-admin/src/main/resources/application-dev.yml @@ -72,10 +72,10 @@ spring: # 从库数据源 slave: # 从数据源开关/默认关闭 - enabled: false - url: - username: - password: + enabled: true + url: jdbc:oracle:thin:@175.27.215.92:1521/helowin + username: aucma_scada + password: aucma # 初始连接数 initialSize: 5 # 最小连接池数量 diff --git a/aucma-admin/src/main/resources/application-local.yml b/aucma-admin/src/main/resources/application-local.yml index bb57be4..80ffc97 100644 --- a/aucma-admin/src/main/resources/application-local.yml +++ b/aucma-admin/src/main/resources/application-local.yml @@ -73,10 +73,10 @@ spring: # 从库数据源 slave: # 从数据源开关/默认关闭 - enabled: false - url: - username: - password: + enabled: true + url: jdbc:oracle:thin:@175.27.215.92:1521/helowin + username: aucma_scada + password: aucma # 初始连接数 initialSize: 5 # 最小连接池数量 diff --git a/aucma-admin/src/main/resources/application-prod.yml b/aucma-admin/src/main/resources/application-prod.yml index 990dfec..cddfdb6 100644 --- a/aucma-admin/src/main/resources/application-prod.yml +++ b/aucma-admin/src/main/resources/application-prod.yml @@ -40,11 +40,11 @@ spring: # redis 配置 redis: # 地址 - host: 175.27.215.92 + host: localhost # 端口,默认为6379 port: 6379 # 数据库索引 - database: 5 + database: 1 # 密码 password: redis@2023 # 连接超时时间 @@ -65,16 +65,16 @@ spring: druid: # 主库数据源 master: - url: jdbc:oracle:thin:@175.27.215.92:1521/helowin - username: aucma_mes + url: jdbc:oracle:thin:@10.100.72.20:1521/ORCLCDB + username: c##aucma_mes password: aucma # 从库数据源 slave: # 从数据源开关/默认关闭 - enabled: false - url: - username: - password: + enabled: true + url: jdbc:oracle:thin:@10.100.72.20:1521/ORCLCDB + username: c##aucma_scada + password: aucma # 初始连接数 initialSize: 5 # 最小连接池数量 diff --git a/aucma-report/src/main/java/com/aucma/report/controller/RecordElectricalInspectionController.java b/aucma-report/src/main/java/com/aucma/report/controller/RecordElectricalInspectionController.java new file mode 100644 index 0000000..b46d58b --- /dev/null +++ b/aucma-report/src/main/java/com/aucma/report/controller/RecordElectricalInspectionController.java @@ -0,0 +1,99 @@ +package com.aucma.report.controller; + +import java.util.List; +import javax.servlet.http.HttpServletResponse; + +import com.aucma.common.utils.DateUtils; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.aucma.common.annotation.Log; +import com.aucma.common.core.controller.BaseController; +import com.aucma.common.core.domain.AjaxResult; +import com.aucma.common.enums.BusinessType; +import com.aucma.report.domain.RecordElectricalInspection; +import com.aucma.report.service.IRecordElectricalInspectionService; +import com.aucma.common.utils.poi.ExcelUtil; +import com.aucma.common.core.page.TableDataInfo; + +/** + * 电检数据记录Controller + * + * @author Yinq + * @date 2023-11-09 + */ +@RestController +@RequestMapping("/report/electricalInspection" ) +public class RecordElectricalInspectionController extends BaseController { + @Autowired + private IRecordElectricalInspectionService recordElectricalInspectionService; + + /** + * 查询电检数据记录列表 + */ + @PreAuthorize("@ss.hasPermi('report:electricalInspection:list')" ) + @GetMapping("/list" ) + public TableDataInfo list(RecordElectricalInspection recordElectricalInspection) { + startPage(); + List list = recordElectricalInspectionService.selectRecordElectricalInspectionList(recordElectricalInspection); + return getDataTable(list); + } + + /** + * 导出电检数据记录列表 + */ + @PreAuthorize("@ss.hasPermi('report:electricalInspection:export')" ) + @Log(title = "电检数据记录" , businessType = BusinessType.EXPORT) + @PostMapping("/export" ) + public void export(HttpServletResponse response, RecordElectricalInspection recordElectricalInspection) { + List list = recordElectricalInspectionService.selectRecordElectricalInspectionList(recordElectricalInspection); + ExcelUtil util = new ExcelUtil(RecordElectricalInspection. class); + util.exportExcel(response, list, "电检数据记录数据" ); + } + + /** + * 获取电检数据记录详细信息 + */ + @PreAuthorize("@ss.hasPermi('report:electricalInspection:query')" ) + @GetMapping(value = "/{uuid}" ) + public AjaxResult getInfo(@PathVariable("uuid" ) String uuid) { + return success(recordElectricalInspectionService.selectRecordElectricalInspectionByUuid(uuid)); + } + + /** + * 新增电检数据记录 + */ + @PreAuthorize("@ss.hasPermi('report:electricalInspection:add')" ) + @Log(title = "电检数据记录" , businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody RecordElectricalInspection recordElectricalInspection) { + return toAjax(recordElectricalInspectionService.insertRecordElectricalInspection(recordElectricalInspection)); + } + + /** + * 修改电检数据记录 + */ + @PreAuthorize("@ss.hasPermi('report:electricalInspection:edit')" ) + @Log(title = "电检数据记录" , businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody RecordElectricalInspection recordElectricalInspection) { + return toAjax(recordElectricalInspectionService.updateRecordElectricalInspection(recordElectricalInspection)); + } + + /** + * 删除电检数据记录 + */ + @PreAuthorize("@ss.hasPermi('report:electricalInspection:remove')" ) + @Log(title = "电检数据记录" , businessType = BusinessType.DELETE) + @DeleteMapping("/{uuids}" ) + public AjaxResult remove(@PathVariable String[] uuids) { + return toAjax(recordElectricalInspectionService.deleteRecordElectricalInspectionByUuids(uuids)); + } +} diff --git a/aucma-report/src/main/java/com/aucma/report/domain/DetailElectricalinspection.java b/aucma-report/src/main/java/com/aucma/report/domain/DetailElectricalinspection.java new file mode 100644 index 0000000..25dbcc0 --- /dev/null +++ b/aucma-report/src/main/java/com/aucma/report/domain/DetailElectricalinspection.java @@ -0,0 +1,131 @@ +package com.aucma.report.domain; + +import java.util.Date; + +import com.aucma.common.annotation.Excel; +import com.fasterxml.jackson.annotation.JsonFormat; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.aucma.common.core.domain.BaseEntity; + +/** + * 电检数据明细对象 detail_electricalinspection + * + * @author Yinq + * @date 2023-11-09 + */ +public class DetailElectricalinspection extends BaseEntity { + private static final long serialVersionUID = 1L; + + /** + * 标识 + */ + @Excel(name = "标识") + private String uuid; + + /** + * 序号 + */ + @Excel(name = "序号") + private Long serialnumber; + + /** + * 项目名称 + */ + @Excel(name = "项目名称") + private String projectname; + + /** + * 测试条件 + */ + @Excel(name = "测试条件") + private String testcondition; + + /** + * 测试值 + */ + @Excel(name = "测试值") + private String testvalue; + + /** + * 测试结果 + */ + @Excel(name = "测试结果") + private String testresult; + + /** + * 记录时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @Excel(name = "记录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") + private Date recordtime; + + public void setUuid(String uuid) { + this.uuid = uuid; + } + + public String getUuid() { + return uuid; + } + + public void setSerialnumber(Long serialnumber) { + this.serialnumber = serialnumber; + } + + public Long getSerialnumber() { + return serialnumber; + } + + public void setProjectname(String projectname) { + this.projectname = projectname; + } + + public String getProjectname() { + return projectname; + } + + public void setTestcondition(String testcondition) { + this.testcondition = testcondition; + } + + public String getTestcondition() { + return testcondition; + } + + public void setTestvalue(String testvalue) { + this.testvalue = testvalue; + } + + public String getTestvalue() { + return testvalue; + } + + public void setTestresult(String testresult) { + this.testresult = testresult; + } + + public String getTestresult() { + return testresult; + } + + public void setRecordtime(Date recordtime) { + this.recordtime = recordtime; + } + + public Date getRecordtime() { + return recordtime; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("uuid", getUuid()) + .append("serialnumber", getSerialnumber()) + .append("projectname", getProjectname()) + .append("testcondition", getTestcondition()) + .append("testvalue", getTestvalue()) + .append("testresult", getTestresult()) + .append("recordtime", getRecordtime()) + .toString(); + } +} diff --git a/aucma-report/src/main/java/com/aucma/report/domain/RecordElectricalInspection.java b/aucma-report/src/main/java/com/aucma/report/domain/RecordElectricalInspection.java new file mode 100644 index 0000000..88a4e65 --- /dev/null +++ b/aucma-report/src/main/java/com/aucma/report/domain/RecordElectricalInspection.java @@ -0,0 +1,131 @@ +package com.aucma.report.domain; + +import java.util.List; +import java.util.Date; + +import com.fasterxml.jackson.annotation.JsonFormat; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.aucma.common.annotation.Excel; +import com.aucma.common.core.domain.BaseEntity; + +/** + * 电检数据记录对象 record_electricalinspection + * + * @author Yinq + * @date 2023-11-09 + */ +public class RecordElectricalInspection extends BaseEntity { + private static final long serialVersionUID = 1L; + + /** + * 唯一标识 + */ + @Excel(name = "唯一标识") + private String uuid; + + /** + * 测试总结果 + */ + @Excel(name = "测试总结果") + private String result; + + /** + * 产品条码 + */ + @Excel(name = "产品条码") + private String barcode; + + /** + * 测试时间 + */ + @Excel(name = "测试时间") + private String testTime; + + /** + * 测试数据 + */ + @Excel(name = "测试数据") + private String testData; + + /** + * 记录时间 + */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @Excel(name = "记录时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") + private Date recordTime; + + /** + * 电检数据明细信息 + */ + private List detailElectricalinspectionList; + + public void setUuid(String uuid) { + this.uuid = uuid; + } + + public String getUuid() { + return uuid; + } + + public void setResult(String result) { + this.result = result; + } + + public String getResult() { + return result; + } + + public void setBarcode(String barcode) { + this.barcode = barcode; + } + + public String getBarcode() { + return barcode; + } + + public void setTestTime(String testTime) { + this.testTime = testTime; + } + + public String getTestTime() { + return testTime; + } + + public void setTestData(String testData) { + this.testData = testData; + } + + public String getTestData() { + return testData; + } + + public void setRecordTime(Date recordTime) { + this.recordTime = recordTime; + } + + public Date getRecordTime() { + return recordTime; + } + + public List getDetailElectricalinspectionList() { + return detailElectricalinspectionList; + } + + public void setDetailElectricalinspectionList(List detailElectricalinspectionList) { + this.detailElectricalinspectionList = detailElectricalinspectionList; + } + + @Override + public String toString() { + return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) + .append("uuid", getUuid()) + .append("result", getResult()) + .append("barcode", getBarcode()) + .append("testTime", getTestTime()) + .append("testData", getTestData()) + .append("recordTime", getRecordTime()) + .append("detailElectricalinspectionList", getDetailElectricalinspectionList()) + .toString(); + } +} diff --git a/aucma-report/src/main/java/com/aucma/report/mapper/RecordElectricalInspectionMapper.java b/aucma-report/src/main/java/com/aucma/report/mapper/RecordElectricalInspectionMapper.java new file mode 100644 index 0000000..e703cbe --- /dev/null +++ b/aucma-report/src/main/java/com/aucma/report/mapper/RecordElectricalInspectionMapper.java @@ -0,0 +1,91 @@ +package com.aucma.report.mapper; + +import java.util.List; + +import com.aucma.common.annotation.DataSource; +import com.aucma.common.enums.DataSourceType; +import com.aucma.report.domain.RecordElectricalInspection; +import com.aucma.report.domain.DetailElectricalinspection; + +/** + * 电检数据记录Mapper接口 + * + * @author Yinq + * @date 2023-11-09 + */ +@DataSource(value = DataSourceType.SLAVE) +public interface RecordElectricalInspectionMapper +{ + /** + * 查询电检数据记录 + * + * @param uuid 电检数据记录主键 + * @return 电检数据记录 + */ + public RecordElectricalInspection selectRecordElectricalInspectionByUuid(String uuid); + + /** + * 查询电检数据记录列表 + * + * @param recordElectricalInspection 电检数据记录 + * @return 电检数据记录集合 + */ + public List selectRecordElectricalInspectionList(RecordElectricalInspection recordElectricalInspection); + + /** + * 新增电检数据记录 + * + * @param recordElectricalInspection 电检数据记录 + * @return 结果 + */ + public int insertRecordElectricalInspection(RecordElectricalInspection recordElectricalInspection); + + /** + * 修改电检数据记录 + * + * @param recordElectricalInspection 电检数据记录 + * @return 结果 + */ + public int updateRecordElectricalInspection(RecordElectricalInspection recordElectricalInspection); + + /** + * 删除电检数据记录 + * + * @param uuid 电检数据记录主键 + * @return 结果 + */ + public int deleteRecordElectricalInspectionByUuid(String uuid); + + /** + * 批量删除电检数据记录 + * + * @param uuids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteRecordElectricalInspectionByUuids(String[] uuids); + + /** + * 批量删除电检数据明细 + * + * @param uuids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteDetailElectricalinspectionByUuids(String[] uuids); + + /** + * 批量新增电检数据明细 + * + * @param detailElectricalinspectionList 电检数据明细列表 + * @return 结果 + */ + public int batchDetailElectricalinspection(List detailElectricalinspectionList); + + + /** + * 通过电检数据记录主键删除电检数据明细信息 + * + * @param uuid 电检数据记录ID + * @return 结果 + */ + public int deleteDetailElectricalinspectionByUuid(String uuid); +} diff --git a/aucma-report/src/main/java/com/aucma/report/service/IRecordElectricalInspectionService.java b/aucma-report/src/main/java/com/aucma/report/service/IRecordElectricalInspectionService.java new file mode 100644 index 0000000..ce080cf --- /dev/null +++ b/aucma-report/src/main/java/com/aucma/report/service/IRecordElectricalInspectionService.java @@ -0,0 +1,61 @@ +package com.aucma.report.service; + +import java.util.List; +import com.aucma.report.domain.RecordElectricalInspection; + +/** + * 电检数据记录Service接口 + * + * @author Yinq + * @date 2023-11-09 + */ +public interface IRecordElectricalInspectionService +{ + /** + * 查询电检数据记录 + * + * @param uuid 电检数据记录主键 + * @return 电检数据记录 + */ + public RecordElectricalInspection selectRecordElectricalInspectionByUuid(String uuid); + + /** + * 查询电检数据记录列表 + * + * @param recordElectricalInspection 电检数据记录 + * @return 电检数据记录集合 + */ + public List selectRecordElectricalInspectionList(RecordElectricalInspection recordElectricalInspection); + + /** + * 新增电检数据记录 + * + * @param recordElectricalInspection 电检数据记录 + * @return 结果 + */ + public int insertRecordElectricalInspection(RecordElectricalInspection recordElectricalInspection); + + /** + * 修改电检数据记录 + * + * @param recordElectricalInspection 电检数据记录 + * @return 结果 + */ + public int updateRecordElectricalInspection(RecordElectricalInspection recordElectricalInspection); + + /** + * 批量删除电检数据记录 + * + * @param uuids 需要删除的电检数据记录主键集合 + * @return 结果 + */ + public int deleteRecordElectricalInspectionByUuids(String[] uuids); + + /** + * 删除电检数据记录信息 + * + * @param uuid 电检数据记录主键 + * @return 结果 + */ + public int deleteRecordElectricalInspectionByUuid(String uuid); +} diff --git a/aucma-report/src/main/java/com/aucma/report/service/impl/RecordElectricalInspectionServiceImpl.java b/aucma-report/src/main/java/com/aucma/report/service/impl/RecordElectricalInspectionServiceImpl.java new file mode 100644 index 0000000..e281c1f --- /dev/null +++ b/aucma-report/src/main/java/com/aucma/report/service/impl/RecordElectricalInspectionServiceImpl.java @@ -0,0 +1,131 @@ +package com.aucma.report.service.impl; + +import java.util.List; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import java.util.ArrayList; +import com.aucma.common.utils.StringUtils; +import org.springframework.transaction.annotation.Transactional; +import com.aucma.report.domain.DetailElectricalinspection; +import com.aucma.report.mapper.RecordElectricalInspectionMapper; +import com.aucma.report.domain.RecordElectricalInspection; +import com.aucma.report.service.IRecordElectricalInspectionService; + +/** + * 电检数据记录Service业务层处理 + * + * @author Yinq + * @date 2023-11-09 + */ +@Service +public class RecordElectricalInspectionServiceImpl implements IRecordElectricalInspectionService +{ + @Autowired + private RecordElectricalInspectionMapper recordElectricalInspectionMapper; + + /** + * 查询电检数据记录 + * + * @param uuid 电检数据记录主键 + * @return 电检数据记录 + */ + @Override + public RecordElectricalInspection selectRecordElectricalInspectionByUuid(String uuid) + { + return recordElectricalInspectionMapper.selectRecordElectricalInspectionByUuid(uuid); + } + + /** + * 查询电检数据记录列表 + * + * @param recordElectricalInspection 电检数据记录 + * @return 电检数据记录 + */ + @Override + public List selectRecordElectricalInspectionList(RecordElectricalInspection recordElectricalInspection) + { + return recordElectricalInspectionMapper.selectRecordElectricalInspectionList(recordElectricalInspection); + } + + /** + * 新增电检数据记录 + * + * @param recordElectricalInspection 电检数据记录 + * @return 结果 + */ + @Transactional + @Override + public int insertRecordElectricalInspection(RecordElectricalInspection recordElectricalInspection) + { + int rows = recordElectricalInspectionMapper.insertRecordElectricalInspection(recordElectricalInspection); + insertDetailElectricalinspection(recordElectricalInspection); + return rows; + } + + /** + * 修改电检数据记录 + * + * @param recordElectricalInspection 电检数据记录 + * @return 结果 + */ + @Transactional + @Override + public int updateRecordElectricalInspection(RecordElectricalInspection recordElectricalInspection) + { + recordElectricalInspectionMapper.deleteDetailElectricalinspectionByUuid(recordElectricalInspection.getUuid()); + insertDetailElectricalinspection(recordElectricalInspection); + return recordElectricalInspectionMapper.updateRecordElectricalInspection(recordElectricalInspection); + } + + /** + * 批量删除电检数据记录 + * + * @param uuids 需要删除的电检数据记录主键 + * @return 结果 + */ + @Transactional + @Override + public int deleteRecordElectricalInspectionByUuids(String[] uuids) + { + recordElectricalInspectionMapper.deleteDetailElectricalinspectionByUuids(uuids); + return recordElectricalInspectionMapper.deleteRecordElectricalInspectionByUuids(uuids); + } + + /** + * 删除电检数据记录信息 + * + * @param uuid 电检数据记录主键 + * @return 结果 + */ + @Transactional + @Override + public int deleteRecordElectricalInspectionByUuid(String uuid) + { + recordElectricalInspectionMapper.deleteDetailElectricalinspectionByUuid(uuid); + return recordElectricalInspectionMapper.deleteRecordElectricalInspectionByUuid(uuid); + } + + /** + * 新增电检数据明细信息 + * + * @param recordElectricalInspection 电检数据记录对象 + */ + public void insertDetailElectricalinspection(RecordElectricalInspection recordElectricalInspection) + { + List detailElectricalinspectionList = recordElectricalInspection.getDetailElectricalinspectionList(); + String uuid = recordElectricalInspection.getUuid(); + if (StringUtils.isNotNull(detailElectricalinspectionList)) + { + List list = new ArrayList(); + for (DetailElectricalinspection detailElectricalinspection : detailElectricalinspectionList) + { + detailElectricalinspection.setUuid(uuid); + list.add(detailElectricalinspection); + } + if (list.size() > 0) + { + recordElectricalInspectionMapper.batchDetailElectricalinspection(list); + } + } + } +} diff --git a/aucma-report/src/main/resources/mapper/report/RecordElectricalInspectionMapper.xml b/aucma-report/src/main/resources/mapper/report/RecordElectricalInspectionMapper.xml new file mode 100644 index 0000000..254f227 --- /dev/null +++ b/aucma-report/src/main/resources/mapper/report/RecordElectricalInspectionMapper.xml @@ -0,0 +1,140 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select uuid, result, barcode, testtime, testdata, recordtime + from record_electricalinspection + + + + + + + + insert into record_electricalinspection + + uuid, + result, + barcode, + testtime, + testdata, + recordtime, + + + #{uuid}, + #{result}, + #{barcode}, + #{testTime}, + #{testData}, + #{recordTime}, + + + + + update record_electricalinspection + + result = #{result}, + barcode = #{barcode}, + testtime = #{testTime}, + testdata = #{testData}, + recordtime = #{recordTime}, + + where uuid = #{uuid} + + + + delete + from record_electricalinspection + where uuid = #{uuid} + + + + delete from record_electricalinspection where uuid in + + #{uuid} + + + + + delete from detail_electricalinspection where uuid in + + #{uuid} + + + + + delete + from detail_electricalinspection + where uuid = #{uuid} + + + + insert all + + into detail_electricalinspection( uuid, serialnumber, projectname, testcondition, testvalue, testresult, + recordtime) values ( #{item.uuid}, #{item.serialnumber}, #{item.projectname}, #{item.testcondition}, + #{item.testvalue}, #{item.testresult}, #{item.recordtime}) + + SELECT 1 FROM DUAL + + \ No newline at end of file