Browse Source

【界面标准化】【其它出入库】【其它出入库主表新增成本金额字段】【后端处理】

rainco 7 years ago
parent
commit
06d837233d

+ 2 - 0
applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/dto/ProdInOutDTO.java

@@ -74,4 +74,6 @@ public class ProdInOutDTO extends CommonBaseDTO implements Serializable {
     private Long pi_ioid;
 
     private String pi_iocode;
+
+    private Double pi_costtotal;
 }

+ 2 - 0
applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/ProdInOut.java

@@ -84,4 +84,6 @@ public class ProdInOut extends CommonBaseEntity implements Serializable {
     private String pi_sellercode;
 
     private String pi_seller;
+
+    private Double pi_costtotal;
 }

+ 2 - 0
applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/ProdInOutList.java

@@ -60,6 +60,8 @@ public class ProdInOutList extends CommonBaseEntity{
 
     private String pi_address;
 
+    private Double pi_costtotal;
+
     private Long pd_piid;
 
     private String pd_inoutno;

+ 2 - 2
applications/storage/storage-server/src/main/resources/mapper/ProdIODetailMapper.xml

@@ -757,11 +757,11 @@
   </delete>
 
   <update id="calcProdIn">
-    update prodinout set pi_total = (select sum(pd_total) from prodiodetail where pd_piid = #{pi_id,jdbcType=INTEGER} ) where pi_id = #{pi_id,jdbcType=INTEGER};
+    update prodinout set pi_costtotal = (select sum(pd_total) from prodiodetail where pd_piid = #{pi_id,jdbcType=INTEGER} ) where pi_id = #{pi_id,jdbcType=INTEGER};
   </update>
 
   <update id="calcProdOut">
-    update prodinout set pi_total = (select sum(pd_total) from prodiodetail where pd_piid = #{pi_id,jdbcType=INTEGER} ) where pi_id = #{pi_id,jdbcType=INTEGER};
+    update prodinout set pi_costtotal = (select sum(pd_total) from prodiodetail where pd_piid = #{pi_id,jdbcType=INTEGER} ) where pi_id = #{pi_id,jdbcType=INTEGER};
   </update>
 
   <delete id="deleteByInOutNo" >

+ 1 - 0
applications/storage/storage-server/src/main/resources/mapper/ProdInOutListMapper.xml

@@ -30,6 +30,7 @@
     <result column="pi_auditman" jdbcType="VARCHAR" property="pi_auditman" />
     <result column="pi_address" jdbcType="VARCHAR" property="pi_address" />
     <result column="pi_remark" jdbcType="VARCHAR" property="pi_remark" />
+    <result column="pi_costtotal" jdbcType="DOUBLE" property="pi_costtotal"/>
     <result column="pd_piid" jdbcType="INTEGER" property="pd_piid" />
     <result column="pd_inoutno" jdbcType="VARCHAR" property="pd_inoutno" />
     <result column="pd_piclass" jdbcType="VARCHAR" property="pd_piclass" />

+ 8 - 1
applications/storage/storage-server/src/main/resources/mapper/ProdInOutMapper.xml

@@ -37,6 +37,7 @@
     <result column="pi_auditman" jdbcType="VARCHAR" property="pi_auditman" />
     <result column="pi_remark" jdbcType="VARCHAR" property="pi_remark" />
     <result column="pi_ioid" jdbcType="INTEGER" property="pi_ioid" />
+    <result column="pi_costtotal" jdbcType="DOUBLE" property="pi_costtotal"/>
   </resultMap>
   <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.usoftchina.saas.storage.po.ProdInOut">
     <result column="pi_address" jdbcType="LONGVARCHAR" property="pi_address" />
@@ -48,7 +49,7 @@
     pi_id, pi_inoutno, pi_class, pi_date, pi_vendid, pi_vendcode, pi_vendname, pi_custid, 
     pi_custcode, pi_custname, pi_puid, pi_pucode, pi_said, pi_sacode, pi_total,pi_status, pi_statuscode, pi_printstatus, pi_printstatuscode,
     companyid, updaterid,updaterName,updatetime,creatorid,creatorName,createtime, pi_text1, pi_text2, pi_text3, pi_text4, pi_text5,pi_auditdate,
-    pi_auditman,pi_remark,pi_ioid
+    pi_auditman,pi_remark,pi_ioid,pi_costtotal
   </sql>
   <sql id="Blob_Column_List">
     pi_address
@@ -184,6 +185,9 @@
         <if test="pi_macode != null">
             pi_macode,
         </if>
+      <if test="pi_costtotal!=null">
+        pi_costtotal,
+      </if>
     </trim>
     <trim prefix="values (" suffix=")" suffixOverrides=",">
 
@@ -298,6 +302,9 @@
         <if test="pi_macode != null">
             #{pi_macode,jdbcType=VARCHAR},
         </if>
+      <if test="pi_costtotal !=null">
+        #{pi_costtotal,jdbcType=DOUBLE},
+      </if>
     </trim>
   </insert>