Browse Source

辅助资料倒序排序

chenw 7 years ago
parent
commit
502f82a3e7

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/AddressMapper.xml

@@ -179,7 +179,7 @@
     where ad_id in (#{ids,jdbcType=VARCHAR})
     where ad_id in (#{ids,jdbcType=VARCHAR})
   </delete>
   </delete>
   <select id="selectAll" resultMap="ResultMapWithBLOBs">
   <select id="selectAll" resultMap="ResultMapWithBLOBs">
-    SELECT * FROM ADDRESS where COMPANYID=#{companyId}
+    SELECT * FROM ADDRESS where COMPANYID=#{companyId} ORDER BY AD_ID DESC
   </select>
   </select>
   <select id="selectCountByName" resultType="int">
   <select id="selectCountByName" resultType="int">
     SELECT count(*) FROM ADDRESS
     SELECT count(*) FROM ADDRESS

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/CustomerkindMapper.xml

@@ -120,7 +120,7 @@
     where ck_id = #{id}
     where ck_id = #{id}
   </update>
   </update>
   <select id="selectAll" resultMap="BaseResultMap">
   <select id="selectAll" resultMap="BaseResultMap">
-    SELECT * FROM CUSTOMERKIND WHERE COMPANYID=#{companyId}
+    SELECT * FROM CUSTOMERKIND WHERE COMPANYID=#{companyId} order by ck_id desc
   </select>
   </select>
   <select id="getCombo" resultType="com.usoftchina.saas.commons.dto.ComboDTO">
   <select id="getCombo" resultType="com.usoftchina.saas.commons.dto.ComboDTO">
     SELECT ck_name display,ck_name value FROM CUSTOMERKIND WHERE COMPANYID=#{companyId}
     SELECT ck_name display,ck_name value FROM CUSTOMERKIND WHERE COMPANYID=#{companyId}

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/FundinouttypeMapper.xml

@@ -140,7 +140,7 @@
     where ft_id = #{id}
     where ft_id = #{id}
   </update>
   </update>
   <select id="selectAll" resultMap="BaseResultMap">
   <select id="selectAll" resultMap="BaseResultMap">
-    SELECT * FROM FUNDINOUTTYPE where companyId=#{companyId}
+    SELECT * FROM FUNDINOUTTYPE where companyId=#{companyId} ORDER BY FT_ID DESC
   </select>
   </select>
   <select id="selectCountByName" resultType="int">
   <select id="selectCountByName" resultType="int">
     SELECT COUNT(*) FROM FUNDINOUTTYPE
     SELECT COUNT(*) FROM FUNDINOUTTYPE

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/ProductMapper.xml

@@ -905,7 +905,7 @@
 
 
     <select id="selectOrderCountByProdCode" resultType="java.lang.Long">
     <select id="selectOrderCountByProdCode" resultType="java.lang.Long">
         SELECT COUNT(*) FROM PRODINOUT LEFT JOIN PRODIODETAIL ON PI_ID=PD_PIID AND PRODINOUT.COMPANYID=PRODIODETAIL.COMPANYID
         SELECT COUNT(*) FROM PRODINOUT LEFT JOIN PRODIODETAIL ON PI_ID=PD_PIID AND PRODINOUT.COMPANYID=PRODIODETAIL.COMPANYID
-        WHERE COMPANYID = #{companyId} AND PD_PRODID = #{id}
+        WHERE PRODIODETAIL.COMPANYID = #{companyId} AND PD_PRODID = #{id}
     </select>
     </select>
 
 
     <delete id="deleteProdIOByCode" >
     <delete id="deleteProdIOByCode" >

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/ProductbrandMapper.xml

@@ -130,7 +130,7 @@
   </select>
   </select>
 
 
   <select id="getCombo" resultType="com.usoftchina.saas.commons.dto.ComboDTO">
   <select id="getCombo" resultType="com.usoftchina.saas.commons.dto.ComboDTO">
-    SELECT PB_NAME display,PB_NAME value FROM PRODUCTBRAND WHERE COMPANYID=#{companyId}
+    SELECT PB_NAME display,PB_NAME value FROM PRODUCTBRAND WHERE COMPANYID=#{companyId} ORDER BY PB_ID DESC
   </select>
   </select>
   <select id="selectCountByName" resultType="int">
   <select id="selectCountByName" resultType="int">
     SELECT COUNT(*) FROM PRODUCTBRAND
     SELECT COUNT(*) FROM PRODUCTBRAND

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/ProducttypeMapper.xml

@@ -126,7 +126,7 @@
     where pt_id = #{id}
     where pt_id = #{id}
   </update>
   </update>
   <select id="selectAll" resultMap="BaseResultMap">
   <select id="selectAll" resultMap="BaseResultMap">
-    SELECT * FROM PRODUCTTYPE where companyId=#{companyId}
+    SELECT * FROM PRODUCTTYPE where companyId=#{companyId} ORDER BY PT_ID DESC
   </select>
   </select>
     <select id="selectCountByName" resultType="int">
     <select id="selectCountByName" resultType="int">
         SELECT COUNT(*) FROM PRODUCTTYPE
         SELECT COUNT(*) FROM PRODUCTTYPE

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/ProductunitMapper.xml

@@ -120,7 +120,7 @@
     where pu_id = #{id}
     where pu_id = #{id}
   </update>
   </update>
   <select id="selectAll" resultMap="BaseResultMap">
   <select id="selectAll" resultMap="BaseResultMap">
-    SELECT * FROM PRODUCTUNIT where companyId=#{companyId}
+    SELECT * FROM PRODUCTUNIT where companyId=#{companyId} ORDER BY PU_ID DESC
   </select>
   </select>
     <select id="selectCountByName" resultType="int">
     <select id="selectCountByName" resultType="int">
         SELECT COUNT(*) FROM productunit
         SELECT COUNT(*) FROM productunit

+ 1 - 1
applications/document/document-server/src/main/resources/mapper/VendorkindMapper.xml

@@ -126,7 +126,7 @@
     where vk_id = #{id}
     where vk_id = #{id}
   </update>
   </update>
   <select id="selectAll" resultMap="BaseResultMap">
   <select id="selectAll" resultMap="BaseResultMap">
-    SELECT * FROM VENDORKIND where companyId = #{companyId}
+    SELECT * FROM VENDORKIND where companyId = #{companyId} ORDER BY VK_ID DESC
   </select>
   </select>
   <select id="getCombo" resultType="com.usoftchina.saas.commons.dto.ComboDTO">
   <select id="getCombo" resultType="com.usoftchina.saas.commons.dto.ComboDTO">
     SELECT VK_NAME display, VK_NAME value FROM VENDORKIND WHERE COMPANYID=#{companyId}
     SELECT VK_NAME display, VK_NAME value FROM VENDORKIND WHERE COMPANYID=#{companyId}