Sfoglia il codice sorgente

月度报表列表返回供应商名称 订单状态调整

zxf 3 giorni fa
parent
commit
d781e446b1

+ 2 - 2
jd-logistics-modules/jd-logistics-system/src/main/java/com/ruoyi/logistics/callback/SfRoutingPushCallback.java

@@ -106,13 +106,13 @@ public class SfRoutingPushCallback {
                 bizWaybillOrderService.updateBizWaybillOrderState( bizWaybillOrder);
                 break;
             case "44": // 派送中
-                bizWaybillOrder.setOrderStatus(5);
+                bizWaybillOrder.setOrderStatus(4);
                 bizWaybillOrder.setExternalWaybillNo(mailno);
                 bizWaybillOrder.setDeliveryTime(new Date());
                 bizWaybillOrderService.updateBizWaybillOrderState( bizWaybillOrder);
                 break;
             case "80": // 已签收
-                bizWaybillOrder.setOrderStatus(6);
+                bizWaybillOrder.setOrderStatus(5);
                 bizWaybillOrder.setExternalWaybillNo(mailno);
                 bizWaybillOrder.setSignTime(new Date());
                 bizWaybillOrderService.updateBizWaybillOrderState( bizWaybillOrder);

+ 2 - 1
jd-logistics-modules/jd-logistics-system/src/main/java/com/ruoyi/logistics/controller/BizWaybillOrderController.java

@@ -110,7 +110,8 @@ public class BizWaybillOrderController extends BaseController
     {
 
         try{
-            return toAjax(bizWaybillOrderService.canceleBizWaybillOrder(bizWaybillOrder));
+            bizWaybillOrderService.canceleBizWaybillOrder(bizWaybillOrder);
+            return AjaxResult.success("运单取消成功!");
         }
         catch(ServiceException e){
             return AjaxResult.error("取消运单失败! 原因:"+e.getMessage());

+ 13 - 0
jd-logistics-modules/jd-logistics-system/src/main/java/com/ruoyi/logistics/domain/RptFinancialMonthSummary.java

@@ -41,6 +41,10 @@ public class RptFinancialMonthSummary extends BaseEntity
     @Excel(name = "部门ID")
     private Long deptId;
 
+    /** 供应商名称 */
+    @Excel(name = "供应商名称")
+    private String deptName;
+
     /** 用户id */
     @Excel(name = "用户id")
     private Long userId;
@@ -181,10 +185,19 @@ public class RptFinancialMonthSummary extends BaseEntity
         return bwDzfpXmlUrl;
     }
 
+    public String getDeptName() {
+        return deptName;
+    }
+
+    public void setDeptName(String deptName) {
+        this.deptName = deptName;
+    }
+
     @Override
     public String toString() {
         return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
             .append("summaryId", getSummaryId())
+                .append("deptName", getDeptName())
             .append("summaryMonth", getSummaryMonth())
             .append("payableAmount", getPayableAmount())
             .append("transactionCount", getTransactionCount())

+ 1 - 1
jd-logistics-modules/jd-logistics-system/src/main/java/com/ruoyi/logistics/service/impl/BizWaybillOrderServiceImpl.java

@@ -156,7 +156,7 @@ public class BizWaybillOrderServiceImpl implements IBizWaybillOrderService
         if(!orderObject.getBooleanValue("success")){
             throw new ServiceException(orderObject.getString("msg"));
         }
-        bizWaybillOrder.setOrderStatus(7);
+        bizWaybillOrder.setOrderStatus(6);
         return bizWaybillOrderMapper.canceleBizWaybillOrder(bizWaybillOrder);
 
     }

+ 17 - 12
jd-logistics-modules/jd-logistics-system/src/main/resources/mapper/logistics/RptFinancialMonthSummaryMapper.xml

@@ -17,6 +17,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="createBy"    column="create_by"    />
         <result property="updateBy"    column="update_by"    />
         <result property="deptId"    column="dept_id"    />
+        <result property="deptName"    column="dept_name"    />
         <result property="userId"    column="user_id"    />
         <result property="bwDjbh"    column="bw_djbh"    />
         <result property="bwDzfpPdfUrl"    column="bw_dzfp_pdf_url"    />
@@ -29,18 +30,22 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </sql>
 
     <select id="selectRptFinancialMonthSummaryList" parameterType="com.ruoyi.logistics.domain.RptFinancialMonthSummary" resultMap="RptFinancialMonthSummaryResult">
-        <include refid="selectRptFinancialMonthSummaryVo"/>
+        select a.summary_id, a.summary_month, a.payable_amount, a.transaction_count, a.status, a.create_time,
+        a.update_time, a.remark, a.del_flag, a.create_by, a.update_by, a.dept_id, a.user_id, a.bw_djbh,
+        a.bw_dzfp_pdf_url, a.bw_dzfp_ofd_url, a.bw_dzfp_xml_url,b.dept_name from rpt_financial_month_summary a
+               left join  sys_dept b on  a.dept_id=b.dept_id
         <where>  
-            <if test="summaryMonth != null  and summaryMonth != ''"> and summary_month = #{summaryMonth}</if>
-            <if test="payableAmount != null  and payableAmount != ''"> and payable_amount = #{payableAmount}</if>
-            <if test="transactionCount != null  and transactionCount != ''"> and transaction_count = #{transactionCount}</if>
-            <if test="status != null  and status != ''"> and status = #{status}</if>
-            <if test="deptId != null "> and dept_id = #{deptId}</if>
-            <if test="userId != null "> and user_id = #{userId}</if>
-            <if test="bwDjbh != null  and bwDjbh != ''"> and bw_djbh = #{bwDjbh}</if>
-            <if test="bwDzfpPdfUrl != null  and bwDzfpPdfUrl != ''"> and bw_dzfp_pdf_url = #{bwDzfpPdfUrl}</if>
-            <if test="bwDzfpOfdUrl != null  and bwDzfpOfdUrl != ''"> and bw_dzfp_ofd_url = #{bwDzfpOfdUrl}</if>
-            <if test="bwDzfpXmlUrl != null  and bwDzfpXmlUrl != ''"> and bw_dzfp_xml_url = #{bwDzfpXmlUrl}</if>
+            <if test="summaryMonth != null  and summaryMonth != ''"> and a.summary_month = #{summaryMonth}</if>
+            <if test="payableAmount != null  and payableAmount != ''"> and a.payable_amount = #{payableAmount}</if>
+            <if test="transactionCount != null  and transactionCount != ''"> a.and transaction_count = #{transactionCount}</if>
+            <if test="status != null  and status != ''"> and a.status = #{status}</if>
+            <if test="deptId != null "> and a.dept_id = #{deptId}</if>
+            <if test="deptName != null "> and b.dept_name = #{deptName}</if>
+            <if test="userId != null "> and a.user_id = #{userId}</if>
+            <if test="bwDjbh != null  and bwDjbh != ''"> and a.bw_djbh = #{bwDjbh}</if>
+            <if test="bwDzfpPdfUrl != null  and bwDzfpPdfUrl != ''"> and a.bw_dzfp_pdf_url = #{bwDzfpPdfUrl}</if>
+            <if test="bwDzfpOfdUrl != null  and bwDzfpOfdUrl != ''"> and a.bw_dzfp_ofd_url = #{bwDzfpOfdUrl}</if>
+            <if test="bwDzfpXmlUrl != null  and bwDzfpXmlUrl != ''"> and a.bw_dzfp_xml_url = #{bwDzfpXmlUrl}</if>
         </where>
     </select>
     
@@ -132,7 +137,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             a.dept_id,
             count( DISTINCT a.external_waybill_no ) transaction_count,
             sum(
-                    ifnull( rate_amount, adjust_amount )) payable_amount
+                    ifnull(adjust_amount, rate_amount  )) payable_amount
         FROM
             ( SELECT * FROM biz_waybill_order WHERE order_status = 6 AND DATE_FORMAT( sign_time, '%Y.%m' )= #{monthCode}  ) a
                 INNER JOIN biz_waybill_cost_details b ON a.external_waybill_no = b.external_waybill_no