ソースを参照

资金账号修改bug

songyang 2 年 前
コミット
ad8ec0eafe

+ 22 - 0
src/main/java/com/dk/mdm/controller/common/CommonController.java

@@ -1533,6 +1533,28 @@ public class CommonController extends BaseController<Map<String, Object>> {
     public ResponseResultVO<PageList<Map<String, Object>>> getInventoryByPage(@RequestBody Map<String, Object> param) {
         return commonService.getInventoryByPage(param);
     }
+
+    /**
+     * @desc   : 供应商类别
+     * @author : 宋扬
+     * @date   : 2024/3/6 10:28
+     */
+    @ApiOperation(value = "获取供应商类别", notes = "获取供应商类别")
+    @PostMapping({"get_supType"})
+    public ResponseResultVO<List<Map<String, Object>>> getSupType(@RequestBody Map<String, Object> param) {
+        return commonService.getSupType(param);
+    }
+
+    /**
+     * @desc   : 供应商服务类别
+     * @author : 宋扬
+     * @date   : 2024/3/6 10:29
+     */
+    @ApiOperation(value = "获取供应商服务类别", notes = "获取供应商服务类别")
+    @PostMapping({"get_serviceCategories"})
+    public ResponseResultVO<List<Map<String, Object>>> getServiceCategories(@RequestBody Map<String, Object> param) {
+        return commonService.getServiceCategories(param);
+    }
 }
 
 

+ 7 - 7
src/main/java/com/dk/mdm/controller/mst/MoneyAccountController.java

@@ -27,7 +27,7 @@ public class MoneyAccountController{
 
     /**
      * @desc : 条件查询
-     * @author : songy
+     * @author : 宋扬
      * @date : 2023/2/29 10:36
      */
     @ApiOperation(value = "分页、关联、条件查询", notes = "分页、关联、条件查询")
@@ -38,7 +38,7 @@ public class MoneyAccountController{
 
     /**
      * @desc   : 通过ID查询
-     * @author : songy
+     * @author : 宋扬
      * @date   : 2024/3/1 16:01
      */
     @PostMapping({"/{id}"})
@@ -49,7 +49,7 @@ public class MoneyAccountController{
 
     /**
      * @desc : 新建资金账户
-     * @author : songy
+     * @author : 宋扬
      * @date : 2023/2/29 10:48
      */
     @ApiOperation(value = "新建资金账户", notes = "新建资金账户")
@@ -60,7 +60,7 @@ public class MoneyAccountController{
 
     /**
      * @desc : 编辑员工
-     * @author : songy
+     * @author : 宋扬
      * @date : 2023/2/29 10:49
      */
     @ApiOperation(value = "编辑资金账户", notes = "编辑资金账户")
@@ -70,10 +70,9 @@ public class MoneyAccountController{
     }
 
 
-
     /**
      * @desc : 停用
-     * @author : songy
+     * @author : 宋扬
      * @date : 2023/2/29 10:34
      */
     @ApiOperation(value = "停用", notes = "停用")
@@ -84,7 +83,7 @@ public class MoneyAccountController{
 
     /**
      * @desc : 启用
-     * @author : songy
+     * @author : 宋扬
      * @date : 2023/2/29 10:34
      */
     @ApiOperation(value = "启用", notes = "启用")
@@ -93,4 +92,5 @@ public class MoneyAccountController{
         return this.getService().enable(id);
     }
 
+
 }

+ 14 - 0
src/main/java/com/dk/mdm/mapper/common/CommonMapper.java

@@ -1067,4 +1067,18 @@ public interface CommonMapper extends BaseMapper<Map<String, Object>> {
      * @date : 2024-03-05 10:52
      */
     Long getInventoryCountByPage(Map param);
+
+    /**
+     * @desc   : 供应商类别
+     * @author : 宋扬
+     * @date   : 2024/3/6 10:45
+     */
+    List<Map<String, Object>> getSupType(Map param);
+
+    /**
+     * @desc   : 供应商服务类别
+     * @author : 宋扬
+     * @date   : 2024/3/6 10:45
+     */
+    List<Map<String, Object>> getServiceCategories(Map param);
 }

+ 19 - 0
src/main/java/com/dk/mdm/mapper/common/CommonMapper.xml

@@ -3253,4 +3253,23 @@
             AND tmgs.wh_name = #{whName}
         </if>
     </select>
+
+    <!--供应商类别 -->
+    <select id="getSupType" resultType="java.util.Map">
+        select sys.f_get_name_i18n(tdk.kind_name_i18n,'zh_CN' )AS name, tdk.kind_code as code
+        from sys.t_data_kind tdk
+        where tdk.flg_valid
+          and tdk.kind_type = '供应商类别'
+        order by tdk.display_no
+    </select>
+
+    <!--供应商服务类别 -->
+    <select id="getServiceCategories" resultType="java.util.Map">
+        select sys.f_get_name_i18n(tdk.kind_name_i18n,'zh_CN' ) AS name, tdk.kind_code as code
+        from sys.t_data_kind tdk
+        where tdk.flg_valid
+          and tdk.kind_type = '服务类别'
+        order by tdk.display_no
+    </select>
+
 </mapper>

+ 4 - 4
src/main/java/com/dk/mdm/mapper/mst/MoneyAccountMapper.java

@@ -16,28 +16,28 @@ import java.util.List;
 public interface MoneyAccountMapper extends BaseMapper<MoneyAccount>{
     /**
      * @desc   : 根据条件进行查询
-     * @author : songy
+     * @author : 宋扬
      * @date   : 2024/3/1 10:42
      */
     List<MoneyAccountResponse> selectByCond(MoneyAccountQuery moneyAccountQuery);
 
     /**
      * @desc   : 根据条件进行查询(数量)
-     * @author : songy
+     * @author : 宋扬
      * @date   : 2024/3/1 10:42
      */
     Long countByCond(MoneyAccountQuery moneyAccountQuery);
 
    /**
     * @desc   : 查询
-    * @author : songy
+    * @author : 宋扬
     * @date   : 2024/3/2 16:19
     */
     Integer selectDisplayNo(MoneyAccountQuery moneyAccountQuery);
 
     /**
      * @desc   : 根据Id进行查询
-     * @author : songy
+     * @author : 宋扬
      * @date   : 2024-03-03 9:25
      */
     MoneyAccountResponse selectById(String id);

+ 4 - 27
src/main/java/com/dk/mdm/mapper/mst/MoneyAccountMapper.xml

@@ -34,29 +34,17 @@
     <sql id="Condition">
         <where>
             <if test="macCode != null and macCode != ''">
-                AND ma.mac_code = #{macCode}
+                AND ma.mac_code LIKE concat('%',my_ex.likequery(#{macCode}),'%')
             </if>
             <if test="macName != null and macName != ''">
-                AND ma.mac_name = #{macName}
+                AND ma.mac_name LIKE concat('%',my_ex.likequery(#{macName}),'%')
             </if>
             <if test="remarks != null and remarks != ''">
-                AND ma.remarks = #{remarks}
+                AND ma.remarks = LIKE concat('%',my_ex.likequery(#{remarks}),'%')
             </if>
             <if test="cpId != null">
                 AND ma.cp_id = #{cpId}
             </if>
-            <if test="opCreateTime != null">
-                AND ma.op_create_time = #{opCreateTime}
-            </if>
-            <if test="opCreateUserId != null and opCreateUserId != ''">
-                AND ma.op_create_user_id = #{opCreateUserId}
-            </if>
-            <if test="opUpdateTime != null">
-                AND ma.op_update_time = #{opUpdateTime}
-            </if>
-            <if test="opUpdateUserId != null and opUpdateUserId != ''">
-                AND ma.op_update_user_id = #{opUpdateUserId}
-            </if>
             <if test="opTimestamp != null">
                 AND ma.op_timestamp = #{opTimestamp}
             </if>
@@ -69,14 +57,6 @@
         </where>
     </sql>
 
-    <sql id="idsForeach">
-        <!-- 根据主键macId批量操作 -->
-        WHERE mac_id in
-        <foreach collection="ids" index="index" item="item" separator="," open="(" close=")">
-            #{item}
-        </foreach>
-    </sql>
-
     <!-- 查询表t_mst_money_account,(条件查询+分页)列表 -->
     <select id="selectByCond" resultMap="BaseResultMap">
         SELECT ma.mac_Type,ma.mac_code,ma.mac_name,ma.remarks
@@ -86,9 +66,6 @@
         FROM dkic_b.t_mst_money_account ma
         left join dkic_b.t_mst_dictionary_data dd on ma.mac_type=dd.data_id
         <include refid="Condition"/>
-        <if test="pageSize != null and currentPage != null and pageSize != 0 and currentPage != 0">
-            limit #{end} offset #{start}
-        </if>
     </select>
 
     <!-- 查询表t_mst_money_account,(条件查询)个数 -->
@@ -103,7 +80,7 @@
     <select id="selectById" resultMap="BaseResultMap">
         SELECT
         <include refid="Base_Column_List"/>
-        FROM t_mst_money_account
+        FROM dkic_b.t_mst_money_account
         WHERE mac_id = #{macId}::uuid
     </select>
 

+ 2 - 2
src/main/java/com/dk/mdm/model/query/mst/MoneyAccountQuery.java

@@ -196,7 +196,7 @@ public class MoneyAccountQuery extends PageInfo<MoneyAccountQuery> implements Se
 
     /**
      * @desc   : 有效标识List
-     * @author : songy
+     * @author : 宋扬
      * @date   : 2024/3/2 9:31
      */
     @Excel(name = "有效标识 (1:正常 0:停用)")
@@ -206,7 +206,7 @@ public class MoneyAccountQuery extends PageInfo<MoneyAccountQuery> implements Se
 
     /**
      * @desc   : 账户类别list
-     * @author : songy
+     * @author : 宋扬
      * @date   : 2024/3/2 9:27
      */
     @Excel(name = "账户类别 (【数据字典】)")

+ 22 - 0
src/main/java/com/dk/mdm/service/common/CommonService.java

@@ -1540,4 +1540,26 @@ public class CommonService extends BaseService<Map<String, Object>> {
         return super.mergeListWithCount(param, commonMapper.getInventory(param),
                 commonMapper.getInventoryCountByPage(param));
     }
+
+    /**
+     * @desc   : 供应商类别
+     * @author : 宋扬
+     * @date   : 2024/3/6 10:41
+     */
+    public ResponseResultVO<List<Map<String, Object>>> getSupType(Map<String, Object> param) {
+        // 获取系统基础数据
+        List<Map<String, Object>> list = commonMapper.getSupType(param);
+        return ResponseResultUtil.success(list);
+    }
+
+    /**
+     * @desc   : 供应商服务类别
+     * @author : 宋扬
+     * @date   : 2024/3/6 10:43
+     */
+    public ResponseResultVO<List<Map<String, Object>>> getServiceCategories(Map<String, Object> param) {
+        // 获取系统基础数据
+        List<Map<String, Object>> list = commonMapper.getServiceCategories(param);
+        return ResponseResultUtil.success(list);
+    }
 }

+ 4 - 4
src/main/java/com/dk/mdm/service/mst/MoneyAccountService.java

@@ -42,7 +42,7 @@ public class MoneyAccountService extends BaseService<MoneyAccount> {
 
 	/**
 	 * @desc   : 重写主键
-	 * @author : songy
+	 * @author : 宋扬
 	 * @date   : 2023/1/9 10:39
 	 */
 	@Override
@@ -53,7 +53,7 @@ public class MoneyAccountService extends BaseService<MoneyAccount> {
 
 	/**
 	 * @desc   : 条件查询
-	 * @author : songy
+	 * @author : 宋扬
 	 * @date   : 2023/2/29 10:40
 	 */
 	@Pagination
@@ -65,7 +65,7 @@ public class MoneyAccountService extends BaseService<MoneyAccount> {
 
 	/**
 	 * @desc : 保存方法
-	 * @author : songy
+	 * @author : 宋扬
 	 * @date : 2023/2/29 10:49
 	 */
 	@Transactional(
@@ -90,7 +90,7 @@ public class MoneyAccountService extends BaseService<MoneyAccount> {
 
 	/**
 	 * @desc : 编辑方法
-	 * @author : songy
+	 * @author : 宋扬
 	 * @date : 2023/2/29 10:49
 	 */
 	@Transactional(