diff --git a/ruoyi-modules/aidmt-manage-ms/pom.xml b/ruoyi-modules/aidmt-manage-ms/pom.xml
new file mode 100644
index 00000000..a7947264
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/pom.xml
@@ -0,0 +1,102 @@
+
+
+
+ com.ruoyi
+ ruoyi-modules
+ 3.6.7
+
+ 4.0.0
+
+ aidmt-manage-ms
+
+
+ ruoyi-modules-property 物业施工作业管理系统
+
+
+
+
+
+
+ com.alibaba.cloud
+ spring-cloud-starter-alibaba-nacos-discovery
+
+
+
+
+ com.alibaba.cloud
+ spring-cloud-starter-alibaba-nacos-config
+
+
+
+
+ com.alibaba.cloud
+ spring-cloud-starter-alibaba-sentinel
+
+
+
+
+ org.springframework.boot
+ spring-boot-starter-actuator
+
+
+
+
+ com.mysql
+ mysql-connector-j
+
+
+
+
+ com.ruoyi
+ ruoyi-common-datasource
+
+
+
+
+ com.ruoyi
+ ruoyi-common-datascope
+
+
+
+
+ com.ruoyi
+ ruoyi-common-log
+
+
+
+
+ com.ruoyi
+ ruoyi-common-swagger
+
+
+ org.projectlombok
+ lombok
+ provided
+
+
+ org.springframework.security
+ spring-security-core
+
+
+
+
+
+ ${project.artifactId}
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+ repackage
+
+
+
+
+
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/AidmtManageApplication.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/AidmtManageApplication.java
new file mode 100644
index 00000000..76695f64
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/AidmtManageApplication.java
@@ -0,0 +1,26 @@
+package com.admin;
+
+import org.mybatis.spring.annotation.MapperScan;
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+import com.ruoyi.common.security.annotation.EnableCustomConfig;
+import com.ruoyi.common.security.annotation.EnableRyFeignClients;
+
+/**
+ * 业务功能模块
+ *
+ * @author ruoyi
+ */
+@EnableCustomConfig
+@EnableRyFeignClients
+@SpringBootApplication
+@MapperScan("com.admin.*.mapper")
+public class AidmtManageApplication
+{
+ public static void main(String[] args)
+ {
+ SpringApplication.run(AidmtManageApplication.class, args);
+ System.out.println("(♥◠‿◠)ノ゙ 业务功能模块启动成功 ლ(´ڡ`ლ)゙ ");
+ }
+}
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraAllocationController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraAllocationController.java
new file mode 100644
index 00000000..1df32f8f
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraAllocationController.java
@@ -0,0 +1,55 @@
+package com.admin.property.controller;
+
+import com.admin.property.domain.PcCameraLedger;
+import com.admin.property.service.IPcCameraBizService;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.admin.property.domain.PcCameraAlloc;
+import com.admin.property.domain.dto.PcCameraAllocConfirmDTO;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+@Tag(name = "球机分配(高风险项目)")
+@RestController
+@RequestMapping("/camera/alloc")
+public class PcCameraAllocationController extends BaseController {
+
+ private final IPcCameraBizService bizService;
+
+ public PcCameraAllocationController(IPcCameraBizService bizService) {
+ this.bizService = bizService;
+ }
+
+ @Operation(summary = "可分配球机列表(弹窗勾选)")
+ @PreAuthorize("@ss.hasPermi('property:camera:available')")
+ @GetMapping("/availableList")
+ public TableDataInfo availableList(PcCameraLedger query) {
+ startPage();
+ List list = bizService.selectAvailableCameras(query);
+ return getDataTable(list);
+ }
+
+ @Operation(summary = "项目分配详情(查看分配详情)")
+ @PreAuthorize("@ss.hasPermi('property:camera:alloc:query')")
+ @GetMapping("/listByProject/{projectId}")
+ public AjaxResult listByProject(@PathVariable Long projectId) {
+ List list = bizService.selectAllocListByProjectId(projectId);
+ return success(list);
+ }
+
+ @Operation(summary = "确认分配(项目 -> 多台球机)")
+ @PreAuthorize("@ss.hasPermi('property:camera:alloc:confirm')")
+ @Log(title = "高风险项目分配球机", businessType = BusinessType.INSERT)
+ @PostMapping("/confirm")
+ public AjaxResult confirm(@Validated @RequestBody PcCameraAllocConfirmDTO dto) {
+ return toAjax(bizService.confirmAllocate(dto));
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraInboundController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraInboundController.java
new file mode 100644
index 00000000..2c39bfef
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraInboundController.java
@@ -0,0 +1,54 @@
+package com.admin.property.controller;
+
+import com.admin.property.service.IPcCameraBizService;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.admin.property.domain.PcCameraReturn;
+import com.admin.property.domain.dto.PcCameraInboundAuditDTO;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+@Tag(name = "球机入库审核")
+@RestController
+@RequestMapping("/camera/inbound")
+public class PcCameraInboundController extends BaseController {
+
+ private final IPcCameraBizService bizService;
+
+ public PcCameraInboundController(IPcCameraBizService bizService) {
+ this.bizService = bizService;
+ }
+
+ @Operation(summary = "入库审核列表(待审核)")
+ @PreAuthorize("@ss.hasPermi('property:camera:inbound:list')")
+ @GetMapping("/auditList")
+ public TableDataInfo auditList(PcCameraReturn query) {
+ startPage();
+ List list = bizService.selectAuditPendingList(query);
+ return getDataTable(list);
+ }
+
+ @Operation(summary = "确认入库(审核通过)")
+ @PreAuthorize("@ss.hasPermi('property:camera:inbound:approve')")
+ @Log(title = "球机入库审核-通过", businessType = BusinessType.UPDATE)
+ @PostMapping("/approve")
+ public AjaxResult approve(@Validated @RequestBody PcCameraInboundAuditDTO dto) {
+ return toAjax(bizService.approveInbound(dto));
+ }
+
+ @Operation(summary = "驳回入库(审核驳回)")
+ @PreAuthorize("@ss.hasPermi('property:camera:inbound:reject')")
+ @Log(title = "球机入库审核-驳回", businessType = BusinessType.UPDATE)
+ @PostMapping("/reject")
+ public AjaxResult reject(@Validated @RequestBody PcCameraInboundAuditDTO dto) {
+ return toAjax(bizService.rejectInbound(dto));
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraLedgerController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraLedgerController.java
new file mode 100644
index 00000000..da054a7d
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraLedgerController.java
@@ -0,0 +1,120 @@
+package com.admin.property.controller;
+
+import com.admin.property.service.IPcCameraLedgerService;
+import com.ruoyi.common.core.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.admin.property.domain.PcCameraLedger;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
+
+import javax.servlet.http.HttpServletResponse;
+import java.util.List;
+
+import static com.ruoyi.common.security.utils.SecurityUtils.getUsername;
+
+@Tag(name = "移动球机管控-球机台账")
+@RestController
+@RequestMapping("/camera/ledger")
+public class PcCameraLedgerController extends BaseController {
+
+ @Autowired
+ private IPcCameraLedgerService pcCameraLedgerService;
+
+ @Operation(summary = "球机台账-分页列表", description = "支持按状态、仓库、单位、时间范围筛选")
+ @PreAuthorize("@ss.hasPermi('property:camera:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(
+ @Parameter(description = "查询条件对象")
+ PcCameraLedger pcCameraLedger) {
+ startPage();
+ List list = pcCameraLedgerService.selectPcCameraLedgerList(pcCameraLedger);
+ return getDataTable(list);
+ }
+
+ @Operation(summary = "球机台账-导出Excel", description = "按筛选条件导出Excel")
+ @PreAuthorize("@ss.hasPermi('property:camera:export')")
+ @Log(title = "球机台账", businessType = BusinessType.EXPORT)
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, PcCameraLedger pcCameraLedger) {
+ List list = pcCameraLedgerService.selectPcCameraLedgerList(pcCameraLedger);
+ ExcelUtil util = new ExcelUtil<>(PcCameraLedger.class);
+ util.exportExcel(response, list, "球机台账");
+ }
+
+ @Operation(summary = "球机台账-详情", description = "根据cameraId查询单条台账详情")
+ @PreAuthorize("@ss.hasPermi('property:camera:query')")
+ @GetMapping("/{cameraId}")
+ public AjaxResult getInfo(
+ @Parameter(description = "台账主键ID", required = true, example = "1")
+ @PathVariable Long cameraId) {
+ return success(pcCameraLedgerService.selectPcCameraLedgerByCameraId(cameraId));
+ }
+
+ @Operation(summary = "球机台账-新增", description = "新增一条球机台账记录")
+ @PreAuthorize("@ss.hasPermi('property:camera:add')")
+ @Log(title = "球机台账", businessType = BusinessType.INSERT)
+ @PostMapping
+ public AjaxResult add(@Validated @RequestBody PcCameraLedger pcCameraLedger) {
+ pcCameraLedger.setCreateBy(getUsername());
+ pcCameraLedger.setUpdateBy(getUsername());
+ return toAjax(pcCameraLedgerService.insertPcCameraLedger(pcCameraLedger));
+ }
+
+ @Operation(summary = "球机台账-修改", description = "修改球机台账记录")
+ @PreAuthorize("@ss.hasPermi('property:camera:edit')")
+ @Log(title = "球机台账", businessType = BusinessType.UPDATE)
+ @PutMapping
+ public AjaxResult edit(@Validated @RequestBody PcCameraLedger pcCameraLedger) {
+ pcCameraLedger.setUpdateBy(getUsername());
+ return toAjax(pcCameraLedgerService.updatePcCameraLedger(pcCameraLedger));
+ }
+
+ @Operation(summary = "球机台账-删除(逻辑删除)", description = "批量逻辑删除,del_flag=2")
+ @PreAuthorize("@ss.hasPermi('property:camera:remove')")
+ @Log(title = "球机台账", businessType = BusinessType.DELETE)
+ @DeleteMapping("/{cameraIds}")
+ public AjaxResult remove(
+ @Parameter(description = "台账ID数组(逗号分隔)", required = true, example = "1,2,3")
+ @PathVariable Long[] cameraIds) {
+ return toAjax(pcCameraLedgerService.deletePcCameraLedgerByCameraIds(cameraIds));
+ }
+
+ @Operation(summary = "球机台账-状态变更", description = "状态:0闲置 1已分配 2待回收 3已入库")
+ @PreAuthorize("@ss.hasPermi('property:camera:edit')")
+ @Log(title = "球机台账-状态", businessType = BusinessType.UPDATE)
+ @PutMapping("/changeStatus")
+ public AjaxResult changeStatus(@RequestParam("cameraId") Long cameraId,
+ @RequestParam("status") String status) {
+ return toAjax(pcCameraLedgerService.changeStatus(cameraId, status));
+ }
+
+ @Operation(summary = "球机台账-批量导入", description = "导入Excel,updateSupport=true 时遇到已存在编号则更新")
+ @PreAuthorize("@ss.hasPermi('property:camera:import')")
+ @Log(title = "球机台账", businessType = BusinessType.IMPORT)
+ @PostMapping("/importData")
+ public AjaxResult importData(@RequestParam("file") MultipartFile file,
+ @RequestParam(value = "updateSupport", defaultValue = "false") boolean updateSupport) throws Exception {
+ ExcelUtil util = new ExcelUtil<>(PcCameraLedger.class);
+ List list = util.importExcel(file.getInputStream());
+ String msg = pcCameraLedgerService.importData(list, updateSupport, getUsername());
+ return success(msg);
+ }
+
+ @Operation(summary = "球机台账-导入模板", description = "下载Excel导入模板")
+ @PreAuthorize("@ss.hasPermi('property:camera:import')")
+ @PostMapping("/importTemplate")
+ public void importTemplate(HttpServletResponse response) {
+ ExcelUtil util = new ExcelUtil<>(PcCameraLedger.class);
+ util.importTemplateExcel(response, "球机台账导入模板");
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraReturnController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraReturnController.java
new file mode 100644
index 00000000..f7860b0d
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcCameraReturnController.java
@@ -0,0 +1,46 @@
+package com.admin.property.controller;
+
+import com.admin.property.service.IPcCameraBizService;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.admin.property.domain.PcCameraReturn;
+import com.admin.property.domain.dto.PcCameraReturnSubmitDTO;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+@Tag(name = "球机回收")
+@RestController
+@RequestMapping("/camera/return")
+public class PcCameraReturnController extends BaseController {
+
+ private final IPcCameraBizService bizService;
+
+ public PcCameraReturnController(IPcCameraBizService bizService) {
+ this.bizService = bizService;
+ }
+
+ @Operation(summary = "回收记录列表(已回收待入库/已入库/已驳回等)")
+ @PreAuthorize("@ss.hasPermi('property:camera:return:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(PcCameraReturn query) {
+ startPage();
+ List list = bizService.selectReturnList(query);
+ return getDataTable(list);
+ }
+
+ @Operation(summary = "回收确认提交(项目 -> 多台球机)")
+ @PreAuthorize("@ss.hasPermi('property:camera:return:submit')")
+ @Log(title = "球机回收确认", businessType = BusinessType.INSERT)
+ @PostMapping("/submit")
+ public AjaxResult submit(@Validated @RequestBody PcCameraReturnSubmitDTO dto) {
+ return toAjax(bizService.submitReturn(dto));
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcRiskProjectController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcRiskProjectController.java
new file mode 100644
index 00000000..caabb6fd
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcRiskProjectController.java
@@ -0,0 +1,68 @@
+package com.admin.property.controller;
+
+import com.admin.property.service.IPcRiskProjectService;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+import com.admin.property.domain.PcRiskProject;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import static com.ruoyi.common.security.utils.SecurityUtils.getUsername;
+
+@Tag(name = "高风险项目管理")
+@RestController
+@RequestMapping("/project/risk")
+public class PcRiskProjectController extends BaseController {
+
+ @Autowired
+ private IPcRiskProjectService pcRiskProjectService;
+
+ /** 列表(高风险项目) */
+ @Operation(summary = "高风险项目分页查询", description = "分页查询高风险项目")
+ @PreAuthorize("@ss.hasPermi('property:project:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(
+ @Parameter(description = "查询条件对象")
+ PcRiskProject project) {
+ startPage();
+ return getDataTable(pcRiskProjectService.selectPcRiskProjectList(project));
+ }
+
+ /** 查询高风险项目详情 */
+ @Operation(summary = "高风险项目详情", description = "根据ID查询项目详情")
+ @PreAuthorize("@ss.hasPermi('property:project:query')")
+ @GetMapping("/{projectId}")
+ public AjaxResult getInfo(@PathVariable Long projectId) {
+ return success(pcRiskProjectService.selectPcRiskProjectById(projectId));
+ }
+
+ /** 修改高风险项目 */
+ @Operation(summary = "修改高风险项目", description = "根据ID修改项目")
+ @PreAuthorize("@ss.hasPermi('property:project:edit')")
+ @Log(title = "高风险项目", businessType = BusinessType.UPDATE)
+ @PutMapping("/{projectId}")
+ public AjaxResult edit(
+ @Parameter(description = "项目ID")
+ @PathVariable Long projectId,
+ @Parameter(description = "修改后的项目数据")
+ @RequestBody PcRiskProject project) {
+ project.setUpdateBy(getUsername());
+ return toAjax(pcRiskProjectService.updatePcRiskProject(projectId, project));
+ }
+
+ /** 删除高风险项目 */
+ @Operation(summary = "删除高风险项目", description = "根据ID删除项目")
+ @PreAuthorize("@ss.hasPermi('property:project:remove')")
+ @Log(title = "高风险项目", businessType = BusinessType.DELETE)
+ @DeleteMapping("/{projectIds}")
+ public AjaxResult remove(@PathVariable Long[] projectIds) {
+ return toAjax(pcRiskProjectService.deletePcRiskProjectByIds(projectIds));
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcUnitArchiveController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcUnitArchiveController.java
new file mode 100644
index 00000000..0adc78a4
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/PcUnitArchiveController.java
@@ -0,0 +1,104 @@
+package com.admin.property.controller;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+
+import com.admin.property.service.IPcUnitArchiveService;
+import com.admin.property.domain.PcUnitArchive;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.validation.annotation.Validated;
+import org.springframework.web.bind.annotation.*;
+
+import com.ruoyi.common.core.utils.poi.ExcelUtil;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.ruoyi.common.log.annotation.Log;
+import com.ruoyi.common.log.enums.BusinessType;
+
+import static com.ruoyi.common.security.utils.SecurityUtils.getUsername;
+
+import io.swagger.v3.oas.annotations.tags.Tag;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.Parameter;
+
+@Tag(name = "单位与账号管理-单位建档")
+@RestController
+@RequestMapping("/unit/archive")
+public class PcUnitArchiveController extends BaseController {
+
+ @Autowired
+ private IPcUnitArchiveService pcUnitArchiveService;
+
+
+ @Operation(summary = "单位建档-列表查询")
+ @PreAuthorize("@ss.hasPermi('property:unit:list')")
+ @GetMapping("/list")
+ public TableDataInfo list(PcUnitArchive pcUnitArchive) {
+ startPage();
+ List list = pcUnitArchiveService.selectPcUnitArchiveList(pcUnitArchive);
+ return getDataTable(list);
+ }
+
+ @Operation(summary = "单位建档-导出Excel")
+ @PreAuthorize("@ss.hasPermi('property:unit:export')")
+ @Log(title = "单位建档", businessType = BusinessType.EXPORT)
+ @PostMapping("/export")
+ public void export(HttpServletResponse response, PcUnitArchive pcUnitArchive) {
+ List list = pcUnitArchiveService.selectPcUnitArchiveList(pcUnitArchive);
+ ExcelUtil util = new ExcelUtil<>(PcUnitArchive.class);
+ util.exportExcel(response, list, "单位建档数据");
+ }
+
+ @Operation(summary = "单位建档-详情")
+ @PreAuthorize("@ss.hasPermi('property:unit:query')")
+ @GetMapping("/{unitId}")
+ public AjaxResult getInfo(
+ @Parameter(description = "单位ID", required = true, example = "1")
+ @PathVariable("unitId") Long unitId) {
+ return success(pcUnitArchiveService.selectPcUnitArchiveByUnitId(unitId));
+ }
+
+ @Operation(summary = "单位建档-新增")
+ @PreAuthorize("@ss.hasPermi('property:unit:add')")
+ @Log(title = "单位建档", businessType = BusinessType.INSERT)
+ @PostMapping
+ public AjaxResult add(@Validated @RequestBody PcUnitArchive pcUnitArchive) {
+ pcUnitArchive.setCreateBy(getUsername());
+ pcUnitArchive.setUpdateBy(getUsername());
+ return toAjax(pcUnitArchiveService.insertPcUnitArchive(pcUnitArchive));
+ }
+
+ @Operation(summary = "单位建档-修改")
+ @PreAuthorize("@ss.hasPermi('property:unit:edit')")
+ @Log(title = "单位建档", businessType = BusinessType.UPDATE)
+ @PutMapping
+ public AjaxResult edit(@Validated @RequestBody PcUnitArchive pcUnitArchive) {
+ pcUnitArchive.setUpdateBy(getUsername());
+ return toAjax(pcUnitArchiveService.updatePcUnitArchive(pcUnitArchive));
+ }
+
+ @Operation(summary = "单位建档-删除(逻辑删除)")
+ @PreAuthorize("@ss.hasPermi('property:unit:remove')")
+ @Log(title = "单位建档", businessType = BusinessType.DELETE)
+ @DeleteMapping("/{unitIds}")
+ public AjaxResult remove(
+ @Parameter(description = "单位ID数组(逗号分隔)", required = true, example = "1,2,3")
+ @PathVariable Long[] unitIds) {
+ return toAjax(pcUnitArchiveService.deletePcUnitArchiveByUnitIds(unitIds));
+ }
+
+ @Operation(summary = "单位建档-启用/禁用")
+ @PreAuthorize("@ss.hasPermi('property:unit:edit')")
+ @Log(title = "单位建档-状态", businessType = BusinessType.UPDATE)
+ @PutMapping("/changeStatus")
+ public AjaxResult changeStatus(
+ @Parameter(description = "单位ID", required = true, example = "1")
+ @RequestParam("unitId") Long unitId,
+ @Parameter(description = "状态(0启用/1禁用)", required = true, example = "0")
+ @RequestParam("status") String status) {
+ return toAjax(pcUnitArchiveService.changeStatus(unitId, status));
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/ProjectCompletionReviewController.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/ProjectCompletionReviewController.java
new file mode 100644
index 00000000..8d09c88d
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/controller/ProjectCompletionReviewController.java
@@ -0,0 +1,70 @@
+package com.admin.property.controller;
+
+import com.admin.property.service.IPcRiskProjectService;
+import com.ruoyi.common.core.web.controller.BaseController;
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.ruoyi.common.core.web.page.TableDataInfo;
+import com.admin.property.domain.PcRiskProject;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+@Tag(name = "项目复核-完工复核管理")
+@RestController
+@RequestMapping("/project/completionReview")
+public class ProjectCompletionReviewController extends BaseController {
+
+ @Autowired
+ private IPcRiskProjectService pcRiskProjectService;
+
+ /** 项目完工复核列表 */
+ @Operation(summary = "项目完工复核-分页列表", description = "支持按项目名称、施工单位等条件筛选")
+ @PreAuthorize("@ss.hasPermi('property:project:completionReviewList')")
+ @GetMapping("/list")
+ public TableDataInfo list(PcRiskProject pcRiskProject) {
+ startPage();
+ List list = pcRiskProjectService.selectProjectCompletionReviewList(pcRiskProject);
+ return getDataTable(list);
+ }
+
+ /** 现场复核提交 */
+ @Operation(summary = "项目完工复核-现场复核提交", description = "提交现场复核并更新状态")
+ @PreAuthorize("@ss.hasPermi('property:project:onSiteReview')")
+ @PutMapping("/onSiteReview")
+ public AjaxResult onSiteReview(
+ @RequestParam Long projectId,
+ @RequestParam String onSiteReviewStatus,
+ @RequestParam String onSiteReviewImages,
+ @RequestParam Integer workContentCompleteRate,
+ @RequestParam String siteCleaningCondition,
+ @RequestParam String reviewComments) {
+
+ // 先检查监理复核状态,确保复核通过
+ PcRiskProject project = pcRiskProjectService.selectPcRiskProjectById(projectId);
+ if (project == null || !"复核通过".equals(project.getSupervisionReviewStatus())) {
+ return AjaxResult.error("监理复核未通过,无法进行现场复核");
+ }
+
+ return toAjax(pcRiskProjectService.onSiteReview(projectId, onSiteReviewStatus, onSiteReviewImages, workContentCompleteRate, siteCleaningCondition, reviewComments));
+ }
+
+ /** 最终审核提交 */
+ @Operation(summary = "项目完工复核-最终审核提交", description = "最终审核项目,确认无异议后提交")
+ @PreAuthorize("@ss.hasPermi('property:project:finalAudit')")
+ @PutMapping("/finalAudit")
+ public AjaxResult finalAudit(
+ @RequestParam Long projectId) {
+
+ // 先检查现场复核是否已完成
+ PcRiskProject project = pcRiskProjectService.selectPcRiskProjectById(projectId);
+ if (project == null || !"已复核".equals(project.getOnSiteReviewStatus())) {
+ return AjaxResult.error("现场复核未完成,无法进行最终审核");
+ }
+
+ return toAjax(pcRiskProjectService.finalAudit(projectId));
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraAlloc.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraAlloc.java
new file mode 100644
index 00000000..34217379
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraAlloc.java
@@ -0,0 +1,34 @@
+package com.admin.property.domain;
+
+import com.ruoyi.common.core.web.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.util.Date;
+
+@Data
+@EqualsAndHashCode(callSuper = true)
+@Schema(description = "项目球机分配记录")
+public class PcCameraAlloc extends BaseEntity {
+
+ private Long allocId;
+ private Long projectId;
+ private Long cameraId;
+
+ private Date allocTime;
+ private String allocBy;
+ private String allocNote;
+
+ @Schema(description = "1已分配 2已回收提交 3已入库完成")
+ private String allocStatus;
+
+ private String delFlag;
+
+ // 方便列表展示(JOIN字段)
+ private String cameraNo;
+ private String model;
+ private String projectName;
+ private String constructionUnit;
+ private String workLocation;
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraInbound.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraInbound.java
new file mode 100644
index 00000000..738283d3
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraInbound.java
@@ -0,0 +1,23 @@
+package com.admin.property.domain;
+
+import com.ruoyi.common.core.web.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.util.Date;
+
+@Data
+@EqualsAndHashCode(callSuper = true)
+@Schema(description = "球机入库记录")
+public class PcCameraInbound extends BaseEntity {
+
+ private Long inboundId;
+ private Long returnId;
+ private Long cameraId;
+
+ private String warehouse;
+ private String keeper;
+ private Date inboundTime;
+ private String remark;
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraLedger.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraLedger.java
new file mode 100644
index 00000000..20c038c6
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraLedger.java
@@ -0,0 +1,39 @@
+package com.admin.property.domain;
+
+import com.ruoyi.common.core.web.domain.BaseEntity;
+import com.ruoyi.common.core.annotation.Excel;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+@Data
+@EqualsAndHashCode(callSuper = true)
+@Schema(description = "球机台账")
+public class PcCameraLedger extends BaseEntity {
+
+ @Schema(description = "球机ID")
+ private Long cameraId;
+
+ @Excel(name = "球机编号")
+ @Schema(description = "球机编号")
+ private String cameraNo;
+
+ @Excel(name = "型号")
+ @Schema(description = "型号")
+ private String model;
+
+ @Excel(name = "状态", readConverterExp = "0=在库,1=已分配,2=已回收待入库,3=已入库")
+ @Schema(description = "状态:0在库 1已分配 2已回收待入库 3已入库")
+ private String status;
+
+ @Excel(name = "所属单位")
+ @Schema(description = "所属单位")
+ private String ownerUnit;
+
+ @Excel(name = "所在仓库")
+ @Schema(description = "所在仓库")
+ private String warehouse;
+
+ @Schema(description = "逻辑删除标记:0存在 2删除")
+ private String delFlag;
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraReturn.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraReturn.java
new file mode 100644
index 00000000..34fc79c9
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcCameraReturn.java
@@ -0,0 +1,46 @@
+package com.admin.property.domain;
+
+import com.ruoyi.common.core.web.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.util.Date;
+
+@Data
+@EqualsAndHashCode(callSuper = true)
+@Schema(description = "球机回收记录(待入库审核)")
+public class PcCameraReturn extends BaseEntity {
+
+ private Long returnId;
+ private Long allocId;
+ private Long projectId;
+ private Long cameraId;
+
+ @Schema(description = "0合格 1不合格 2不齐全")
+ private String checkResult;
+
+ private String returnBy;
+ private Date returnTime;
+
+ @Schema(description = "回收照片url,逗号分隔")
+ private String photoUrls;
+
+ private String remark;
+
+ @Schema(description = "0待审核 1已通过 2已驳回")
+ private String auditStatus;
+
+ private String auditBy;
+ private Date auditTime;
+ private String auditRemark;
+
+ private String delFlag;
+
+ // JOIN展示字段
+ private String cameraNo;
+ private String model;
+ private String projectName;
+ private String constructionUnit;
+ private String workLocation;
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcRiskProject.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcRiskProject.java
new file mode 100644
index 00000000..55f6fe85
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcRiskProject.java
@@ -0,0 +1,73 @@
+package com.admin.property.domain;
+
+import com.ruoyi.common.core.web.domain.BaseEntity;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+@Data
+@EqualsAndHashCode(callSuper = true)
+@Schema(description = "高风险项目")
+public class PcRiskProject extends BaseEntity {
+
+ @Schema(description = "项目ID")
+ private Long projectId;
+
+ @Schema(description = "项目名称")
+ private String projectName;
+
+ @Schema(description = "项目编号")
+ private String projectCode;
+
+ @Schema(description = "施工单位")
+ private String constructionUnit;
+
+ @Schema(description = "工作地点")
+ private String workLocation;
+
+ @Schema(description = "工作开始时间")
+ private String workStart;
+
+ @Schema(description = "工作结束时间")
+ private String workEnd;
+
+ @Schema(description = "风险类型")
+ private String riskType;
+
+ @Schema(description = "需要摄像头数量")
+ private Integer needCameraCnt;
+
+ @Schema(description = "分配状态:0待分配,1已分配")
+ private String allocStatus;
+
+ @Schema(description = "删除标记:0存在 2删除")
+ private String delFlag;
+
+ @Schema(description = "备注")
+ private String remark;
+
+ @Schema(description = "监理复核状态")
+ private String supervisionReviewStatus;
+
+ @Schema(description = "现场复核状态")
+ private String onSiteReviewStatus;
+
+ @Schema(description = "最终审核状态")
+ private String finalAuditStatus;
+
+ @Schema(description = "项目状态")
+ private String projectStatus;
+
+ @Schema(description = "现场复核图片(URL数组)")
+ private String onSiteReviewImages;
+
+ @Schema(description = "作业内容完成度")
+ private Integer workContentCompleteRate;
+
+ @Schema(description = "现场清理情况")
+ private String siteCleaningCondition;
+
+ @Schema(description = "复核意见")
+ private String reviewComments;
+
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcUnitArchive.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcUnitArchive.java
new file mode 100644
index 00000000..c659583e
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/PcUnitArchive.java
@@ -0,0 +1,65 @@
+package com.admin.property.domain;
+
+import com.ruoyi.common.core.annotation.Excel;
+import com.ruoyi.common.core.web.domain.BaseEntity;
+import lombok.Data;
+
+@Data
+public class PcUnitArchive extends BaseEntity {
+
+ private static final long serialVersionUID = 1L;
+
+ /** 主键 */
+ private Long unitId;
+
+ /** 单位类型(1施工/2监理/3业主) */
+ @Excel(name = "单位类型", readConverterExp = "1=施工单位,2=监理单位,3=业主单位")
+ private String unitType;
+
+ /** 单位名称 */
+ @Excel(name = "单位名称")
+ private String unitName;
+
+ /** 所属区域编码 */
+ private String areaCode;
+
+ /** 所属区域名称 */
+ @Excel(name = "所属区域")
+ private String areaName;
+
+ /** 统一社会信用代码 */
+ @Excel(name = "统一社会信用代码")
+ private String creditCode;
+
+ /** 联系人 */
+ @Excel(name = "联系人")
+ private String contactName;
+
+ /** 联系电话 */
+ @Excel(name = "联系电话")
+ private String contactPhone;
+
+ /** 单位地址 */
+ @Excel(name = "单位地址")
+ private String address;
+
+ /** 资质文件(上传后URL/路径) */
+ @Excel(name = "资质文件")
+ private String qualFileUrl;
+
+ /** 备注 */
+ @Excel(name = "备注")
+ private String remark;
+
+ /** 建档状态(0草稿/1已建档) */
+ @Excel(name = "建档状态", readConverterExp = "0=草稿,1=已建档")
+ private String archiveStatus;
+
+ /** 状态(0启用/1禁用) */
+ @Excel(name = "状态", readConverterExp = "0=启用,1=禁用")
+ private String status;
+
+ /** 删除标志(0存在/2删除) */
+ private String delFlag;
+
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraAllocConfirmDTO.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraAllocConfirmDTO.java
new file mode 100644
index 00000000..9edc498d
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraAllocConfirmDTO.java
@@ -0,0 +1,24 @@
+package com.admin.property.domain.dto;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+import java.util.Date;
+import java.util.List;
+
+@Data
+@Schema(description = "确认分配球机请求")
+public class PcCameraAllocConfirmDTO {
+
+ @Schema(description = "项目ID")
+ private Long projectId;
+
+ @Schema(description = "选中的球机ID列表")
+ private List cameraIds;
+
+ @Schema(description = "分配时间(不传则取当前时间)")
+ private Date allocTime;
+
+ @Schema(description = "分配备注")
+ private String allocNote;
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraInboundAuditDTO.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraInboundAuditDTO.java
new file mode 100644
index 00000000..890fcae0
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraInboundAuditDTO.java
@@ -0,0 +1,27 @@
+package com.admin.property.domain.dto;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+import java.util.Date;
+import java.util.List;
+
+@Data
+@Schema(description = "入库审核请求(通过/驳回)")
+public class PcCameraInboundAuditDTO {
+
+ @Schema(description = "回收记录ID列表")
+ private List returnIds;
+
+ @Schema(description = "仓库名称(通过时必填)")
+ private String warehouse;
+
+ @Schema(description = "库管/审核人(不传则取当前登录人)")
+ private String keeper;
+
+ @Schema(description = "入库时间(不传则取当前时间)")
+ private Date inboundTime;
+
+ @Schema(description = "驳回原因/审核备注")
+ private String auditRemark;
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraReturnSubmitDTO.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraReturnSubmitDTO.java
new file mode 100644
index 00000000..e0b0bfb6
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/domain/dto/PcCameraReturnSubmitDTO.java
@@ -0,0 +1,30 @@
+package com.admin.property.domain.dto;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+import java.util.Date;
+import java.util.List;
+
+@Data
+@Schema(description = "回收确认提交请求")
+public class PcCameraReturnSubmitDTO {
+
+ @Schema(description = "项目ID")
+ private Long projectId;
+
+ @Schema(description = "回收球机ID列表")
+ private List cameraIds;
+
+ @Schema(description = "0合格 1不合格 2不齐全")
+ private String checkResult;
+
+ @Schema(description = "回收时间(不传则取当前时间)")
+ private Date returnTime;
+
+ @Schema(description = "回收照片URL列表(前端上传后回传)")
+ private List photoUrls;
+
+ @Schema(description = "备注")
+ private String remark;
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcAllocStatus.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcAllocStatus.java
new file mode 100644
index 00000000..594e1788
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcAllocStatus.java
@@ -0,0 +1,7 @@
+package com.admin.property.enums;
+
+public interface PcAllocStatus {
+ String ALLOCATED = "1";
+ String RETURN_SUBMITTED = "2";
+ String INBOUND_DONE = "3";
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcAuditStatus.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcAuditStatus.java
new file mode 100644
index 00000000..4038fbd2
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcAuditStatus.java
@@ -0,0 +1,10 @@
+package com.admin.property.enums;
+
+public interface PcAuditStatus {
+ /** 0待入库审核 */
+ String PENDING = "0";
+ /** 1已通过 */
+ String APPROVED = "1";
+ /** 2已驳回 */
+ String REJECTED = "2";
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcCameraStatus.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcCameraStatus.java
new file mode 100644
index 00000000..fdce4402
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/enums/PcCameraStatus.java
@@ -0,0 +1,14 @@
+package com.admin.property.enums;
+
+public interface PcCameraStatus {
+
+ /** 台账 status:0在库 */
+ String IN_STOCK = "0";
+ /** 台账 status:1已分配 */
+ String ALLOCATED = "1";
+ /** 台账 status:2已回收待入库 */
+ String RETURNED_PENDING_INBOUND = "2";
+ /** 台账 status:3已入库(等同在库,可按你业务区分) */
+ String INBOUNDED = "3";
+
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraAllocMapper.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraAllocMapper.java
new file mode 100644
index 00000000..d87f1133
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraAllocMapper.java
@@ -0,0 +1,26 @@
+package com.admin.property.mapper;
+
+import com.admin.property.domain.PcCameraAlloc;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+@Mapper
+public interface PcCameraAllocMapper {
+
+ List selectAllocListByProjectId(@Param("projectId") Long projectId);
+
+ /** 高风险项目分配页:项目列表(带过滤) */
+ List selectRiskProjectAllocList(PcCameraAlloc query);
+
+ int insertBatch(@Param("list") List list);
+
+ int updateAllocStatusByProject(@Param("projectId") Long projectId, @Param("allocStatus") String allocStatus);
+
+ PcCameraAlloc selectActiveAlloc(@Param("projectId") Long projectId, @Param("cameraId") Long cameraId);
+
+ List selectAllocatedByProject(@Param("projectId") Long projectId);
+
+ int updateAllocStatusByIds(@Param("allocIds") List allocIds, @Param("allocStatus") String allocStatus);
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraInboundMapper.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraInboundMapper.java
new file mode 100644
index 00000000..4d18b377
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraInboundMapper.java
@@ -0,0 +1,12 @@
+package com.admin.property.mapper;
+
+import com.admin.property.domain.PcCameraInbound;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+@Mapper
+public interface PcCameraInboundMapper {
+ int insertBatch(@Param("list") List list);
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraLedgerMapper.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraLedgerMapper.java
new file mode 100644
index 00000000..c9ad394f
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraLedgerMapper.java
@@ -0,0 +1,35 @@
+package com.admin.property.mapper;
+
+import com.admin.property.domain.PcCameraLedger;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+@Mapper
+public interface PcCameraLedgerMapper {
+
+ PcCameraLedger selectPcCameraLedgerByCameraId(@Param("cameraId") Long cameraId);
+
+ List selectPcCameraLedgerList(PcCameraLedger query);
+
+ /** 精确按编号查(导入更新用,避免 like) */
+ PcCameraLedger selectByCameraNo(@Param("cameraNo") String cameraNo);
+
+ /** 可分配球机列表(status=0或3) */
+ List selectAvailableCameraList(PcCameraLedger query);
+
+ int insertPcCameraLedger(PcCameraLedger entity);
+
+ int updatePcCameraLedger(PcCameraLedger entity);
+
+ int deletePcCameraLedgerByCameraIds(@Param("cameraIds") Long[] cameraIds);
+
+ int updateStatusIfMatch(@Param("cameraId") Long cameraId,
+ @Param("fromStatus") String fromStatus,
+ @Param("toStatus") String toStatus);
+
+ int updateStatus(@Param("cameraId") Long cameraId, @Param("toStatus") String toStatus);
+
+ List selectByIds(@Param("cameraIds") List cameraIds);
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraReturnMapper.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraReturnMapper.java
new file mode 100644
index 00000000..427de08f
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcCameraReturnMapper.java
@@ -0,0 +1,29 @@
+package com.admin.property.mapper;
+
+import com.admin.property.domain.PcCameraReturn;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+@Mapper
+public interface PcCameraReturnMapper {
+
+ /** 回收入库页:待回收/已回收待入库/已入库等列表(你可按 audit_status + 台账status组合筛选) */
+ List selectReturnList(PcCameraReturn query);
+
+ /** 入库审核列表:audit_status=0 */
+ List selectAuditPendingList(PcCameraReturn query);
+
+ int insertBatch(@Param("list") List list);
+
+ PcCameraReturn selectById(@Param("returnId") Long returnId);
+
+ List selectByIds(@Param("returnIds") List returnIds);
+
+ int updateAuditStatus(@Param("returnIds") List returnIds,
+ @Param("auditStatus") String auditStatus,
+ @Param("auditBy") String auditBy,
+ @Param("auditTime") java.util.Date auditTime,
+ @Param("auditRemark") String auditRemark);
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcRiskProjectMapper.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcRiskProjectMapper.java
new file mode 100644
index 00000000..79d6610b
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcRiskProjectMapper.java
@@ -0,0 +1,34 @@
+package com.admin.property.mapper;
+
+import com.admin.property.domain.PcRiskProject;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+@Mapper
+public interface PcRiskProjectMapper {
+
+ PcRiskProject selectPcRiskProjectById(@Param("projectId") Long projectId);
+
+ List selectPcRiskProjectList(PcRiskProject query);
+
+ int insertPcRiskProject(PcRiskProject entity);
+
+ int updatePcRiskProject(PcRiskProject entity);
+
+ int deletePcRiskProjectByIds(@Param("projectIds") Long[] projectIds);
+
+ int updateAllocStatus(@Param("projectId") Long projectId,
+ @Param("allocStatus") String allocStatus);
+
+ /** 完工复核管理列表 */
+ List selectProjectCompletionReviewList(PcRiskProject query);
+
+ /** 更新复核/审核/归档相关状态(包含监理复核状态) */
+ int updateProjectStatus(PcRiskProject entity);
+
+ /** 仅更新监理复核状态(如果监理系统回写用得到,可选) */
+ int updateSupervisionReviewStatus(@Param("projectId") Long projectId,
+ @Param("supervisionReviewStatus") String supervisionReviewStatus);
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcUnitArchiveMapper.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcUnitArchiveMapper.java
new file mode 100644
index 00000000..5a53142e
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/mapper/PcUnitArchiveMapper.java
@@ -0,0 +1,24 @@
+package com.admin.property.mapper;
+
+import com.admin.property.domain.PcUnitArchive;
+import org.apache.ibatis.annotations.Mapper;
+
+import java.util.List;
+
+@Mapper
+public interface PcUnitArchiveMapper {
+
+ PcUnitArchive selectPcUnitArchiveByUnitId(Long unitId);
+
+ List selectPcUnitArchiveList(PcUnitArchive pcUnitArchive);
+
+ int insertPcUnitArchive(PcUnitArchive pcUnitArchive);
+
+ int updatePcUnitArchive(PcUnitArchive pcUnitArchive);
+
+ int deletePcUnitArchiveByUnitId(Long unitId);
+
+ int deletePcUnitArchiveByUnitIds(Long[] unitIds);
+
+ int updatePcUnitArchiveStatus(Long unitId, String status);
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcCameraBizService.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcCameraBizService.java
new file mode 100644
index 00000000..1e8897ed
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcCameraBizService.java
@@ -0,0 +1,37 @@
+package com.admin.property.service;
+
+import com.admin.property.domain.PcCameraLedger;
+import com.admin.property.domain.PcCameraAlloc;
+import com.admin.property.domain.PcCameraReturn;
+import com.admin.property.domain.dto.PcCameraAllocConfirmDTO;
+import com.admin.property.domain.dto.PcCameraInboundAuditDTO;
+import com.admin.property.domain.dto.PcCameraReturnSubmitDTO;
+
+import java.util.List;
+
+public interface IPcCameraBizService {
+
+ /** 可分配球机列表 */
+ List selectAvailableCameras(PcCameraLedger query);
+
+ /** 项目分配详情 */
+ List selectAllocListByProjectId(Long projectId);
+
+ /** 确认分配(项目 -> 多台球机) */
+ int confirmAllocate(PcCameraAllocConfirmDTO dto);
+
+ /** 回收列表/回收记录列表 */
+ List selectReturnList(PcCameraReturn query);
+
+ /** 入库审核列表(待审核) */
+ List selectAuditPendingList(PcCameraReturn query);
+
+ /** 回收确认提交(项目 -> 多台球机) */
+ int submitReturn(PcCameraReturnSubmitDTO dto);
+
+ /** 入库审核通过(确认入库) */
+ int approveInbound(PcCameraInboundAuditDTO dto);
+
+ /** 入库审核驳回 */
+ int rejectInbound(PcCameraInboundAuditDTO dto);
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcCameraLedgerService.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcCameraLedgerService.java
new file mode 100644
index 00000000..a5be7129
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcCameraLedgerService.java
@@ -0,0 +1,22 @@
+package com.admin.property.service;
+
+import com.admin.property.domain.PcCameraLedger;
+
+import java.util.List;
+
+public interface IPcCameraLedgerService {
+
+ PcCameraLedger selectPcCameraLedgerByCameraId(Long cameraId);
+
+ List selectPcCameraLedgerList(PcCameraLedger pcCameraLedger);
+
+ int insertPcCameraLedger(PcCameraLedger pcCameraLedger);
+
+ int updatePcCameraLedger(PcCameraLedger pcCameraLedger);
+
+ int deletePcCameraLedgerByCameraIds(Long[] cameraIds);
+
+ int changeStatus(Long cameraId, String status);
+
+ String importData(List list, boolean updateSupport, String operName);
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcRiskProjectService.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcRiskProjectService.java
new file mode 100644
index 00000000..b534ce97
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcRiskProjectService.java
@@ -0,0 +1,29 @@
+package com.admin.property.service;
+
+import com.admin.property.domain.PcRiskProject;
+
+import java.util.List;
+
+public interface IPcRiskProjectService {
+
+ PcRiskProject selectPcRiskProjectById(Long projectId);
+
+ List selectPcRiskProjectList(PcRiskProject project);
+
+ int updatePcRiskProject(Long projectId, PcRiskProject project);
+
+ int deletePcRiskProjectByIds(Long[] projectIds);
+
+
+ public List selectProjectCompletionReviewList(PcRiskProject pcRiskProject);
+
+ public int onSiteReview( Long projectId,
+ String onSiteReviewStatus,
+ String onSiteReviewImages,
+ Integer workContentCompleteRate,
+ String siteCleaningCondition,
+ String reviewComments);
+
+ public int finalAudit(Long projectId);
+
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcUnitArchiveService.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcUnitArchiveService.java
new file mode 100644
index 00000000..4c7b9e33
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/IPcUnitArchiveService.java
@@ -0,0 +1,21 @@
+package com.admin.property.service;
+
+
+import com.admin.property.domain.PcUnitArchive;
+
+import java.util.List;
+
+public interface IPcUnitArchiveService {
+
+ PcUnitArchive selectPcUnitArchiveByUnitId(Long unitId);
+
+ List selectPcUnitArchiveList(PcUnitArchive pcUnitArchive);
+
+ int insertPcUnitArchive(PcUnitArchive pcUnitArchive);
+
+ int updatePcUnitArchive(PcUnitArchive pcUnitArchive);
+
+ int deletePcUnitArchiveByUnitIds(Long[] unitIds);
+
+ int changeStatus(Long unitId, String status);
+}
\ No newline at end of file
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcCameraBizServiceImpl.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcCameraBizServiceImpl.java
new file mode 100644
index 00000000..29fccf48
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcCameraBizServiceImpl.java
@@ -0,0 +1,264 @@
+package com.admin.property.service.impl;
+
+import com.admin.property.domain.*;
+import com.admin.property.enums.PcCameraStatus;
+import com.admin.property.mapper.*;
+import com.ruoyi.common.core.exception.ServiceException;
+import com.admin.property.domain.dto.PcCameraAllocConfirmDTO;
+import com.admin.property.domain.dto.PcCameraInboundAuditDTO;
+import com.admin.property.domain.dto.PcCameraReturnSubmitDTO;
+import com.admin.property.enums.PcAllocStatus;
+import com.admin.property.enums.PcAuditStatus;
+import com.admin.property.service.IPcCameraBizService;
+import com.ruoyi.common.security.utils.SecurityUtils;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.*;
+import java.util.stream.Collectors;
+
+@Service
+public class PcCameraBizServiceImpl implements IPcCameraBizService {
+
+ private final PcRiskProjectMapper projectMapper;
+ private final PcCameraLedgerMapper ledgerMapper;
+ private final PcCameraAllocMapper allocMapper;
+ private final PcCameraReturnMapper returnMapper;
+ private final PcCameraInboundMapper inboundMapper;
+
+ public PcCameraBizServiceImpl(PcRiskProjectMapper projectMapper,
+ PcCameraLedgerMapper ledgerMapper,
+ PcCameraAllocMapper allocMapper,
+ PcCameraReturnMapper returnMapper,
+ PcCameraInboundMapper inboundMapper) {
+ this.projectMapper = projectMapper;
+ this.ledgerMapper = ledgerMapper;
+ this.allocMapper = allocMapper;
+ this.returnMapper = returnMapper;
+ this.inboundMapper = inboundMapper;
+ }
+
+ @Override
+ public List selectAvailableCameras(PcCameraLedger query) {
+ return ledgerMapper.selectAvailableCameraList(query);
+ }
+
+ @Override
+ public List selectAllocListByProjectId(Long projectId) {
+ return allocMapper.selectAllocListByProjectId(projectId);
+ }
+
+ /** ① 确认分配 */
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int confirmAllocate(PcCameraAllocConfirmDTO dto) {
+ if (dto.getProjectId() == null) throw new ServiceException("projectId不能为空");
+ if (dto.getCameraIds() == null || dto.getCameraIds().isEmpty()) throw new ServiceException("cameraIds不能为空");
+
+ PcRiskProject project = projectMapper.selectPcRiskProjectById(dto.getProjectId());
+ if (project == null) throw new ServiceException("项目不存在或已删除");
+
+ Date allocTime = dto.getAllocTime() != null ? dto.getAllocTime() : new Date();
+ String username = SecurityUtils.getUsername();
+
+ // 校验球机是否可分配 + 状态更新(在库->已分配)
+ List cameraIds = dto.getCameraIds().stream().distinct().collect(Collectors.toList());
+
+ // 先查一次,避免前端传错ID
+ List ledgers = ledgerMapper.selectByIds(cameraIds);
+ if (ledgers.size() != cameraIds.size()) throw new ServiceException("存在无效的球机ID");
+
+ // 逐个乐观更新,避免并发重复分配
+ for (Long cameraId : cameraIds) {
+ int ok0 = ledgerMapper.updateStatusIfMatch(cameraId, PcCameraStatus.IN_STOCK, PcCameraStatus.ALLOCATED);
+ int ok3 = 0;
+ if (ok0 == 0) {
+ ok3 = ledgerMapper.updateStatusIfMatch(cameraId, PcCameraStatus.INBOUNDED, PcCameraStatus.ALLOCATED);
+ }
+ if (ok0 == 0 && ok3 == 0) {
+ PcCameraLedger one = ledgerMapper.selectPcCameraLedgerByCameraId(cameraId);
+ throw new ServiceException("球机不可分配,编号=" + (one != null ? one.getCameraNo() : cameraId) + ",当前状态=" + (one != null ? one.getStatus() : "未知"));
+ }
+ }
+
+ // 写入分配记录(每台一条)
+ List inserts = new ArrayList<>();
+ for (Long cameraId : cameraIds) {
+ // 防重复(同项目同球机唯一键也能兜底)
+ PcCameraAlloc exists = allocMapper.selectActiveAlloc(dto.getProjectId(), cameraId);
+ if (exists != null) throw new ServiceException("重复分配:项目已存在该球机记录,cameraId=" + cameraId);
+
+ PcCameraAlloc a = new PcCameraAlloc();
+ a.setProjectId(dto.getProjectId());
+ a.setCameraId(cameraId);
+ a.setAllocTime(allocTime);
+ a.setAllocBy(username);
+ a.setAllocNote(dto.getAllocNote());
+ a.setAllocStatus(PcAllocStatus.ALLOCATED);
+ a.setCreateBy(username);
+ a.setUpdateBy(username);
+ inserts.add(a);
+ }
+ int rows = allocMapper.insertBatch(inserts);
+
+ // 如果已满足需分配数量,则项目状态置为已分配(你也可以改成“分配中/部分分配”)
+ int allocatedCount = allocMapper.selectAllocatedByProject(dto.getProjectId()).size();
+ int need = project.getNeedCameraCnt() == null ? 0 : project.getNeedCameraCnt();
+ if (need > 0 && allocatedCount >= need) {
+ projectMapper.updateAllocStatus(dto.getProjectId(), "1");
+ } else {
+ projectMapper.updateAllocStatus(dto.getProjectId(), "0");
+ }
+ return rows;
+ }
+
+ @Override
+ public List selectReturnList(PcCameraReturn query) {
+ return returnMapper.selectReturnList(query);
+ }
+
+ @Override
+ public List selectAuditPendingList(PcCameraReturn query) {
+ return returnMapper.selectAuditPendingList(query);
+ }
+
+ /** ② 回收确认提交(项目->多台球机) */
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int submitReturn(PcCameraReturnSubmitDTO dto) {
+ if (dto.getProjectId() == null) throw new ServiceException("projectId不能为空");
+ if (dto.getCameraIds() == null || dto.getCameraIds().isEmpty()) throw new ServiceException("cameraIds不能为空");
+ if (dto.getCheckResult() == null || dto.getCheckResult().isEmpty()) throw new ServiceException("checkResult不能为空");
+
+ String username = SecurityUtils.getUsername();
+ Date returnTime = dto.getReturnTime() != null ? dto.getReturnTime() : new Date();
+ String photoUrls = (dto.getPhotoUrls() == null || dto.getPhotoUrls().isEmpty())
+ ? null
+ : String.join(",", dto.getPhotoUrls());
+
+ List cameraIds = dto.getCameraIds().stream().distinct().collect(Collectors.toList());
+
+ // 找到对应的 alloc 记录(必须是已分配状态)
+ List allocated = allocMapper.selectAllocatedByProject(dto.getProjectId());
+ Map allocByCamera = allocated.stream()
+ .collect(Collectors.toMap(PcCameraAlloc::getCameraId, x -> x, (a,b)->a));
+
+ for (Long cameraId : cameraIds) {
+ if (!allocByCamera.containsKey(cameraId)) {
+ throw new ServiceException("该球机不属于该项目的“已分配”状态,cameraId=" + cameraId);
+ }
+ }
+
+ // 更新台账状态:已分配 -> 已回收待入库
+ for (Long cameraId : cameraIds) {
+ int ok = ledgerMapper.updateStatusIfMatch(cameraId, PcCameraStatus.ALLOCATED, PcCameraStatus.RETURNED_PENDING_INBOUND);
+ if (ok == 0) {
+ PcCameraLedger one = ledgerMapper.selectPcCameraLedgerByCameraId(cameraId);
+ throw new ServiceException("回收失败,球机状态不匹配,编号=" + (one != null ? one.getCameraNo() : cameraId));
+ }
+ }
+
+ // 更新 alloc 状态:1 -> 2
+ List allocIds = cameraIds.stream().map(id -> allocByCamera.get(id).getAllocId()).collect(Collectors.toList());
+ allocMapper.updateAllocStatusByIds(allocIds, PcAllocStatus.RETURN_SUBMITTED);
+
+ // 插入回收记录(每台一条)
+ List inserts = new ArrayList<>();
+ for (Long cameraId : cameraIds) {
+ PcCameraAlloc a = allocByCamera.get(cameraId);
+ PcCameraReturn r = new PcCameraReturn();
+ r.setAllocId(a.getAllocId());
+ r.setProjectId(dto.getProjectId());
+ r.setCameraId(cameraId);
+ r.setCheckResult(dto.getCheckResult());
+ r.setReturnBy(username);
+ r.setReturnTime(returnTime);
+ r.setPhotoUrls(photoUrls);
+ r.setRemark(dto.getRemark());
+ r.setAuditStatus(PcAuditStatus.PENDING);
+ r.setCreateBy(username);
+ r.setUpdateBy(username);
+ inserts.add(r);
+ }
+ return returnMapper.insertBatch(inserts);
+ }
+
+ /** ③ 入库审核通过(确认入库) */
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int approveInbound(PcCameraInboundAuditDTO dto) {
+ if (dto.getReturnIds() == null || dto.getReturnIds().isEmpty()) throw new ServiceException("returnIds不能为空");
+ if (dto.getWarehouse() == null || dto.getWarehouse().isEmpty()) throw new ServiceException("warehouse不能为空(通过时必填)");
+
+ String username = SecurityUtils.getUsername();
+ String keeper = (dto.getKeeper() == null || dto.getKeeper().isEmpty()) ? username : dto.getKeeper();
+ Date inboundTime = dto.getInboundTime() != null ? dto.getInboundTime() : new Date();
+
+ List returns = returnMapper.selectByIds(dto.getReturnIds());
+ if (returns.size() != dto.getReturnIds().size()) throw new ServiceException("存在无效returnId");
+ for (PcCameraReturn r : returns) {
+ if (!PcAuditStatus.PENDING.equals(r.getAuditStatus())) {
+ throw new ServiceException("仅允许审核“待入库审核”的记录,returnId=" + r.getReturnId());
+ }
+ }
+
+ // 1) 回收记录置为通过
+ int rows = returnMapper.updateAuditStatus(dto.getReturnIds(), PcAuditStatus.APPROVED, username, new Date(), dto.getAuditRemark());
+
+ // 2) 台账状态:2已回收待入库 -> 3已入库(或0在库)
+ for (PcCameraReturn r : returns) {
+ int ok = ledgerMapper.updateStatusIfMatch(r.getCameraId(), PcCameraStatus.RETURNED_PENDING_INBOUND, PcCameraStatus.INBOUNDED);
+ if (ok == 0) {
+ PcCameraLedger one = ledgerMapper.selectPcCameraLedgerByCameraId(r.getCameraId());
+ throw new ServiceException("入库失败,球机状态不匹配,编号=" + (one != null ? one.getCameraNo() : r.getCameraId()));
+ }
+ }
+
+ // 3) 分配记录状态:2 -> 3
+ List allocIds = returns.stream().map(PcCameraReturn::getAllocId).collect(Collectors.toList());
+ allocMapper.updateAllocStatusByIds(allocIds, PcAllocStatus.INBOUND_DONE);
+
+ // 4) 写入入库记录
+ List inboundList = new ArrayList<>();
+ for (PcCameraReturn r : returns) {
+ PcCameraInbound in = new PcCameraInbound();
+ in.setReturnId(r.getReturnId());
+ in.setCameraId(r.getCameraId());
+ in.setWarehouse(dto.getWarehouse());
+ in.setKeeper(keeper);
+ in.setInboundTime(inboundTime);
+ in.setRemark(dto.getAuditRemark());
+ in.setCreateBy(username);
+ inboundList.add(in);
+
+ // 可选:同步台账的仓库字段
+ PcCameraLedger ledger = new PcCameraLedger();
+ ledger.setCameraId(r.getCameraId());
+ ledger.setWarehouse(dto.getWarehouse());
+ ledger.setUpdateBy(username);
+ ledgerMapper.updatePcCameraLedger(ledger);
+ }
+ inboundMapper.insertBatch(inboundList);
+
+ return rows;
+ }
+
+ /** ④ 入库审核驳回 */
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int rejectInbound(PcCameraInboundAuditDTO dto) {
+ if (dto.getReturnIds() == null || dto.getReturnIds().isEmpty()) throw new ServiceException("returnIds不能为空");
+ String username = SecurityUtils.getUsername();
+
+ List returns = returnMapper.selectByIds(dto.getReturnIds());
+ if (returns.size() != dto.getReturnIds().size()) throw new ServiceException("存在无效returnId");
+ for (PcCameraReturn r : returns) {
+ if (!PcAuditStatus.PENDING.equals(r.getAuditStatus())) {
+ throw new ServiceException("仅允许驳回“待入库审核”的记录,returnId=" + r.getReturnId());
+ }
+ }
+
+ // 驳回只改变回收记录状态;台账仍保持“已回收待入库”,方便修改后重新提交/重新审核
+ return returnMapper.updateAuditStatus(dto.getReturnIds(), PcAuditStatus.REJECTED, username, new Date(), dto.getAuditRemark());
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcCameraLedgerServiceImpl.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcCameraLedgerServiceImpl.java
new file mode 100644
index 00000000..809a1aef
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcCameraLedgerServiceImpl.java
@@ -0,0 +1,110 @@
+package com.admin.property.service.impl;
+
+import com.admin.property.service.IPcCameraLedgerService;
+import com.ruoyi.common.core.exception.ServiceException;
+import com.ruoyi.common.core.utils.StringUtils;
+import com.admin.property.domain.PcCameraLedger;
+import com.admin.property.mapper.PcCameraLedgerMapper;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.List;
+
+@Service
+public class PcCameraLedgerServiceImpl implements IPcCameraLedgerService {
+
+ private final PcCameraLedgerMapper pcCameraLedgerMapper;
+
+ public PcCameraLedgerServiceImpl(PcCameraLedgerMapper pcCameraLedgerMapper) {
+ this.pcCameraLedgerMapper = pcCameraLedgerMapper;
+ }
+
+ @Override
+ public PcCameraLedger selectPcCameraLedgerByCameraId(Long cameraId) {
+ return pcCameraLedgerMapper.selectPcCameraLedgerByCameraId(cameraId);
+ }
+
+ @Override
+ public List selectPcCameraLedgerList(PcCameraLedger pcCameraLedger) {
+ return pcCameraLedgerMapper.selectPcCameraLedgerList(pcCameraLedger);
+ }
+
+ @Override
+ public int insertPcCameraLedger(PcCameraLedger pcCameraLedger) {
+ if (StringUtils.isEmpty(pcCameraLedger.getDelFlag())) {
+ pcCameraLedger.setDelFlag("0");
+ }
+ if (StringUtils.isEmpty(pcCameraLedger.getStatus())) {
+ pcCameraLedger.setStatus("0");
+ }
+ return pcCameraLedgerMapper.insertPcCameraLedger(pcCameraLedger);
+ }
+
+ @Override
+ public int updatePcCameraLedger(PcCameraLedger pcCameraLedger) {
+ return pcCameraLedgerMapper.updatePcCameraLedger(pcCameraLedger);
+ }
+
+ @Override
+ public int deletePcCameraLedgerByCameraIds(Long[] cameraIds) {
+ return pcCameraLedgerMapper.deletePcCameraLedgerByCameraIds(cameraIds);
+ }
+
+ @Override
+ public int changeStatus(Long cameraId, String status) {
+ return pcCameraLedgerMapper.updateStatus(cameraId, status);
+ }
+
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public String importData(List list, boolean updateSupport, String operName) {
+ if (list == null || list.isEmpty()) {
+ throw new ServiceException("导入数据不能为空");
+ }
+
+ int success = 0;
+ int fail = 0;
+ StringBuilder sb = new StringBuilder();
+
+ for (PcCameraLedger item : list) {
+ try {
+ if (StringUtils.isEmpty(item.getCameraNo())) {
+ fail++;
+ sb.append("
球机编号为空,跳过");
+ continue;
+ }
+
+ // 默认值
+ if (StringUtils.isEmpty(item.getDelFlag())) {
+ item.setDelFlag("0");
+ }
+ if (StringUtils.isEmpty(item.getStatus())) {
+ item.setStatus("0");
+ }
+
+ item.setCreateBy(operName);
+ item.setUpdateBy(operName);
+
+ PcCameraLedger exists = pcCameraLedgerMapper.selectByCameraNo(item.getCameraNo());
+
+ if (exists == null) {
+ pcCameraLedgerMapper.insertPcCameraLedger(item);
+ success++;
+ } else if (updateSupport) {
+ item.setCameraId(exists.getCameraId());
+ pcCameraLedgerMapper.updatePcCameraLedger(item);
+ success++;
+ } else {
+ fail++;
+ sb.append("
球机编号 ").append(item.getCameraNo()).append(" 已存在");
+ }
+ } catch (Exception e) {
+ fail++;
+ sb.append("
球机编号 ").append(item.getCameraNo()).append(" 导入失败:").append(e.getMessage());
+ }
+ }
+
+ sb.insert(0, "导入完成:成功 " + success + " 条,失败 " + fail + " 条。");
+ return sb.toString();
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcRiskProjectServiceImpl.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcRiskProjectServiceImpl.java
new file mode 100644
index 00000000..f8d053c8
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcRiskProjectServiceImpl.java
@@ -0,0 +1,105 @@
+package com.admin.property.service.impl;
+
+import com.ruoyi.common.core.exception.ServiceException;
+import com.admin.property.domain.PcRiskProject;
+import com.admin.property.mapper.PcRiskProjectMapper;
+import com.admin.property.service.IPcRiskProjectService;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.List;
+
+@Service
+public class PcRiskProjectServiceImpl implements IPcRiskProjectService {
+
+ private final PcRiskProjectMapper pcRiskProjectMapper;
+
+ public PcRiskProjectServiceImpl(PcRiskProjectMapper pcRiskProjectMapper) {
+ this.pcRiskProjectMapper = pcRiskProjectMapper;
+ }
+
+ @Override
+ public PcRiskProject selectPcRiskProjectById(Long projectId) {
+ return pcRiskProjectMapper.selectPcRiskProjectById(projectId);
+ }
+
+ @Override
+ public List selectPcRiskProjectList(PcRiskProject project) {
+ return pcRiskProjectMapper.selectPcRiskProjectList(project);
+ }
+
+ @Override
+ @Transactional
+ public int updatePcRiskProject(Long projectId, PcRiskProject project) {
+ project.setProjectId(projectId);
+ return pcRiskProjectMapper.updatePcRiskProject(project);
+ }
+
+ @Override
+ @Transactional
+ public int deletePcRiskProjectByIds(Long[] projectIds) {
+ return pcRiskProjectMapper.deletePcRiskProjectByIds(projectIds);
+ }
+
+
+ @Override
+ public List selectProjectCompletionReviewList(PcRiskProject pcRiskProject) {
+ return pcRiskProjectMapper.selectProjectCompletionReviewList(pcRiskProject);
+ }
+
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int onSiteReview(Long projectId,
+ String onSiteReviewStatus,
+ String onSiteReviewImages,
+ Integer workContentCompleteRate,
+ String siteCleaningCondition,
+ String reviewComments) {
+ // 查询项目
+ PcRiskProject project = pcRiskProjectMapper.selectPcRiskProjectById(projectId);
+ if (project == null) {
+ throw new ServiceException("项目不存在");
+ }
+
+ // 检查监理复核状态,确保复核通过才能进行现场复核
+ if (!"复核通过".equals(project.getSupervisionReviewStatus())) {
+ throw new ServiceException("监理复核未通过,无法进行现场复核");
+ }
+
+ // 更新现场复核状态
+ project.setOnSiteReviewStatus(onSiteReviewStatus);
+
+ // 设置其他复核字段
+ project.setOnSiteReviewImages(onSiteReviewImages); // 现场复核图片(URL数组)
+ project.setWorkContentCompleteRate(workContentCompleteRate); // 作业内容完成度
+ project.setSiteCleaningCondition(siteCleaningCondition); // 现场清理情况
+ project.setReviewComments(reviewComments); // 复核意见
+
+ // 设置为待最终审核状态
+ if ("已复核".equals(onSiteReviewStatus)) {
+ project.setFinalAuditStatus("待审核"); // 设置为待最终审核
+ }
+
+ // 更新项目状态
+ return pcRiskProjectMapper.updateProjectStatus(project);
+ }
+
+ @Override
+ @Transactional(rollbackFor = Exception.class)
+ public int finalAudit(Long projectId) {
+ PcRiskProject project = pcRiskProjectMapper.selectPcRiskProjectById(projectId);
+ if (project == null || !"已复核".equals(project.getOnSiteReviewStatus())) {
+ throw new ServiceException("现场复核未完成,无法进行最终审核");
+ }
+
+ // 更新项目为已完成审核
+ project.setFinalAuditStatus("已审核");
+
+ // 标记项目为已完成并归档
+ project.setProjectStatus("已完成审核");
+
+ return pcRiskProjectMapper.updateProjectStatus(project);
+ }
+
+
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcUnitArchiveServiceImpl.java b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcUnitArchiveServiceImpl.java
new file mode 100644
index 00000000..aa2e8f6a
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/java/com/admin/property/service/impl/PcUnitArchiveServiceImpl.java
@@ -0,0 +1,57 @@
+package com.admin.property.service.impl;
+
+import java.util.List;
+
+import com.admin.property.service.IPcUnitArchiveService;
+import com.admin.property.domain.PcUnitArchive;
+import com.admin.property.mapper.PcUnitArchiveMapper;
+import org.springframework.stereotype.Service;
+import org.springframework.util.StringUtils;
+
+
+@Service
+public class PcUnitArchiveServiceImpl implements IPcUnitArchiveService {
+
+ private final PcUnitArchiveMapper pcUnitArchiveMapper;
+
+ public PcUnitArchiveServiceImpl(PcUnitArchiveMapper pcUnitArchiveMapper) {
+ this.pcUnitArchiveMapper = pcUnitArchiveMapper;
+ }
+
+ @Override
+ public PcUnitArchive selectPcUnitArchiveByUnitId(Long unitId) {
+ return pcUnitArchiveMapper.selectPcUnitArchiveByUnitId(unitId);
+ }
+
+ @Override
+ public List selectPcUnitArchiveList(PcUnitArchive pcUnitArchive) {
+ return pcUnitArchiveMapper.selectPcUnitArchiveList(pcUnitArchive);
+ }
+
+ @Override
+ public int insertPcUnitArchive(PcUnitArchive pcUnitArchive) {
+ // 默认:已建档 + 启用(你也可以由前端传 archiveStatus 实现“暂存草稿/保存建档”)
+ if (!StringUtils.hasText(pcUnitArchive.getArchiveStatus())) {
+ pcUnitArchive.setArchiveStatus("1");
+ }
+ if (!StringUtils.hasText(pcUnitArchive.getStatus())) {
+ pcUnitArchive.setStatus("0");
+ }
+ return pcUnitArchiveMapper.insertPcUnitArchive(pcUnitArchive);
+ }
+
+ @Override
+ public int updatePcUnitArchive(PcUnitArchive pcUnitArchive) {
+ return pcUnitArchiveMapper.updatePcUnitArchive(pcUnitArchive);
+ }
+
+ @Override
+ public int deletePcUnitArchiveByUnitIds(Long[] unitIds) {
+ return pcUnitArchiveMapper.deletePcUnitArchiveByUnitIds(unitIds);
+ }
+
+ @Override
+ public int changeStatus(Long unitId, String status) {
+ return pcUnitArchiveMapper.updatePcUnitArchiveStatus(unitId, status);
+ }
+}
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/bootstrap.yml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/bootstrap.yml
new file mode 100644
index 00000000..5c46f5ab
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/bootstrap.yml
@@ -0,0 +1,26 @@
+# Tomcat
+server:
+ port: 9208
+
+# Spring
+spring:
+ application:
+ # 应用名称
+ name: ruoyi-property
+ profiles:
+ # 环境配置
+ active: dev
+ cloud:
+ nacos:
+ discovery:
+ # 服务注册地址
+ server-addr: 127.0.0.1:8848
+ config:
+ # 配置中心地址
+ server-addr: 127.0.0.1:8848
+ # 配置文件格式
+ file-extension: yml
+ # 共享配置
+ shared-configs:
+ - application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/logback.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/logback.xml
new file mode 100644
index 00000000..b16ac7fa
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/logback.xml
@@ -0,0 +1,75 @@
+
+
+
+
+
+
+
+
+
+
+ ${log.pattern}
+
+
+
+
+
+ ${log.path}/info.log
+
+
+
+ ${log.path}/info.%d{yyyy-MM-dd}.log
+
+ 60
+
+
+ ${log.pattern}
+
+
+
+ INFO
+
+ ACCEPT
+
+ DENY
+
+
+
+
+ ${log.path}/error.log
+
+
+
+ ${log.path}/error.%d{yyyy-MM-dd}.log
+
+ 60
+
+
+ ${log.pattern}
+
+
+
+ ERROR
+
+ ACCEPT
+
+ DENY
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraAllocMapper.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraAllocMapper.xml
new file mode 100644
index 00000000..8c7c4738
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraAllocMapper.xml
@@ -0,0 +1,89 @@
+
+
+
+
+
+
+
+
+
+
+
+ insert into pc_camera_alloc(project_id, camera_id, alloc_time, alloc_by, alloc_note, alloc_status, del_flag, create_by, create_time, update_by, update_time)
+ values
+
+ (#{it.projectId}, #{it.cameraId}, #{it.allocTime}, #{it.allocBy}, #{it.allocNote}, #{it.allocStatus}, '0', #{it.createBy}, now(), #{it.updateBy}, now())
+
+
+
+
+ update pc_camera_alloc
+ set alloc_status=#{allocStatus}, update_time=now()
+ where del_flag='0' and project_id=#{projectId}
+
+
+
+
+
+
+
+ update pc_camera_alloc
+ set alloc_status=#{allocStatus}, update_time=now()
+ where del_flag='0' and alloc_id in
+
+ #{id}
+
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraInboundMapper.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraInboundMapper.xml
new file mode 100644
index 00000000..5472a836
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraInboundMapper.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+ insert into pc_camera_inbound(return_id, camera_id, warehouse, keeper, inbound_time, remark, create_by, create_time)
+ values
+
+ (#{it.returnId}, #{it.cameraId}, #{it.warehouse}, #{it.keeper}, #{it.inboundTime}, #{it.remark}, #{it.createBy}, now())
+
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraLedgerMapper.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraLedgerMapper.xml
new file mode 100644
index 00000000..b61465f2
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraLedgerMapper.xml
@@ -0,0 +1,137 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ insert into pc_camera_ledger
+ (camera_no, model, status, owner_unit, warehouse, remark, del_flag, create_by, create_time, update_by, update_time)
+ values
+ (#{cameraNo}, #{model}, #{status}, #{ownerUnit}, #{warehouse}, #{remark}, '0', #{createBy}, now(), #{updateBy}, now())
+
+
+
+ update pc_camera_ledger
+ set camera_no=#{cameraNo},
+ model=#{model},
+ status=#{status},
+ owner_unit=#{ownerUnit},
+ warehouse=#{warehouse},
+ remark=#{remark},
+ update_by=#{updateBy},
+ update_time=now()
+ where camera_id=#{cameraId}
+ and del_flag='0'
+
+
+
+ update pc_camera_ledger
+ set del_flag='2',
+ update_time=now()
+ where camera_id in
+
+ #{id}
+
+ and del_flag='0'
+
+
+
+ update pc_camera_ledger
+ set status = #{toStatus},
+ update_time = now()
+ where camera_id = #{cameraId}
+ and del_flag='0'
+ and status = #{fromStatus}
+
+
+
+ update pc_camera_ledger
+ set status = #{toStatus},
+ update_time=now()
+ where camera_id = #{cameraId}
+ and del_flag='0'
+
+
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraReturnMapper.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraReturnMapper.xml
new file mode 100644
index 00000000..63caf4b8
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcCameraReturnMapper.xml
@@ -0,0 +1,110 @@
+
+
+
+
+
+
+
+
+
+ insert into pc_camera_return(
+ alloc_id, project_id, camera_id, check_result, return_by, return_time, photo_urls, remark,
+ audit_status, del_flag, create_by, create_time, update_by, update_time
+ ) values
+
+ (#{it.allocId}, #{it.projectId}, #{it.cameraId}, #{it.checkResult}, #{it.returnBy}, #{it.returnTime},
+ #{it.photoUrls}, #{it.remark}, #{it.auditStatus}, '0', #{it.createBy}, now(), #{it.updateBy}, now())
+
+
+
+
+
+
+
+
+ update pc_camera_return
+ set audit_status = #{auditStatus},
+ audit_by = #{auditBy},
+ audit_time = #{auditTime},
+ audit_remark = #{auditRemark},
+ update_by = #{auditBy},
+ update_time = now()
+ where del_flag='0'
+ and return_id in
+
+ #{id}
+
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcRiskProjectMapper.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcRiskProjectMapper.xml
new file mode 100644
index 00000000..acb966ed
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcRiskProjectMapper.xml
@@ -0,0 +1,170 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ insert into pc_risk_project(
+ project_name, project_code, construction_unit, work_location,
+ work_start, work_end, risk_type, need_camera_cnt, alloc_status,
+ remark, del_flag, create_by, create_time, update_by, update_time
+ ) values (
+ #{projectName}, #{projectCode}, #{constructionUnit}, #{workLocation},
+ #{workStart}, #{workEnd}, #{riskType}, #{needCameraCnt}, #{allocStatus},
+ #{remark}, '0', #{createBy}, now(), #{updateBy}, now()
+ )
+
+
+
+ update pc_risk_project
+ set project_name=#{projectName},
+ project_code=#{projectCode},
+ construction_unit=#{constructionUnit},
+ work_location=#{workLocation},
+ work_start=#{workStart},
+ work_end=#{workEnd},
+ risk_type=#{riskType},
+ need_camera_cnt=#{needCameraCnt},
+ alloc_status=#{allocStatus},
+ remark=#{remark},
+ update_by=#{updateBy},
+ update_time=now()
+ where project_id=#{projectId} and del_flag='0'
+
+
+
+ update pc_risk_project
+ set del_flag='2',
+ update_time=now()
+ where project_id in
+
+ #{id}
+
+
+
+
+ update pc_risk_project
+ set alloc_status = #{allocStatus},
+ update_time = now()
+ where project_id = #{projectId} and del_flag='0'
+
+
+
+
+
+
+
+
+ update pc_risk_project
+ set
+ review_status = #{reviewStatus},
+ supervision_review_status = #{supervisionReviewStatus},
+ on_site_review_status = #{onSiteReviewStatus},
+ final_audit_status = #{finalAuditStatus},
+ project_status = #{projectStatus},
+ on_site_review_images = #{onSiteReviewImages},
+ work_content_complete_rate = #{workContentCompleteRate},
+ site_cleaning_condition = #{siteCleaningCondition},
+ review_comments = #{reviewComments},
+
+ update_by = #{updateBy},
+ update_time = now()
+ where project_id = #{projectId} and del_flag = '0'
+
+
+
+
+ update pc_risk_project
+ set supervision_review_status = #{supervisionReviewStatus},
+ update_time = now()
+ where project_id = #{projectId} and del_flag = '0'
+
+
+
diff --git a/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcUnitArchiveMapper.xml b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcUnitArchiveMapper.xml
new file mode 100644
index 00000000..a83efe52
--- /dev/null
+++ b/ruoyi-modules/aidmt-manage-ms/src/main/resources/mapper/PcUnitArchiveMapper.xml
@@ -0,0 +1,123 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ unit_id, unit_type, unit_name, area_code, area_name, credit_code,
+ contact_name, contact_phone, address, qual_file_url, remark,
+ archive_status, status, del_flag, create_by, create_time, update_by, update_time
+
+
+
+
+
+
+
+ insert into pc_unit_archive
+ (unit_type, unit_name, area_code, area_name, credit_code,
+ contact_name, contact_phone, address, qual_file_url, remark,
+ archive_status, status, del_flag, create_by, create_time, update_by, update_time)
+ values
+ (#{unitType}, #{unitName}, #{areaCode}, #{areaName}, #{creditCode},
+ #{contactName}, #{contactPhone}, #{address}, #{qualFileUrl}, #{remark},
+ #{archiveStatus}, #{status}, '0', #{createBy}, now(), #{updateBy}, now())
+
+
+
+ update pc_unit_archive
+
+ unit_type = #{unitType},
+ unit_name = #{unitName},
+ area_code = #{areaCode},
+ area_name = #{areaName},
+ credit_code = #{creditCode},
+ contact_name = #{contactName},
+ contact_phone = #{contactPhone},
+ address = #{address},
+ qual_file_url = #{qualFileUrl},
+ remark = #{remark},
+ archive_status = #{archiveStatus},
+ status = #{status},
+ update_by = #{updateBy},
+ update_time = now()
+
+ where unit_id = #{unitId}
+ and del_flag = '0'
+
+
+
+ update pc_unit_archive
+ set status = #{param2}, update_time = now()
+ where unit_id = #{param1}
+ and del_flag = '0'
+
+
+
+ update pc_unit_archive
+ set del_flag = '2', update_time = now()
+ where unit_id = #{unitId}
+ and del_flag = '0'
+
+
+
+ update pc_unit_archive
+ set del_flag = '2', update_time = now()
+ where unit_id in
+
+ #{id}
+
+ and del_flag = '0'
+
+
+
diff --git a/ruoyi-modules/pom.xml b/ruoyi-modules/pom.xml
index bcec3cc5..a5c62cd1 100644
--- a/ruoyi-modules/pom.xml
+++ b/ruoyi-modules/pom.xml
@@ -1,25 +1,26 @@
-
-
-
- com.ruoyi
- ruoyi
- 3.6.7
-
- 4.0.0
-
-
- ruoyi-system
- ruoyi-gen
- ruoyi-job
- ruoyi-file
-
-
- ruoyi-modules
- pom
-
-
- ruoyi-modules业务模块
-
-
-
+
+
+
+ com.ruoyi
+ ruoyi
+ 3.6.7
+
+ 4.0.0
+
+
+ ruoyi-system
+ ruoyi-gen
+ ruoyi-job
+ ruoyi-file
+ aidmt-manage-ms
+
+
+ ruoyi-modules
+ pom
+
+
+ ruoyi-modules业务模块
+
+
+