jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/demo/contract/controller/ContractController.java
@@ -370,7 +370,22 @@ } return Result.OK("编辑成功!"); } @AutoLog(value = "停止服务合同") @Operation(summary="停止服务合同") @RequiresPermissions("contract:contract:dropService") @RequestMapping(value = "/dropService", method = {RequestMethod.PUT,RequestMethod.POST}) public Result<String> dropService(@RequestBody ContractPage contractPage) { Contract contract = new Contract(); contract.setId(contractPage.getId()); contract.setIsDropService(contractPage.getIsDropService().isEmpty() ? "是" : contractPage.getIsDropService()); boolean b = contractService.updateById(contract); if (b) { return Result.OK("更新完成"); } else { return Result.error("更新失败"); } } /** * 通过id删除 * jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/demo/contract/entity/Contract.java
@@ -143,4 +143,9 @@ private java.lang.String contractCode; @Excel(name = "是否停止服务", width = 1) @Schema(description = "是否停止服务") private java.lang.String isDropService; } jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/demo/contract/entity/SemanticWord.java
@@ -131,6 +131,9 @@ private Contract contract; @TableField(exist = false) private String isDropService; @TableField(exist = false) private List<SemanticWord> semanticWordList; @TableField(exist = false) jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/demo/contract/vo/ContractPage.java
@@ -121,4 +121,9 @@ @Excel(name = "紧急状态", width = 15) @Schema(description = "紧急状态") private java.lang.String emergencyStatus; @Excel(name = "是否停止服务", width = 255) @Schema(description = "是否停止服务") private java.lang.String isDropService; } jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/demo/semanticword/controller/SemanticWordController.java
@@ -98,6 +98,14 @@ "SELECT id FROM contract WHERE customer_name = '" + customerName + "'" ); } String isDropService = semanticWord.getIsDropService(); if (customerName != null && !customerName.isEmpty()) { // 拼接关联条件:semantic_word关联contract,contract关联customer,通过客户名称过滤 queryWrapper.inSql( "contract_id", // semantic_word表中关联contract的字段 "SELECT id FROM contract WHERE is_drop_service = '" + isDropService + "'" ); } String agentName = semanticWord.getAgentName(); if (agentName != null && !agentName.isEmpty()) { // 拼接关联条件:semantic_word关联contract,contract关联customer,通过客户名称过滤