Browse Source

1.反结账更新表

heqinwei 7 years ago
parent
commit
bfb77c6510

+ 1 - 0
applications/commons/commons-server/src/main/java/com/usoftchina/saas/commons/mapper/EndProductMapper.java

@@ -21,6 +21,7 @@ public interface EndProductMapper {
     void updatePeriodStatus(@Param("status") Long status,@Param("period") String period, @Param("companyId") Long companyId);
 
     void updateRe(@Param("ym") String ym, @Param("companyId") Long companyId);
+    void updatePa(@Param("ym") String ym, @Param("companyId") Long companyId);
 
     int checkPay(Long companyId);
     int checkRec(Long companyId);

+ 1 - 0
applications/commons/commons-server/src/main/java/com/usoftchina/saas/commons/service/impl/EndProductServiceImpl.java

@@ -88,6 +88,7 @@ public class EndProductServiceImpl implements EndProductService {
             throw new BizException(BizExceptionCode.BIZ_UNENDPRODUCT);
         }else{
             endProductMapper.updateRe(period, BaseContextHolder.getCompanyId());
+            endProductMapper.updatePa(period, BaseContextHolder.getCompanyId());
             endProductMapper.updatePeriodStatus(0L, period, BaseContextHolder.getCompanyId());
             messageLogService.customizeLog(generateMsgObj(Long.parseLong(period)), Operation.UNENDPRODUCT);
         }

+ 4 - 0
applications/commons/commons-server/src/main/resources/mapper/EndProductMapper.xml

@@ -41,6 +41,10 @@
         UPDATE receivablesdetail SET RD_STATUS=0 WHERE date_format(rd_date, '%Y%m')=#{ym} AND companyid=#{companyId};
     </update>
 
+    <update id="updatePa" >
+        UPDATE payablesdetail SET PD_STATUS=0 WHERE date_format(PD_date, '%Y%m')=#{ym} AND companyid=#{companyId};
+    </update>
+
     <select id="checkPay" parameterType="java.lang.Long" resultType="java.lang.Integer">
         select count(1) from vendor where (ve_id,companyid) in (select pb_vendid,companyid from (
         select pbd_ym,pb_vendid,paybalance.companyid from paybalance,paybalancedetail where pb_id=pbd_pbid and pbd_slkind='期初余额'

+ 4 - 0
applications/money/money-dto/pom.xml

@@ -28,6 +28,10 @@
             <groupId>io.undertow</groupId>
             <artifactId>undertow-servlet</artifactId>
         </dependency>
+        <dependency>
+            <groupId>com.usoftchina.saas</groupId>
+            <artifactId>commons-dto</artifactId>
+        </dependency>
     </dependencies>