|
@@ -64,32 +64,7 @@ public interface FsPrescribeMapper
|
|
|
* @return 结果
|
|
|
*/
|
|
|
public int deleteFsPrescribeByPrescribeIds(Long[] prescribeIds);
|
|
|
- @Select({"<script> " +
|
|
|
- "select so.*,us.nick_name,dc.doctor_name,dp.doctor_name doctor_drug_name,fso.order_code,fso.`status` order_status,fse.store_name FROM fs_prescribe so LEFT JOIN fs_user us ON us.user_id=so.user_id LEFT JOIN fs_doctor dc ON dc.doctor_id = so.doctor_id LEFT JOIN fs_doctor dp ON dp.doctor_id =so.drug_doctor_id LEFT JOIN fs_store_order fso ON fso.order_id = so.store_order_id LEFT JOIN fs_store fse ON fse.store_id = so.store_id "+
|
|
|
- "<where>\n" +
|
|
|
- " <if test=\"companyId != null \"> and fso.company_id = #{companyId}</if>\n" +
|
|
|
- " <if test=\"companyUserId != null \"> and fso.company_user_id = #{companyUserId}</if>\n" +
|
|
|
- " <if test=\"prescribeType != null \"> and so.prescribe_type = #{prescribeType}</if>\n" +
|
|
|
- " <if test=\"inquiryOrderId != null \"> and so.inquiry_order_id = #{inquiryOrderId}</if>\n" +
|
|
|
- " <if test=\"storeOrderId != null \"> and so.store_order_id = #{storeOrderId}</if>\n" +
|
|
|
- " <if test=\"userId != null \"> and so.user_id = #{userId}</if>\n" +
|
|
|
- " <if test=\"prescribeCode != null and prescribeCode != ''\"> and so.prescribe_code = #{prescribeCode}</if>\n" +
|
|
|
- " <if test=\"patientName != null and patientName != ''\"> and so.patient_name like concat('%', #{patientName}, '%')</if>\n" +
|
|
|
- " <if test=\"doctorName != null and doctorName != ''\"> and dc.doctor_name like concat('%', #{doctorName}, '%')</if>\n" +
|
|
|
- " <if test=\"patientTel != null and patientTel != ''\"> and so.patient_tel = #{patientTel}</if>\n" +
|
|
|
- " <if test=\"doctorId != null and doctorId != ''\"> and so.doctor_id = #{doctorId}</if>\n" +
|
|
|
- " <if test=\"status != null \"> and so.status = #{status}</if>\n" +
|
|
|
- " <if test=\"sTime != null \"> and DATE(so.create_time) >= DATE(#{sTime})</if>\n" +
|
|
|
- " <if test=\"eTime != null \"> and DATE(so.create_time) <= DATE(#{eTime})</if>\n" +
|
|
|
- " <if test=\"auditSTime != null \"> and DATE(so.audit_time) >= DATE(#{auditSTime})</if>\n" +
|
|
|
- " <if test=\"auditETime != null \"> and DATE(so.audit_time) <= DATE(#{auditETime})</if>\n" +
|
|
|
- " <if test=\"auditTime != null \"> and so.audit_time = #{auditTime}</if>\n" +
|
|
|
- " <if test=\"orderCode != null \"> and fso.order_code = #{orderCode}</if>\n" +
|
|
|
- " <if test=\"orderStatus != null \"> and fso.`status` = #{orderStatus}</if>\n" +
|
|
|
- " <if test=\"storeId != null \"> and so.store_id = #{storeId}</if>\n" +
|
|
|
- " </where>\n" +
|
|
|
- " order by prescribe_id desc"+
|
|
|
- "</script>"})
|
|
|
+
|
|
|
List<FsPrescribeListVO> selectFsPrescribeListVO(FsPrescribeParam fsPrescribe);
|
|
|
@Select({"<script> " +
|
|
|
"select p.* from fs_prescribe p " +
|