Explorar o código

充值模块bug修复

yq %!s(int64=3) %!d(string=hai) anos
pai
achega
1c812653da

+ 1 - 1
src/main/java/com/usky/dxtop/controller/web/StaffController.java

@@ -65,7 +65,7 @@ public class StaffController {
      * @param card
      * @return
      */
-    @PostMapping("cardBalance")
+    @GetMapping("cardBalance")
     public AjaxResult getCardBalance(@RequestParam String card){
         return AjaxResult.success(staffService.getBalance(card));
     }

+ 4 - 4
src/main/resources/mapper/ChargeMapper.xml

@@ -21,15 +21,15 @@
         select ch.*,s.name as userName
         from charge as ch
         left join staff as s
-        on ch.card = s.card
+        on ch.card = s.card_id
         <where>
             <if test="startTime != null and endTime != null">
-                and  create_time between #{startTime}
+                and  ch.create_time between #{startTime}
                 and #{endTime}
             </if>
             <if test="userName !=null and userName !=''">
-                and user_name like CONCAT('%',#{searchParam},'%')
-                or user_account like CONCAT('%',#{searchParam},'%')
+                and user_name like CONCAT('%',#{userName},'%')
+                or user_account like CONCAT('%',#{userName},'%')
             </if>
             <if test="userId != null">
                 and s.id = #{userId}

+ 1 - 1
src/main/resources/mapper/DishMapper.xml

@@ -24,7 +24,7 @@
         select d.*
         from dish as d
         left join staff as s
-        on d.card = s.card
+        on d.card = s.card_id
         <where>
             <if test="startTime != null and endTime != null">
                 and  d.create_time between #{startTime}