|
@@ -18,8 +18,10 @@ import java.time.LocalDate;
|
|
|
import java.time.LocalDateTime;
|
|
|
import java.time.ZoneId;
|
|
|
import java.util.ArrayList;
|
|
|
+import java.util.Arrays;
|
|
|
import java.util.Date;
|
|
|
import java.util.List;
|
|
|
+
|
|
|
@Service
|
|
|
@Log4j2
|
|
|
public class DetailServiceImpl implements IDetailService {
|
|
@@ -39,6 +41,8 @@ public class DetailServiceImpl implements IDetailService {
|
|
|
private AppOrderMapper appOrderMapper;
|
|
|
@Resource
|
|
|
private AppSitePlaceMapper appSitePlaceMapper;
|
|
|
+ @Resource
|
|
|
+ private AppCategoryMapper appCategoryMapper;
|
|
|
|
|
|
@Override
|
|
|
public PlaceInfoVO getPlaceInfo(String id) {
|
|
@@ -117,6 +121,21 @@ public class DetailServiceImpl implements IDetailService {
|
|
|
return courseInfoVOList;
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public PlaceInfoVO.theGymnasiumIsCharteredVO getPlaceInfoNoFixation(String id, String categoryId) {
|
|
|
+ AppSitePlace appSitePlace = appSitePlaceMapper.selectOne(Wrappers.<AppSitePlace>lambdaQuery()
|
|
|
+ .eq(AppSitePlace::getSiteId, id)
|
|
|
+ .eq(AppSitePlace::getStatus, 0)
|
|
|
+ .eq(AppSitePlace::getDelFlag, 0)
|
|
|
+ .last("LIMIT 1"));
|
|
|
+ List<PlaceInfoVO.theGymnasiumIsCharteredInfoVO> collect = appSitePriceRulesMapper.theGymnasiumIsCharteredInfo(appSitePlace.getOrgCode(), categoryId);
|
|
|
+ return new PlaceInfoVO.theGymnasiumIsCharteredVO()
|
|
|
+ .setCategory(getCategoryName(categoryId))
|
|
|
+ .setEarlyRefundTime(appSitePlace.getEarlyRefundTime())
|
|
|
+ .setVr(appSiteMapper.selectById(id).getVr())
|
|
|
+ .setTimeSlot(collect);
|
|
|
+ }
|
|
|
+
|
|
|
/**
|
|
|
* @return
|
|
|
* @Author SheepHy
|
|
@@ -190,4 +209,22 @@ public class DetailServiceImpl implements IDetailService {
|
|
|
return 0;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @Author SheepHy
|
|
|
+ * @Description 根据类目ID获取完整的类目名称
|
|
|
+ * @Date 13:31 2025/7/7
|
|
|
+ * @Param categoryId 类目ID
|
|
|
+ * @return List<String>
|
|
|
+ **/
|
|
|
+ private List<String> getCategoryName(String categoryId) {
|
|
|
+ List<String> list = new ArrayList<>();
|
|
|
+ if(null != categoryId){
|
|
|
+ String[] split = categoryId.split(",");
|
|
|
+ Arrays.stream(split).forEach(id -> {
|
|
|
+ list.add(appCategoryMapper.selectById(id).getName());
|
|
|
+ });
|
|
|
+ }
|
|
|
+ return list;
|
|
|
+ }
|
|
|
}
|