| | |
| | | |
| | | |
| | | </select> |
| | | <select id="supplierThirtyProcurementStatistics" |
| | | resultType="com.ruoyi.system.vo.SupplierThirtyProcurementStatisticsVO"> |
| | | select |
| | | date_format(t1.pay_time, '%m.%d') as `time`, |
| | | date_format(t1.pay_time, '%Y-%m-%d') as payTime, |
| | | count(1) as orderCount |
| | | from t_erp_procurement t1 |
| | | where t1.disabled = ${@com.ruoyi.common.enums.DisabledEnum@NO.getCode()} |
| | | and t1.status in (3,4,5) |
| | | and t1.pay_time between #{startTime} and #{endTime} |
| | | <if test="query.roleType != null and query.roleType == 4"> |
| | | and t1.supplier_id = #{supplierAndClinicId} |
| | | </if> |
| | | <if test="query.roleType != null and query.roleType == 5"> |
| | | and t1.clinic_id = #{supplierAndClinicId} |
| | | </if> |
| | | group by date_format(t1.pay_time, '%m.%d') |
| | | </select> |
| | | <select id="supplierThirtyMoneyProcurementStatistics" |
| | | resultType="com.ruoyi.system.vo.SupplierThirtyMoneyProcurementStatisticsVO"> |
| | | select |
| | | date_format(t1.pay_time, '%m.%d') as `time`, |
| | | date_format(t1.pay_time, '%Y-%m-%d') as payTime, |
| | | sum(t1.pay_money) as moneyTotal |
| | | from t_erp_procurement t1 |
| | | where t1.disabled = ${@com.ruoyi.common.enums.DisabledEnum@NO.getCode()} |
| | | and t1.status in (3,4,5) |
| | | and t1.pay_time between #{startTime} and #{endTime} |
| | | <if test="query.roleType != null and query.roleType == 4"> |
| | | and t1.supplier_id = #{supplierAndClinicId} |
| | | </if> |
| | | <if test="query.roleType != null and query.roleType == 5"> |
| | | and t1.clinic_id = #{supplierAndClinicId} |
| | | </if> |
| | | group by date_format(t1.pay_time, '%m.%d') |
| | | </select> |
| | | |
| | | </mapper> |