12/1
This commit is contained in:
@@ -12,4 +12,5 @@ import lombok.Data;
|
|||||||
@Data
|
@Data
|
||||||
public class LpkStoreQuery implements Query {
|
public class LpkStoreQuery implements Query {
|
||||||
private String name;
|
private String name;
|
||||||
|
private String sort;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,10 +19,12 @@ import java.util.UUID;
|
|||||||
public class LpkStoreVo implements Vo {
|
public class LpkStoreVo implements Vo {
|
||||||
private String sid;
|
private String sid;
|
||||||
private String createTime;
|
private String createTime;
|
||||||
private String remarks;
|
private String remarks;//备注信息
|
||||||
private String code;
|
private String code;//编号
|
||||||
private String name;
|
private String name;//名称
|
||||||
private String address;
|
private String address;//地址
|
||||||
private String phone;
|
private String phone;//电话
|
||||||
private String businessHours;
|
private String businessHours;//营业时间,提货时间(早X点到晚X点)
|
||||||
|
private String linker;//联系人
|
||||||
|
private String sort;//排序
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -27,6 +27,7 @@ import com.yxt.yyth.api.lpkgoods.LpkGoodsQuery;
|
|||||||
import com.yxt.yyth.api.lpkgoods.LpkGoodsVo;
|
import com.yxt.yyth.api.lpkgoods.LpkGoodsVo;
|
||||||
import com.yxt.yyth.api.lpkreserveorder.LpkReserveOrderVo;
|
import com.yxt.yyth.api.lpkreserveorder.LpkReserveOrderVo;
|
||||||
import com.yxt.yyth.api.lpkreserveordergoods.LpkReserveOrderGoods;
|
import com.yxt.yyth.api.lpkreserveordergoods.LpkReserveOrderGoods;
|
||||||
|
import com.yxt.yyth.api.lpkstore.LpkStoreQuery;
|
||||||
import com.yxt.yyth.api.lpkstore.StoreSelect;
|
import com.yxt.yyth.api.lpkstore.StoreSelect;
|
||||||
import com.yxt.yyth.biz.lpkcardbuildrecord.LpkCardBuildRecordService;
|
import com.yxt.yyth.biz.lpkcardbuildrecord.LpkCardBuildRecordService;
|
||||||
import com.yxt.yyth.biz.lpkcardgrantrecord.LpkCardGrantRecordService;
|
import com.yxt.yyth.biz.lpkcardgrantrecord.LpkCardGrantRecordService;
|
||||||
@@ -177,7 +178,9 @@ public class LpkGiftCardService extends MybatisBaseService<LpkGiftCardMapper, Lp
|
|||||||
ResultBean rb = new ResultBean().fail();
|
ResultBean rb = new ResultBean().fail();
|
||||||
AppletVo vo = baseMapper.getGifCardBySid(sid);
|
AppletVo vo = baseMapper.getGifCardBySid(sid);
|
||||||
List<LpkGiftBagGoodsVo> list = LpkGiftBagGoodsService.getGoodsByBagSid(vo.getGiftbagSid());
|
List<LpkGiftBagGoodsVo> list = LpkGiftBagGoodsService.getGoodsByBagSid(vo.getGiftbagSid());
|
||||||
List<StoreSelect> l = lpkStoreService.getAllStore().getData();
|
// List<StoreSelect> l = lpkStoreService.getAllStore().getData();
|
||||||
|
LpkStoreQuery query=new LpkStoreQuery();
|
||||||
|
// List<StoreSelect> l = lpkStoreService.getAllStoreByQuery(query).getData();
|
||||||
|
|
||||||
List<GoodsVo> goodsVos = new ArrayList<>();
|
List<GoodsVo> goodsVos = new ArrayList<>();
|
||||||
list.forEach(s -> {
|
list.forEach(s -> {
|
||||||
@@ -203,7 +206,7 @@ public class LpkGiftCardService extends MybatisBaseService<LpkGiftCardMapper, Lp
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
vo.setGoodsVos(goodsVos);
|
vo.setGoodsVos(goodsVos);
|
||||||
vo.setSelect(l);
|
// vo.setSelect(l);
|
||||||
LpkReserveOrderVo vo1 =lpkReserveOrderService.getStoreByCustomerSid(vo.getCustomerSid()).getData();
|
LpkReserveOrderVo vo1 =lpkReserveOrderService.getStoreByCustomerSid(vo.getCustomerSid()).getData();
|
||||||
if(null!=vo1){
|
if(null!=vo1){
|
||||||
vo.setStoreSid(vo1.getStore());
|
vo.setStoreSid(vo1.getStore());
|
||||||
|
|||||||
@@ -25,4 +25,5 @@ public interface LpkStoreMapper extends BaseMapper<LpkStore> {
|
|||||||
IPage<LpkStoreVo> storeListPage(IPage<LpkStore> page, @Param(Constants.WRAPPER) QueryWrapper<LpkStore> qw);
|
IPage<LpkStoreVo> storeListPage(IPage<LpkStore> page, @Param(Constants.WRAPPER) QueryWrapper<LpkStore> qw);
|
||||||
@Select("select sid as value,name as text from lpk_store")
|
@Select("select sid as value,name as text from lpk_store")
|
||||||
List<StoreSelect> getAllStore();
|
List<StoreSelect> getAllStore();
|
||||||
|
List<LpkStoreVo> getAllStoreByQuery(@Param(Constants.WRAPPER) QueryWrapper<LpkStore> qw);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,4 +18,12 @@
|
|||||||
${ew.sqlSegment}
|
${ew.sqlSegment}
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
<select id="getAllStoreByQuery" resultType="com.yxt.yyth.api.lpkstore.LpkStoreVo">
|
||||||
|
select
|
||||||
|
*
|
||||||
|
from lpk_store
|
||||||
|
<where>
|
||||||
|
${ew.sqlSegment}
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
@@ -57,4 +57,10 @@ public class LpkStoreRest {
|
|||||||
public ResultBean getAllStore(){
|
public ResultBean getAllStore(){
|
||||||
return lpkStoreService.getAllStore();
|
return lpkStoreService.getAllStore();
|
||||||
}
|
}
|
||||||
|
@ApiOperation("获取全部取货点名称")
|
||||||
|
@PostMapping ("/getAllStoreByQuery")
|
||||||
|
public ResultBean getAllStoreByQuery(LpkStoreQuery query){
|
||||||
|
return lpkStoreService.getAllStoreByQuery(query);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -90,4 +90,15 @@ public class LpkStoreService extends MybatisBaseService<LpkStoreMapper, LpkStore
|
|||||||
List<StoreSelect> vos= baseMapper.getAllStore();
|
List<StoreSelect> vos= baseMapper.getAllStore();
|
||||||
return rb.success().setData(vos);
|
return rb.success().setData(vos);
|
||||||
}
|
}
|
||||||
|
public ResultBean<List<LpkStoreVo>> getAllStoreByQuery(LpkStoreQuery query){
|
||||||
|
ResultBean rb=new ResultBean();
|
||||||
|
QueryWrapper<LpkStore> qw = new QueryWrapper<>();
|
||||||
|
if (StringUtils.isNotBlank(query.getName())) {
|
||||||
|
qw.like("name", query.getName());
|
||||||
|
}
|
||||||
|
qw.eq("isEnable", "1");
|
||||||
|
qw.orderByDesc("sort");
|
||||||
|
List<LpkStoreVo> vos= baseMapper.getAllStoreByQuery(qw);
|
||||||
|
return rb.success().setData(vos);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user