liujie
2023-09-26 05100bf0452bea899f74e1b837e714f70362db63
app接口修改
30个文件已修改
386 ■■■■ 已修改文件
cloud-server-account/src/main/java/com/dsh/account/controller/StudentController.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/controller/UseBenefitsController.java 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/feignclient/activity/MerChandiseClient.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/model/vo/userBenefitDetail/PointDetailsVo.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/service/UserIntegralChangesService.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/service/impl/TAppUserServiceImpl.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/service/impl/TStudentServiceImpl.java 17 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/service/impl/UserIntegralChangesServiceImpl.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-activity/src/main/java/com/dsh/activity/controller/UserCouponController.java 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-activity/src/main/java/com/dsh/activity/feignclient/account/model/AppUser.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-competition/src/main/java/com/dsh/competition/feignclient/account/model/AppUser.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackagePaymentController.java 24 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-course/src/main/java/com/dsh/course/entity/CoursePackageStudent.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-course/src/main/java/com/dsh/course/feignclient/account/model/AppUser.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-course/src/main/java/com/dsh/course/model/DetailsListVo.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java 46 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TShopController.java 143 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/LoginController.java 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/resources/mapper/TStoreMapper.xml 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/WEB-INF/view/system/tShop/TShop_add.html 29 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/WEB-INF/view/system/tShop/TShop_edit.html 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/static/img/index4.png 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/static/img/logo.png 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/static/modular/system/tShop/tShop.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/static/modular/system/tShop/tShopOtherOne.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-management/src/main/webapp/static/modular/system/tShop/tShop_info.js 37 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-other/src/main/java/com/dsh/other/feignclient/account/model/AppUser.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
cloud-server-account/src/main/java/com/dsh/account/controller/StudentController.java
@@ -71,7 +71,7 @@
    @PostMapping("/student/queryDefaultStudent")
    public TStudent queryDefaultStudent(@RequestBody Integer appUserId){
        try {
            TStudent one = studentService.getOne(new QueryWrapper<TStudent>().eq("appUserId", appUserId).eq("isDefault", 1).eq("state", 1));
            TStudent one = studentService.getOne(new QueryWrapper<TStudent>().eq("appUserId", appUserId).eq("isDefault", 1).eq("state", 1).last("limit 1"));
            return one;
        }catch (Exception e){
            e.printStackTrace();
cloud-server-account/src/main/java/com/dsh/account/controller/UseBenefitsController.java
@@ -90,10 +90,16 @@
                detailsVo.setUserImage(tAppUser.getHeadImg());
                detailsVo.setUserName(tAppUser.getName());
                detailsVo.setUserPhone(tAppUser.getPhone());
                detailsVo.setSex(tAppUser.getGender() == 1 ? "男" : "女");
                if(tAppUser.getGender()!=null){
                    detailsVo.setSex(tAppUser.getGender() == 1 ? "男" : "女");
                }
                detailsVo.setBirthday(format1.format(tAppUser.getBirthday()));
                detailsVo.setAddress(tAppUser.getProvince()+tAppUser.getCity());
                detailsVo.setMemberLifespan(format1.format(tAppUser.getVipEndTime()));
                if(tAppUser.getVipEndTime()!=null){
                    detailsVo.setMemberLifespan(format1.format(tAppUser.getVipEndTime()));
                }
            }
            return ResultUtil.success(detailsVo);
        }catch (Exception e){
@@ -433,7 +439,7 @@
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9....."),
            @ApiImplicitParam(value = "记录id", name = "detailsId", required = true, dataType = "string"),
    })
    public ResultUtil<PointDetailsVo> redemptionDetails(Integer detailsId){
    public ResultUtil<PointDetailsVo> redemptionDetails(Long detailsId){
        try {
            return ResultUtil.success(uicService.queryRedemptionDetails(detailsId));
        }catch (Exception e){
cloud-server-account/src/main/java/com/dsh/account/feignclient/activity/MerChandiseClient.java
@@ -33,7 +33,7 @@
    ExchangeDetailsVo getIntegralExchangeDetails(@RequestBody Integer appUserId);
    @PostMapping("/base/pointMerchars/getSpecificsOfGoods")
    public PointDetailsVo getSpecificsOfGoods(@RequestBody Integer speMercharsId);
    public PointDetailsVo getSpecificsOfGoods(@RequestBody Long speMercharsId);
    @PostMapping("/base/pointMerchars/selectPointsMerchandiseById")
    public PointsMerchandise selectPointsMerchandiseById(@RequestBody Integer speMercharsId);
cloud-server-account/src/main/java/com/dsh/account/model/vo/userBenefitDetail/PointDetailsVo.java
@@ -8,10 +8,10 @@
import java.util.List;
@Data
public class    PointDetailsVo {
public class   PointDetailsVo {
    @ApiModelProperty(value = "记录id")
    private Integer detailsId;
    private Long detailsId;
    @ApiModelProperty(value = "图片集")
    private List<String> pics;
cloud-server-account/src/main/java/com/dsh/account/service/UserIntegralChangesService.java
@@ -35,7 +35,7 @@
    List<ExchangeDetailsResponse> queryExchangeGoodsdetails(Integer userIdFormRedis, Integer useType, Integer goodType);
    PointDetailsVo queryRedemptionDetails(Integer detailsId);
    PointDetailsVo queryRedemptionDetails(Long detailsId);
    Page<UserIntegral> listAll(Page<UserIntegral> userIntegralPage, IntegralListQuery integralListQuery);
cloud-server-account/src/main/java/com/dsh/account/service/impl/TAppUserServiceImpl.java
@@ -370,7 +370,7 @@
        if(tAppUser.getState() == 2){
            return ResultUtil.error("您的账号已被冻结", "");
        }
        password = Md5Util.MD5Encode(password, null);
//        password = Md5Util.MD5Encode(password, null);
        if(!tAppUser.getPassword().equals(password)){
            return ResultUtil.error("账号密码错误", "");
        }
@@ -799,6 +799,7 @@
                        commodity.setShopIds(mcsClient.queryPointMerStoreIds(vicinityGood.getId()));
                        break;
                    default:
                        break;
                }
                goods.add(commodity);
@@ -820,6 +821,7 @@
                }
                commodity.setBelongsType(allCoupon.getUserPopulation());
                commodity.setGoodsType(4);
                commodity.setShopIds(ucponClient.getCouponStoreIds(allCoupon.getId()));
                commodity.setNums(ucponClient.getRedeemedQuantity(allCoupon.getId()));
                goods.add(commodity);
            }
cloud-server-account/src/main/java/com/dsh/account/service/impl/TStudentServiceImpl.java
@@ -44,6 +44,7 @@
import javax.annotation.Resource;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;
@@ -135,11 +136,21 @@
        student.setHeight(stu.getHeight());
        student.setWeight(stu.getWeight());
        BigDecimal bigDecimal = BigDecimal.valueOf(stu.getWeight());
        BigDecimal multiply = bigDecimal.subtract(BigDecimal.valueOf(stu.getHeight())).multiply(bigDecimal.subtract(BigDecimal.valueOf(stu.getHeight())));
        multiply.setScale(2);
        student.setBmi(multiply.doubleValue());
        double v = stu.getHeight() / 100;
        double v1 = v * v;
        BigDecimal bigDecimal1 = new BigDecimal(v1).setScale(2, RoundingMode.HALF_UP);
        double v2 = bigDecimal.doubleValue() / bigDecimal1.doubleValue();
        BigDecimal bigDecimal2 = new BigDecimal(v2).setScale(2, RoundingMode.HALF_UP);
        student.setBmi(bigDecimal2.doubleValue());
        student.setInsertTime(new Date());
        student.setState(1);
        List<TStudent> tStudents = this.baseMapper.selectList(new LambdaQueryWrapper<TStudent>().eq(TStudent::getAppUserId, appUserId));
        if(tStudents.size()>0){
            student.setIsDefault(2);
        }else {
            student.setIsDefault(1);
        }
        this.baseMapper.insert(student);
        //同步信息到参赛人员信息中
cloud-server-account/src/main/java/com/dsh/account/service/impl/UserIntegralChangesServiceImpl.java
@@ -146,8 +146,9 @@
    }
    @Override
    public PointDetailsVo queryRedemptionDetails(Integer detailsId) {
        return mcClient.getSpecificsOfGoods(detailsId);
    public PointDetailsVo queryRedemptionDetails(Long detailsId) {
        PointDetailsVo specificsOfGoods = mcClient.getSpecificsOfGoods(detailsId);
        return specificsOfGoods;
    }
    @Override
cloud-server-activity/src/main/java/com/dsh/activity/controller/PointMercharsController.java
@@ -361,7 +361,7 @@
    @ResponseBody
    @PostMapping("/base/pointMerchars/getSpecificsOfGoods")
    public PointDetailsVo getSpecificsOfGoods(@RequestBody Integer speMercharsId){
    public PointDetailsVo getSpecificsOfGoods(@RequestBody Long speMercharsId){
        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
        PointDetailsVo detailsVo = new PointDetailsVo();
        UserPointsMerchandise byId = upmseService.getById(speMercharsId);
@@ -382,7 +382,8 @@
            switch (pmdsServiceById.getType()){
                case 1:
                case 3:
                    List<String> list2 = Arrays.asList(StrUtils.splitStr2StrArr(pmdsServiceById.getProductImages(), ","));
                    List<String> list10 = Arrays.asList(StrUtils.splitStr2StrArr(pmdsServiceById.getProductImages(), ","));
                    ArrayList<String> list2 = new ArrayList<>(list10);
                    list2.add(pmdsServiceById.getCover());
                    detailsVo.setPics(list2);
                    Collections.sort(detailsVo.getPics(), (s1, s2) -> {
@@ -397,7 +398,8 @@
                    break;
                case 2:
                    CoursePackage coursePackage = cpClient.queryCoursePackageById(pmdsServiceById.getCoursePackageId());
                    List<String> list1 = Arrays.asList(StrUtils.splitStr2StrArr(coursePackage.getDetailDrawing(), ","));
                    List<String> list11 = Arrays.asList(StrUtils.splitStr2StrArr(coursePackage.getDetailDrawing(), ","));
                    ArrayList<String> list1 = new ArrayList<>(list11);
                    list1.add(coursePackage.getCoverDrawing());
                    detailsVo.setPics(list1);
                    CoursePackagePaymentConfig coursePackagePaymentConfig = cpClient.queryConfigCoursePackData(pmdsServiceById.getCoursePackageConfigId());
@@ -414,7 +416,8 @@
                    break;
                case 4:
                    Coupon coupon = iCouponService.getById(pmdsServiceById.getId());
                    List<String> list3 = Arrays.asList(StrUtils.splitStr2StrArr(coupon.getProductImages(), ","));
                    List<String> list13 = Arrays.asList(StrUtils.splitStr2StrArr(coupon.getProductImages(), ","));
                    ArrayList<String> list3 = new ArrayList<>(list13);
                    list3.add(coupon.getCover());
                    detailsVo.setPics(list3);
                    Collections.sort(detailsVo.getPics(), (s1, s2) -> {
@@ -497,6 +500,9 @@
        if (list.size() >  0){
            storeIds = list.stream().map(PointsMerchandiseStore::getStoreId).collect(Collectors.toList());
        }
        if(storeIds.size()==0){
            storeIds.add(-1);
        }
        return storeIds;
    }
cloud-server-activity/src/main/java/com/dsh/activity/controller/UserCouponController.java
@@ -223,6 +223,9 @@
            if (list.size() > 0 ){
                storeIds = list.stream().map(CouponStore::getStoreId).collect(Collectors.toList());
            }
            if(storeIds.size()==0){
                storeIds.add(-1);
            }
            return storeIds;
        }catch (Exception e){
            e.printStackTrace();
cloud-server-activity/src/main/java/com/dsh/activity/feignclient/account/model/AppUser.java
@@ -1,5 +1,6 @@
package com.dsh.activity.feignclient.account.model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date;
@@ -30,6 +31,7 @@
    /**
     * 生日
     */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date birthday;
    /**
     * 性别(1=男,2=女)
cloud-server-competition/src/main/java/com/dsh/competition/feignclient/account/model/AppUser.java
@@ -1,5 +1,6 @@
package com.dsh.competition.feignclient.account.model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date;
@@ -30,6 +31,7 @@
    /**
     * 生日
     */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date birthday;
    /**
     * 性别(1=男,2=女)
cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java
@@ -103,9 +103,10 @@
        // 2.0
        ArrayList<Map<String,Object>> objects = new ArrayList<>();
        if(null != competition.getStoreId()){
            HashMap<String, Object> map = new HashMap<>();
            String storeId = competition.getStoreId();
            for (String s : storeId.split(",")) {
                HashMap<String, Object> map = new HashMap<>();
                Store store = storeClient.queryStoreById(Integer.valueOf(s));
                map.put("name",store.getName());
                map.put("address",store.getAddress());
@@ -117,8 +118,9 @@
                    double wgs84 = new BigDecimal(distance.get("WGS84")).divide(new BigDecimal(1000)).setScale(2, RoundingMode.HALF_EVEN).doubleValue();
                    map.put("distance",wgs84);
                }
                objects.add(map);
            }
            objects.add(map);
        }
        competitionInfo.setStoreInfos(objects);
cloud-server-course/src/main/java/com/dsh/course/controller/CoursePackagePaymentController.java
@@ -1290,7 +1290,7 @@
    @ResponseBody
    @PostMapping("/coursePackagePayment/editCoursePackagePayment")
    public void editCoursePackagePayment(TCoursePackagePayment coursePackagePayment){
        coursePackagePayment.setCoursePackageId(null);
        coursePackagePayment.setAppUserId(null);
        packagePaymentService.updateById(coursePackagePayment);
    }
@@ -1323,8 +1323,14 @@
            if (ToolUtil.isEmpty(packagePayment) || packagePayment.size()==0){
                return ResultUtil.error("该用户未购买该课包");
            }
            List<CoursePackageScheduling> coursePackageSchedulings = coursePackageSchedulingMapper.selectList(new LambdaQueryWrapper<CoursePackageScheduling>()
                    .eq(CoursePackageScheduling::getCoursePackageId, Integer.valueOf(courseID))
                    .like(CoursePackageScheduling::getClassDate, time)
            );
            List<CoursePackageStudent> coursePackageStudent = cspsService.list(new LambdaQueryWrapper<CoursePackageStudent>()
                    .in(CoursePackageStudent::getCoursePackagePaymentId,packagePayment.stream().map(TCoursePackagePayment::getId).collect(Collectors.toList()))
                    .in(CoursePackageStudent::getCoursePackageSchedulingId,coursePackageSchedulings.stream().map(CoursePackageScheduling::getId).collect(Collectors.toList()))
                    .eq(CoursePackageStudent::getCoursePackageId,courseID)
                    .eq(CoursePackageStudent::getStudentId,stuId)
                    .eq(CoursePackageStudent::getAppUserId,appUserId)
@@ -1342,6 +1348,7 @@
            }
            return ResultUtil.success();
        }catch (Exception e){
            e.printStackTrace();
            return ResultUtil.runErr();
        }
    }
@@ -1388,10 +1395,13 @@
                String classEndTime = tCoursePackage.getClassEndTime();
                String[] split1 = classEndTime.split(",");
                ArrayList<String> strings = new ArrayList<>();
                for (int i1 = 0; i1 < split.length; i1++) {
                    String s = split[i1] + "-" + split1[i1];
                    strings.add(s);
                if(ToolUtil.isNotEmpty(classStartTime)){
                    for (int i1 = 0; i1 < split.length; i1++) {
                        String s = split[i1].substring(0,5) + "-" + split1[i1].substring(0,5);
                        strings.add(s);
                    }
                }
                detailsListVo.setTime(strings);
                List<CoursePackagePaymentConfig> list2 = icppcService.list(new LambdaQueryWrapper<CoursePackagePaymentConfig>().eq(CoursePackagePaymentConfig::getCoursePackageId, tCoursePackage.getId()).orderByAsc(CoursePackagePaymentConfig::getCashPayment));
                if (list2.size() > 0) {
@@ -1405,6 +1415,9 @@
                            .eq(CoursePackageScheduling::getCoursePackageId, tCoursePackage.getId())
                            .like(CoursePackageScheduling::getClassDate, courseDetailReq.getTime())
                    );
                    if(list3.size()==0){
                        break;
                    }
                    List<Long> collect2 = list3.stream().map(CoursePackageScheduling::getId).collect(Collectors.toList());
                    if(collect2.size()==0){
                        collect2.add(-1l);
@@ -1416,12 +1429,13 @@
                                    in(CoursePackageStudent::getCoursePackagePaymentId, ids)
                    );
                        detailsListVo.setType(1);
                    detailsListVo.setType(1);
                    if(list4.size()>0){
                        Integer signInOrNot = list4.get(0).getSignInOrNot();
                        if(signInOrNot==2){
                            detailsListVo.setType(3);
                        }
                        detailsListVo.setIsType(list4.get(0).getType());
                    }
                } else {
cloud-server-course/src/main/java/com/dsh/course/entity/CoursePackageStudent.java
@@ -72,6 +72,8 @@
    @TableField("insertTime")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date insertTime;
    @TableField("type")
    private Integer type;
    @Override
cloud-server-course/src/main/java/com/dsh/course/feignclient/account/model/AppUser.java
@@ -1,5 +1,6 @@
package com.dsh.course.feignclient.account.model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date;
@@ -30,6 +31,7 @@
    /**
     * 生日
     */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date birthday;
    /**
     * 性别(1=男,2=女)
cloud-server-course/src/main/java/com/dsh/course/model/DetailsListVo.java
@@ -20,4 +20,6 @@
    private Integer num;
    private Double money;
    private Integer isType=1;
}
cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackagePaymentServiceImpl.java
@@ -994,6 +994,7 @@
                    student1.setSignInOrNot(0);
                    student1.setReservationStatus(1);
                    student1.setInsertTime(new Date());
                    student1.setType(1);
                    cpsMapper.insert(student1);
                } catch (Exception e) {
                    e.printStackTrace();
cloud-server-course/src/main/java/com/dsh/course/service/impl/TCoursePackageServiceImpl.java
@@ -143,9 +143,11 @@
            ArrayList<String> classTime = new ArrayList<>();
            String[] split = classStartTime.split(",");
            String[] split3 = classEndTime.split(",");
            for (int i = 0; i < split.length; i++) {
                String s = split[i] + "-" +  split3[i];
                classTime.add(s);
            if(ToolUtil.isNotEmpty(classStartTime)) {
                for (int i = 0; i < split.length; i++) {
                    String s = split[i].substring(0,5) + "-" + split3[i].substring(0,5);
                    classTime.add(s);
                }
            }
            coursePackageListVo.setClassStartTime(classTime);
            coursePackageListVo.setType(coursePackage.getType());
@@ -283,6 +285,7 @@
        }
        return listVos;
    }
    @Override
@@ -484,7 +487,11 @@
            TCoursePackage coursePackage = this.getById(id);
            CoursePackageInfo coursePackageInfo = new CoursePackageInfo();
            coursePackageInfo.setId(id);
            coursePackageInfo.setTime(coursePackage.getStartTime()+"-"+coursePackage.getEndTime());
        SimpleDateFormat format = new SimpleDateFormat("yyyy.MM.dd");
        if(coursePackage.getType()==2){
            coursePackageInfo.setTime(format.format(coursePackage.getStartTime())+"-"+format.format(coursePackage.getEndTime()));
        }
            coursePackageInfo.setCoverDrawing(coursePackage.getCoverDrawing());
            coursePackageInfo.setName(coursePackage.getName());
            Store store = storeClient.queryStoreById(coursePackage.getStoreId());
@@ -508,10 +515,13 @@
            ArrayList<String> classTime = new ArrayList<>();
            String[] split4 = classStartTime.split(",");
            String[] split3 = classEndTime.split(",");
            for (int i = 0; i < split4.length; i++) {
                String s = split4[i] + "-" +  split3[i];
                classTime.add(s);
            if(ToolUtil.isNotEmpty(classStartTime)){
                for (int i = 0; i < split4.length; i++) {
                    String s = split4[i].substring(0,5) + "-" +  split3[i].substring(0,5);
                    classTime.add(s);
                }
            }
            coursePackageInfo.setTimes(classTime);
            coursePackageInfo.setType(coursePackage.getType());
@@ -662,13 +672,27 @@
        String[] students = paymentCourseVo.getStudentIds().split(";");
        for (CoursePackagePaymentConfigVo coursePackagePaymentConfigVo : list) {
            if(paymentCourseVo.getCoursePackagePaymentConfigId().compareTo(coursePackagePaymentConfigVo.getId()) == 0){
                CoursePackagePaymentConfig byId = coursePackagePaymentConfigService.getById(paymentCourseVo.getCoursePackagePaymentConfigId());
                Double cashPayment = byId.getCashPayment();
                Integer payType = coursePackagePaymentConfigVo.getPayType();
                if(payType == 1 && paymentCourseVo.getPayType() == 3){//现金支付
                    return ResultUtil.error("支付方式错误,请刷新后重试");
                Integer playPaiCoin1 = byId.getPlayPaiCoin();
                if(cashPayment!=null || cashPayment>0){
                    payType=1;
                }
                if(payType == 2 && paymentCourseVo.getPayType() != 3){//玩湃币支付
                    return ResultUtil.error("支付方式错误,请刷新后重试");
                if(playPaiCoin1!=null || playPaiCoin1>0){
                    payType=2;
                }
                if(cashPayment!=null && cashPayment>0 && playPaiCoin1 !=null && playPaiCoin1>0){
                }else {
                    if(payType == 1 && paymentCourseVo.getPayType() == 3){//现金支付
                        return ResultUtil.error("支付方式错误,请刷新后重试");
                    }
                    if(payType == 2 && paymentCourseVo.getPayType() != 3){//玩湃币支付
                        return ResultUtil.error("支付方式错误,请刷新后重试");
                    }
                }
                Double paymentPrice = coursePackagePaymentConfigVo.getPaymentPrice();//支付价
                paymentPrice = new BigDecimal(students.length).multiply(new BigDecimal(paymentPrice)).setScale(2, RoundingMode.HALF_EVEN).doubleValue();
                Double playPaiCoin = coursePackagePaymentConfigVo.getPlayPaiCoin().doubleValue();//支付币
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/code/TShopController.java
@@ -119,6 +119,14 @@
        String roleid = UserExt.getUser().getRoleid();
        return PREFIX + "TShop_edit_three.html";
    }
    @RequestMapping("/tShop_add_two1")
    public String tCompetitionAddTwo1(Integer id,Model model) {
        List<TCity> list = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId, 0));
        model.addAttribute("list",list);
        model.addAttribute("id",id);
        String roleid = UserExt.getUser().getRoleid();
        return PREFIX + "TShop_add_two.html";
    }
    /**
@@ -134,13 +142,16 @@
//        TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getProvinceCode()));
        TOperatorCity one = operatorCityService.getOne(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, byId.getOperatorId()).eq(TOperatorCity::getType, 1));
        List<TOperatorCity> ones = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, byId.getOperatorId()).eq(TOperatorCity::getType, 1));
        model.addAttribute("list",ones);
        List<TOperatorCity> list3 = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, one.getId()).eq(TOperatorCity::getType, 2));
        if(list3.size()>0){
        if(ones.size()>0){
            model.addAttribute("list",ones);
            List<TOperatorCity> list3 = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, one.getId()).eq(TOperatorCity::getType, 2));
            model.addAttribute("list1",list3);
            System.out.println("===list3======="+list3);
        }else {
            List<TCity> list2 = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId, 0));
            model.addAttribute("list",list2);
            TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getProvinceCode()));
            List<TCity> list1 = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId,one1.getId()));
            model.addAttribute("list1",list1);
@@ -293,25 +304,48 @@
    @RequestMapping(value = "/add")
    @ResponseBody
    public Object list(TStore tStore,String time,String userName,String userPhone,String ids,Integer type,Integer yyId,String lat,String lon) {
    public Object list(TStore tStore,String time,String userName,String userPhone,String ids,Integer type,Integer yyId,String lat,String lon,String pCode1,String cCode1) {
        try {
            if(ToolUtil.isNotEmpty(tStore.getProvinceCode())) {
                TOperatorCity byId = operatorCityService.getById(tStore.getProvinceCode());
                TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getCode()));
                tStore.setProvince(one.getName());
                tStore.setProvinceCode(one.getCode());
                List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, byId.getId()).eq(TOperatorCity::getType, 2));
                if(list.size()>0){
                    TOperatorCity byId1 = operatorCityService.getById(tStore.getCityCode());
                    TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                    tStore.setCity(one1.getName());
                    tStore.setCityCode(one1.getCode());
            if(yyId==null){
                yyId=0;
            }
            if(yyId!=0) {
                List<TOperatorCity> list1 = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, yyId));
                if(list1.size()>0){
                    if (ToolUtil.isNotEmpty(tStore.getProvinceCode())) {
                        TOperatorCity byId = operatorCityService.getById(tStore.getProvinceCode());
                        TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getCode()));
                        tStore.setProvince(one.getName());
                        tStore.setProvinceCode(one.getCode());
                        List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, byId.getId()).eq(TOperatorCity::getType, 2));
                        if (list.size() > 0) {
                            TOperatorCity byId1 = operatorCityService.getById(tStore.getCityCode());
                            TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                            tStore.setCity(one1.getName());
                            tStore.setCityCode(one1.getCode());
                        } else {
                            TCity byId1 = cityService.getById(tStore.getCityCode());
                            TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                            tStore.setCity(one1.getName());
                            tStore.setCityCode(one1.getCode());
                        }
                    }
                }else {
                    TCity byId1 = cityService.getById(tStore.getCityCode());
                    TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                    TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getId, tStore.getProvinceCode()));
                    tStore.setProvince(one.getName());
                    tStore.setProvinceCode(one.getCode());
                    TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getId, tStore.getCityCode()));
                    tStore.setCity(one1.getName());
                    tStore.setCityCode(one1.getCode());
                }
            }else {
                TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, pCode1));
                tStore.setProvince(one.getName());
                tStore.setProvinceCode(one.getCode());
                TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, cCode1));
                tStore.setCity(one1.getName());
                tStore.setCityCode(one1.getCode());
            }
            tStore.setStartTime(time.split(" - ")[0]);
            tStore.setEndTime(time.split(" - ")[1]);
@@ -355,27 +389,53 @@
    @RequestMapping(value = "/update")
    @ResponseBody
    public Object update(TStore tStore,String time,String userName,String userPhone,String ids,Integer type,Integer yyId,String lat,String lon) {
    public Object update(TStore tStore,String time,String userName,String userPhone,String ids,Integer type,Integer yyId,String lat,String lon,String pCode1,String cCode1) {
        try {
            TStore byId = storeService.getById(tStore.getId());
            TStore byIdc = storeService.getById(tStore.getId());
            if(ToolUtil.isNotEmpty(tStore.getProvinceCode())) {
                TOperatorCity tOperatorCity = operatorCityService.getById(tStore.getProvinceCode());
                TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, tOperatorCity.getCode()));
                tStore.setProvince(one.getName());
                tStore.setProvinceCode(one.getCode());
                List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, tOperatorCity.getId()).eq(TOperatorCity::getType, 2));
                if(list.size()>0){
                    TOperatorCity byId1 = operatorCityService.getById(tStore.getCityCode());
                    TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                    tStore.setCity(one1.getName());
                    tStore.setCityCode(one1.getCode());
            if(yyId==null){
                yyId=0;
            }
            if(tStore.getType()==1){
                yyId=0;
            }
            if(yyId!=0) {
                List<TOperatorCity> list1 = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, yyId));
                if(list1.size()>0){
                    if (ToolUtil.isNotEmpty(tStore.getProvinceCode())) {
                        TOperatorCity byId = operatorCityService.getById(tStore.getProvinceCode());
                        TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getCode()));
                        tStore.setProvince(one.getName());
                        tStore.setProvinceCode(one.getCode());
                        List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, byId.getId()).eq(TOperatorCity::getType, 2));
                        if (list.size() > 0) {
                            TOperatorCity byId1 = operatorCityService.getById(tStore.getCityCode());
                            TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                            tStore.setCity(one1.getName());
                            tStore.setCityCode(one1.getCode());
                        } else {
                            TCity byId1 = cityService.getById(tStore.getCityCode());
                            TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                            tStore.setCity(one1.getName());
                            tStore.setCityCode(one1.getCode());
                        }
                    }
                }else {
                    TCity byId1 = cityService.getById(tStore.getCityCode());
                    TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId1.getCode()));
                    TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getId, tStore.getProvinceCode()));
                    tStore.setProvince(one.getName());
                    tStore.setProvinceCode(one.getCode());
                    TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getId, tStore.getCityCode()));
                    tStore.setCity(one1.getName());
                    tStore.setCityCode(one1.getCode());
                }
            }else {
                        TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getId, tStore.getProvinceCode()));
                tStore.setProvince(one.getName());
                tStore.setProvinceCode(one.getCode());
                TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getId, tStore.getCityCode()));
                tStore.setCity(one1.getName());
                tStore.setCityCode(one1.getCode());
            }
            tStore.setStartTime(time.split(" - ")[0]);
            tStore.setEndTime(time.split(" - ")[1]);
@@ -383,9 +443,9 @@
            tStore.setType(type);
            tStore.setOperatorId(yyId);
            if(ToolUtil.isEmpty(tStore.getCoverDrawing())){
                tStore.setCoverDrawing(byId.getCoverDrawing());
                tStore.setCoverDrawing(byIdc.getCoverDrawing());
            }
            User user = userMapper.selectById(byId.getStoreStaffId());
            User user = userMapper.selectById(byIdc.getStoreStaffId());
            List<User> users = userMapper.selectList(new LambdaQueryWrapper<User>().eq(User::getAccount, userPhone).ne(User::getId,tStore.getStoreStaffId()));
            if(users.size()>0){
                return "5001";
@@ -483,7 +543,13 @@
    public Object onChange1(Integer oneId) {
        try {
            List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, oneId).eq(TOperatorCity::getType, 1));
            return list;
            if(list.size()==0){
                List<TCity> list1 = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId, 0));
                return list1;
            }else {
                return list;
            }
        }catch (Exception e){
            e.printStackTrace();
            return ERROR;
@@ -496,6 +562,13 @@
        try {
            List<TOperatorCity> list1 = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, oneId).eq(TOperatorCity::getType, 1));
            List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getPid, oneId).eq(TOperatorCity::getType, 2));
            // 若是全国 为空 去找这个省下面的市
            if(list1.size()==0){
                TCity byId = cityService.getById(oneId);
                List<TCity> list2 = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId, byId.getId()));
                return list2;
            }
            if(list.size()==0){
                TOperatorCity tOperatorCity = list1.get(0);
                Integer code = tOperatorCity.getCode();
cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/LoginController.java
@@ -189,13 +189,12 @@
            }
        }
        User user = userService.getByAccount(username);
        // todo 记得该回去!!!!!!!!!!
//        password = AESUtils.decrypt(password);
//        String s = MD5.md5(password);
//        if(!user.getPassword().equals(s)){
//            model.addAttribute("tips", "账号密码错误");
//            return "/login.html";
//        }
        password = AESUtils.decrypt(password);
        String s = MD5.md5(password);
        if(!user.getPassword().equals(s)){
            model.addAttribute("tips", "账号密码错误");
            return "/login.html";
        }
        GetTokenRequest tokenRequest = new GetTokenRequest();
cloud-server-management/src/main/resources/mapper/TStoreMapper.xml
@@ -17,8 +17,7 @@
    </delete>
    <select id="listAll" resultType="com.dsh.guns.modular.system.model.TStoreListVo">
        select t1.*,t2.name userName,t2.phone userPhone from t_store t1 left join sys_user t2 on t1.storeStaffId = t2.id
        select t1.*,t2.name userName,t2.phone userPhone,t3.name yysName from t_store t1 left join sys_user t2 on t1.storeStaffId = t2.id left  join t_operator t3 on t1.operatorId = t3.id
        where 1=1
        <if test="provinceCode !=null and provinceCode !=''">
            and t1.provinceCode = #{provinceCode}
cloud-server-management/src/main/webapp/WEB-INF/view/system/tShop/TShop_add.html
@@ -52,7 +52,8 @@
                </div>
            </div>
            @if(role=='1'){
            <div class="form-group" id="yys" hidden >
            <div id="yys" hidden>
            <div class="form-group"   >
                <label class="col-sm-3 control-label">所属运营商:</label>
                <div class="col-sm-9">
                    <select class="form-control" id="account" name="account" onchange="TCarInfoDlg.oneChange1(this)">
@@ -76,6 +77,30 @@
                    <select class="form-control" id="cCode" name="cCode" >
                        <option value="">选择市</option>
                    </select>
                </div>
            </div>
            </div>
            <div id="yys1" >
                <div class="form-group" id="provinceCode1">
                    <label class="col-sm-3 control-label">所在省:</label>
                    <div class="col-sm-9">
                        <select class="form-control" id="pCode1" name="pCode1" onchange="TCarInfoDlg.oneChange(this)">
                            <option value="">选择省</option>
                            @for(i in list){
                              <option value="${i.code}">${i.name}</option>
                            @}
                        </select>
                    </div>
                </div>
                <div class="form-group" id="cityCode1">
                    <label class="col-sm-3 control-label">所在市:</label>
                    <div class="col-sm-9">
                        <select class="form-control" id="cCode1" name="cCode1" >
                            <option value="">选择市</option>
                        </select>
                    </div>
                </div>
            </div>
@@ -193,8 +218,10 @@
    function updateType(o) {
        if(o==1){
            $("#yys").hide()
            $("#yys1").show()
        }else {
            $("#yys").show()
            $("#yys1").hide()
        }
cloud-server-management/src/main/webapp/WEB-INF/view/system/tShop/TShop_edit.html
@@ -100,7 +100,7 @@
                <!-- 创建地图容器-->
                <div id="container" style="height: 500px;" ></div>
            </div>
            <#input id="time" name="营业时间" type="text" value="${time}"/>
            <#input id="time" name="营业时间" type="text" value="${time}"/>v
            <div class="form-group">
                <label class="col-sm-3 control-label">门店介绍:</label>
                <div class="col-sm-9">
@@ -223,7 +223,6 @@
            $("#yys").hide()
        }else {
            $("#yys").show()
            queryStudentData
        }
    }
cloud-server-management/src/main/webapp/static/img/index4.png

cloud-server-management/src/main/webapp/static/img/logo.png

cloud-server-management/src/main/webapp/static/modular/system/tShop/tShop.js
@@ -21,7 +21,7 @@
            }
        },
        {title: '所属运营商', field: 'province', visible: role==1?true:false, align: 'center', valign: 'middle'
        {title: '所属运营商', field: 'yysName', visible: role==1?true:false, align: 'center', valign: 'middle'
        },
        {title: '省', field: 'province', visible: role==1?true:false, align: 'center', valign: 'middle'
        },
cloud-server-management/src/main/webapp/static/modular/system/tShop/tShopOtherOne.js
@@ -101,7 +101,7 @@
        area: ['100%', '100%'], //宽高
        fix: false, //不固定
        maxmin: true,
        content: Feng.ctxPath + '/tShop/tShop_add_two?id='+$("#id").val()
        content: Feng.ctxPath + '/tShop/tShop_add_two1?id='+$("#id").val()
    });
    this.layerIndex = index;
};
cloud-server-management/src/main/webapp/static/modular/system/tShop/tShop_info.js
@@ -176,16 +176,26 @@
    }
    let pCode = $("#pCode").val()
    let cCode = $("#cCode").val()
    let pCode1 = $("#pCode1").val()
    let cCode1 = $("#cCode1").val()
    let name = $("#name").val()
    let phone = $("#phone").val()
    if(pCode=='' && $("#role")=="1"){
    if(pCode=='' && $("#role")=="1" && OBJradio==2){
        Feng.info("请选择省")
        return;
    }
    if(cCode=='' && $("#role")=="1"){
    if(cCode=='' && $("#role")=="1" && OBJradio==2){
        Feng.info("请选择市")
        return;
    }
    if(pCode1=='' && $("#role")=="1" && OBJradio==1){
        Feng.info("请选择省")
        return;
    }
    if(cCode1=='' && $("#role")=="1" && OBJradio==12){
        Feng.info("请选择市")
        return;
    }
@@ -288,6 +298,8 @@
    ajax.set("ids",$("#ids").val());
    ajax.set("type",OBJradio);
    ajax.set("yyId",$("#account").val());
    ajax.set("pCode1",pCode1);
    ajax.set("cCode1",cCode1);
    ajax.start();
}
var  map = new AMap.Map('container', {
@@ -400,6 +412,8 @@
    let pCode = $("#pCode").val()
    let cCode = $("#cCode").val()
    let cCode1 = $("#cCode1").val()
    let pCode1 = $("#pCode1").val()
    let account = $("#account").val()
    var OBJradio= $("input[name='type']:checked").val();
    if(OBJradio==2){
@@ -413,13 +427,20 @@
    let name = $("#name").val()
    let phone = $("#phone").val()
    if(pCode=='' && $("#role")=="1"){
    if(pCode=='' && $("#role")=="1" && OBJradio==2){
        Feng.info("请选择省")
        return;
    }
    if(cCode=='' && $("#role")=="1"){
    if(cCode=='' && $("#role")=="1" && OBJradio==2){
        Feng.info("请选择市")
        return;
    }
    if(pCode1=='' && $("#role")=="1" && OBJradio==1){
        Feng.info("请选择省")
        return;
    }
    if(cCode1=='' && $("#role")=="1" && OBJradio==12) {
        Feng.info("请选择市")
    }
    if(name==''){
        Feng.info("门店名称不能为空")
@@ -481,8 +502,7 @@
    var ajax = new $ax(Feng.ctxPath + "/tShop/update", function(data){
        if(data=="5001"){
            Feng.error("该店长手机号已经存在!")
        }else
        if(data.code == 200){
        }else if(data.code == 200){
            if(language==1){
                Feng.success("修改成功!");
            }else if(language==2){
@@ -498,6 +518,7 @@
    },function(data){
        Feng.error("修改失败!" + data.responseJSON.message + "!");
    });
    ajax.set("provinceCode",pCode);
    ajax.set("cityCode",cCode);
    ajax.set("name",name);
@@ -516,6 +537,8 @@
    ajax.set("ids",$("#ids").val());
    ajax.set("type",OBJradio);
    ajax.set("yyId",$("#account").val());
    ajax.set("pCode1",pCode1);
    ajax.set("cCode1",cCode1);
    ajax.start();
}
@@ -574,7 +597,7 @@
            $.each(data, function(k,v) {
                content += "<option value='"+v.code+"'>"+v.name+"</option>";
            });
            $("#cCode").empty().append(content);
            $("#cCode1").empty().append(content);
        }
    });
    ajax.set("oneId",oneId);
cloud-server-other/src/main/java/com/dsh/other/feignclient/account/model/AppUser.java
@@ -1,5 +1,6 @@
package com.dsh.other.feignclient.account.model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import java.util.Date;
@@ -30,6 +31,7 @@
    /**
     * 生日
     */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date birthday;
    /**
     * 性别(1=男,2=女)