@@ -122,10 +124,18 @@ public class TbCfStationItem {
privateStringtemplate;
@ManyToOne
@JoinColumn(columnDefinition="template")
privateTbCfExpressTemplateexpress;
@Formula(value="(SELECT IFNULL(CEILING(SUM((a.item_score+a.service_score+a.logistics_score+a.price_score)/4)/COUNT(a.item_id)),5) FROM tb_cf_item_comment a WHERE a.item_id=item_id)")
@Query(value="select distinct a from #{#entityName} a WHERE a.templateId in (SELECT x.templateId FROM TbCfExpTemKeyword x WHERE x.keyword LIKE concat('%',:keyword,'%'))")
@Query("select a from #{#entityName} a WHERE a.enableFlag = 1 and a.userId = :user_id and CURRENT_TIMESTAMP between a.startTime and a.endTime order by a.coupon.deductAmount desc ")
@Query("select a from #{#entityName} a WHERE a.enableFlag = 1 and a.userId = :user_id and CURRENT_TIMESTAMP not between a.startTime and a.endTime order by a.coupon.deductAmount desc ")