Просмотр исходного кода

[租赁/物业][修改][查询排序]

release_toaliyun_real
gongbiao 7 лет назад
committed by Stormeye Wu
Родитель
Сommit
b9b53477c1
5 измененных файлов: 11 добавлений и 7 удалений
  1. +1
    -0
      mallinkAdmin/src/main/java/com/iformall/controller/WxBillPropertyController.java
  2. +1
    -1
      mallinkService/src/main/java/com/iformall/domain/po/WxBillRent.java
  3. +1
    -0
      mallinkService/src/main/java/com/iformall/service/impl/WxBillRentServiceImpl.java
  4. +4
    -3
      mallinkService/src/main/resources/mapper/WxBillPropertyMapper.xml
  5. +4
    -3
      mallinkService/src/main/resources/mapper/WxBillRentMapper.xml

+ 1
- 0
mallinkAdmin/src/main/java/com/iformall/controller/WxBillPropertyController.java Просмотреть файл

@@ -35,6 +35,7 @@ public class WxBillPropertyController extends BaseController {
wxBillProperty = new WxBillProperty();
}
wxBillProperty.setTenantId(getTenantId());
wxBillProperty.setSortColumns(WxBillProperty.Field.Id_ASC);
PageInfo<Map<String, Object>> result = wxBillPropertyService.listAsPage(wxBillProperty, pageNum, pageSize);
return new ResultData(result);
}


+ 1
- 1
mallinkService/src/main/java/com/iformall/domain/po/WxBillRent.java Просмотреть файл

@@ -351,7 +351,7 @@ public class WxBillRent implements Serializable {
sb.append(",");
sb.append(fields[k].toString());
}
this.sortColumns = sb.toString();
}
public void setSortColumns(String sortColumns)


+ 1
- 0
mallinkService/src/main/java/com/iformall/service/impl/WxBillRentServiceImpl.java Просмотреть файл

@@ -92,6 +92,7 @@ public class WxBillRentServiceImpl implements WxBillRentService {
public Map<String, Object> getById(Long id) {
WxBillRent record = new WxBillRent();
record.setId(id);
record.setSortColumns(WxBillRent.Field.Id_ASC);
return wxBillRentMapper.queryBillRentList(record).get(0);
}



+ 4
- 3
mallinkService/src/main/resources/mapper/WxBillPropertyMapper.xml Просмотреть файл

@@ -83,12 +83,13 @@
br.`property_contract_id` propertyContractId,d.receive_pay deposit,case when br.late_pay_time is null then 0
else
FLOOR(DATEDIFF(now(),br.late_pay_time)*br.late_pay_ratio/10000*br.owe) end latePayPrice,
(select max(period) from wx_bill_property where id=br.id) allPeriod,d.`status` depositStatus
(select max(period) from wx_bill_property where property_contract_id=br.property_contract_id)
allPeriod,d.`status` depositStatus
from wx_bill_property br left join wx_merchant m on br.merchant_id=m.id
left join wx_shop s on br.shop_id=s.id
left join wx_bill_property_deposit d on br.property_contract_id=d.property_contract_id
<where>
is_preview = 0
br.is_preview = 0
<if test=" null != id ">and br.`id` = #{id}</if>
<if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if>
<if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if>
@@ -99,7 +100,7 @@
<if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if>
</where>
order by ${sortColumns}
order by br.${sortColumns}
</select>
<select id="queryPayInfo" resultType="hashmap" parameterType="hashmap">


+ 4
- 3
mallinkService/src/main/resources/mapper/WxBillRentMapper.xml Просмотреть файл

@@ -84,13 +84,14 @@
br.`revenue`,br.`late_pay_ratio` latePayRatio,br.`late_pay_time` latePayTime,br.`period`,
br.`rent_contract_id` rentContractId,d.receive_pay deposit,case when br.late_pay_time is null then 0 else
FLOOR(DATEDIFF(now(),br.late_pay_time)*br.late_pay_ratio/10000*br.owe) end latePayPrice,
(select max(period) from wx_bill_rent where id=br.id) allPeriod,d.`status` depositStatus
(select max(period) from wx_bill_rent where rent_contract_id=br.rent_contract_id) allPeriod,d.`status`
depositStatus
from wx_bill_rent br left join wx_merchant m on br.merchant_id=m.id
left join wx_shop s on br.shop_id=s.id
left join wx_rent_contract r on br.rent_contract_id=r.id
left join wx_bill_rent_deposit d on br.rent_contract_id=d.rent_contract_id and br.merchant_id=d.merchant_id
<where>
is_preview = 0
br.is_preview = 0
<if test=" null != id ">and br.`id` = #{id}</if>
<if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if>
<if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if>
@@ -100,7 +101,7 @@
<if test=" null != starttime and null!=endtime ">and br.`receive_date` between #{starttime} and #{endtime}</if>
<if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if>
</where>
order by ${sortColumns}
order by br.${sortColumns}
</select>
<select id="queryPayInfo" resultType="hashmap" parameterType="hashmap">


Загрузка…
Отмена
Сохранить