Forráskód Böngészése

运营后台逆序排序

guq 7 éve
szülő
commit
33616da8d6

+ 2 - 2
applications/operation/operation-server/src/main/resources/mapper/AccoutMapper.xml

@@ -44,7 +44,7 @@
         <if test="con != null">
             ${con}
         </if>
-    </where>
+    </where> order by id desc
     </select>
     <select id="getLogin" parameterType="string" resultMap="loginMap">
         SELECT * FROM (select account_id  ,count(account_id) login_num,max(ac_account.realname) username,max(login_time) lastesttime, max(ac_account.mobile) mobile from saas_auth.au_authorize_log left join saas_account.ac_account on account_id= ac_account.id  where login_time >  date_sub(now(),interval 3 MONTH) GROUP BY account_id order by lastesttime desc
@@ -53,7 +53,7 @@
             <if test="con != null">
                 ${con}
             </if>
-        </where>
+        </where>  order by account_id desc
     </select>
 
     <select id="getConpanyAnalyze" parameterType="string" resultMap="companymap">

+ 2 - 2
applications/operation/operation-server/src/main/resources/mapper/CompanyMapper.xml

@@ -14,13 +14,13 @@
     </resultMap>
 
     <select id="findCompanyByCondition" parameterType="string" resultMap="baseMap">
-         select name,business_code,address,tel,fax,realname,mobile,ac_company.create_time,ac_company.uu from saas_account.ac_company
+         select ac_company.id,name,business_code,address,tel,fax,realname,mobile,ac_company.create_time,ac_company.uu from saas_account.ac_company
         left join saas_account.ac_account on ac_account.id = ac_company.creator_id
         <where>
             <if test="con != null">
                 ${con}
             </if>
-        </where>
+        </where> order by id desc
     </select>