| | |
| | | e.printStackTrace(); |
| | | return ResultUtil.runErr(); |
| | | } |
| | | |
| | | } |
| | | |
| | | @ResponseBody |
| | |
| | | @ApiOperation(value = "上课首页分配课时-课程列表", tags = {"APP-开始上课"}) |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9....."), |
| | | @ApiImplicitParam(value = "分配给课包id", name = "packetId", required = true, dataType = "string"), |
| | | @ApiImplicitParam(value = "分配给课包id", name = "packetId", required = true, dataType = "Long"), |
| | | }) |
| | | public ResultUtil<Integer> weeksOfAddHours(Integer packetId){ |
| | | public ResultUtil<Integer> weeksOfAddHours(Long packetId){ |
| | | try { |
| | | Integer appUserId = tokenUtil.getUserIdFormRedis(); |
| | | if(null == appUserId){ |
| | |
| | | } |
| | | TAppGift one = appGiftService.getOne(new LambdaQueryWrapper<TAppGift>().eq(TAppGift::getUserId, appUserId)); |
| | | Boolean b= false; |
| | | Integer i=0; |
| | | if(one!=null && one.getNum()>0){ |
| | | b =appGiftService.weeksOfAddHours(packetId,appUserId,one.getNum()); |
| | | i=appGiftService.weeksOfAddHours(packetId,appUserId,one.getNum()); |
| | | |
| | | } |
| | | if(b){ |
| | | if(i==1){ |
| | | // 送完清0 |
| | | one.setNum(0); |
| | | appGiftService.updateById(one); |
| | |
| | | @ApiOperation(value = "联系客服-常见问题列表", tags = {"APP-探索玩湃"}) |
| | | public ResultUtil<List<QuestionIns>> queryFrequentlyAskedQuestionDetails(){ |
| | | try { |
| | | return ResultUtil.success(tsService.queryQuestionData()); |
| | | List<QuestionIns> questionIns = tsService.queryQuestionData(); |
| | | return ResultUtil.success(questionIns); |
| | | }catch (Exception e){ |
| | | return ResultUtil.runErr(); |
| | | } |
| | |
| | | List<TCoursePackagePayment> getCoursePackagePaymentOfCode(@RequestBody String code); |
| | | |
| | | @PostMapping("/base/coursePack/sendHours") |
| | | Boolean sendHours(String s); |
| | | Integer sendHours(String s); |
| | | |
| | | @PostMapping("/base/coursePack/getClassHour") |
| | | Integer getClassHour(Integer courseConfigId); |
| | |
| | | |
| | | @Data |
| | | public class StuCourseResp { |
| | | private Long id; |
| | | |
| | | @ApiModelProperty(value = "课包id") |
| | | private Integer courseId; |
| | |
| | | @Data |
| | | public class RegisteredCourse { |
| | | |
| | | private Long id; |
| | | |
| | | @ApiModelProperty(value = "课程ID") |
| | | private Integer courseId; |
| | | |
| | |
| | | public class QuestionIns { |
| | | |
| | | @ApiModelProperty(value = "问题id") |
| | | private Integer noticeId; |
| | | private Integer quesId; |
| | | |
| | | @ApiModelProperty(value = "问题标题") |
| | | private String noticeTitle; |
| | | private String quesTitle; |
| | | |
| | | @ApiModelProperty(value = "答复内容") |
| | | private String noticeContents; |
| | | private String quesContents; |
| | | |
| | | } |
| | |
| | | */ |
| | | public interface TAppGiftService extends IService<TAppGift> { |
| | | |
| | | Boolean weeksOfAddHours(Integer packetId,Integer appUserId,Integer num); |
| | | Integer weeksOfAddHours(Long packetId,Integer appUserId,Integer num); |
| | | |
| | | |
| | | } |
| | |
| | | private CoursePaymentClient coursePaymentClient; |
| | | |
| | | @Override |
| | | public Boolean weeksOfAddHours(Integer packetId,Integer appUserId,Integer num) { |
| | | Boolean b = coursePaymentClient.sendHours(packetId+"_"+appUserId+"_"+num); |
| | | public Integer weeksOfAddHours(Long packetId,Integer appUserId,Integer num) { |
| | | Integer b = coursePaymentClient.sendHours(packetId+"_"+appUserId+"_"+num); |
| | | return b; |
| | | } |
| | | } |
| | |
| | | coursePackIds = stuCoursePayment.stream().map(StuCourseResp::getCourseId).collect(Collectors.toList()); |
| | | for (StuCourseResp tCoursePackagePayment : stuCoursePayment) { |
| | | RegisteredCourse course = new RegisteredCourse(); |
| | | course.setId(tCoursePackagePayment.getId()); |
| | | course.setCourseId(tCoursePackagePayment.getCourseId()); |
| | | course.setCourseName(tCoursePackagePayment.getCourseName()); |
| | | course.setTotalNums(ToolUtil.isEmpty(tCoursePackagePayment.getTotalCourseNums()) ? 0 : tCoursePackagePayment.getTotalCourseNums()); |
| | |
| | | course.setPeriodOfValidity(tCoursePackagePayment.getPeriodOfValidity()); |
| | | courseList.add(course); |
| | | } |
| | | |
| | | } |
| | | classInfoVo.setCourseList(courseList); |
| | | List<ExerciseVideo> stuCourseOfVideoList = voclClient.getStuCourseOfVideoList(coursePackIds); |
| | |
| | | TCoursePackage tCoursePackage = tcpService.getById(tCoursePackagePayment.getCoursePackageId()); |
| | | StuCourseResp resp = new StuCourseResp(); |
| | | resp.setCourseId(tCoursePackage.getId()); |
| | | resp.setId(tCoursePackagePayment.getId()); |
| | | resp.setCourseName(tCoursePackage.getName()); |
| | | resp.setTotalCourseNums(tCoursePackagePayment.getTotalClassHours()); |
| | | resp.setResidueNums(tCoursePackagePayment.getLaveClassHours()); |
| | |
| | | .groupBy("coursePackageId")); |
| | | if (list.size() > 0){ |
| | | for (TCoursePackagePayment tCoursePackagePayment : list) { |
| | | CoursePackageStudent packageStudent = cspsService.getOne(new LambdaQueryWrapper<CoursePackageStudent>() |
| | | List<CoursePackageStudent> packageStudent = cspsService.list(new LambdaQueryWrapper<CoursePackageStudent>() |
| | | .eq(CoursePackageStudent::getAppUserId, courseRest.getAppUserId()) |
| | | .eq(CoursePackageStudent::getStudentId,courseRest.getStuId()) |
| | | .eq(CoursePackageStudent::getCoursePackagePaymentId,tCoursePackagePayment.getId()) |
| | | .eq(CoursePackageStudent::getCoursePackageId,tCoursePackagePayment.getCoursePackageId())); |
| | | if (ToolUtil.isEmpty(packageStudent) || (ToolUtil.isNotEmpty(packageStudent) && packageStudent.getReservationStatus() != 1)){ |
| | | if (ToolUtil.isEmpty(packageStudent) || (ToolUtil.isNotEmpty(packageStudent) && packageStudent.get(0).getReservationStatus() == 1)){ |
| | | // 没有预约过的/已经取消了的 |
| | | TCoursePackage tCoursePackage = tcpService.getById(tCoursePackagePayment.getCoursePackageId()); |
| | | CoursePackagePaymentConfig paymentConfig = icppcService.getOne(new QueryWrapper<CoursePackagePaymentConfig>() |
| | |
| | | if(null == userIdFormRedis){ |
| | | return ResultUtil.tokenErr(); |
| | | } |
| | | Integer couponId = request.getConponId(); |
| | | if(couponId==null || couponId==0){ |
| | | request.setConponId(null); |
| | | } |
| | | return packagePaymentService.ContinuationOrpaymentCourse(userIdFormRedis,request); |
| | | }catch (Exception e){ |
| | | return ResultUtil.runErr(); |
| | |
| | | |
| | | // 2.0 送课时 |
| | | @PostMapping("/base/coursePack/sendHours") |
| | | public Boolean sendHours(@RequestBody String s){ |
| | | public Integer sendHours(@RequestBody String s){ |
| | | String[] split = s.split("_"); |
| | | TCoursePackagePayment byId = packagePaymentService.getById(Integer.valueOf(split[0])); |
| | | TCoursePackagePayment byId = packagePaymentService.getById(Long.valueOf(split[0])); |
| | | byId.setTotalClassHours(byId.getTotalClassHours()+Integer.valueOf(split[2])); |
| | | return packagePaymentService.updateById(byId); |
| | | boolean b = packagePaymentService.updateHoursById(byId,Integer.valueOf(split[2])); |
| | | if(b){ |
| | | return 1; |
| | | }else { |
| | | |
| | | return 0; |
| | | } |
| | | } |
| | | |
| | | |
| | |
| | | package com.dsh.course.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import lombok.Data; |
| | |
| | | * 主键 |
| | | */ |
| | | @TableId(value = "id", type = IdType.NONE) |
| | | @TableField(updateStrategy = FieldStrategy.NEVER) |
| | | private Long id; |
| | | /** |
| | | * 业务编号 |
| | |
| | | |
| | | @Data |
| | | public class StuCourseResp { |
| | | private Long id; |
| | | |
| | | @ApiModelProperty(value = "课包id") |
| | | private Integer courseId; |
| | |
| | | void updateUseTime(@Param("id")Long id, @Param("date") Date date); |
| | | |
| | | List<Integer> getStudentIds(@Param("id")Integer payId); |
| | | |
| | | boolean updateHoursById(@Param("id") Long id, @Param("i") int i); |
| | | } |
| | |
| | | void updateUseTime(Long id, Date date); |
| | | |
| | | List<Integer> getStudentIds(Integer payId); |
| | | |
| | | boolean updateHoursById(TCoursePackagePayment byId, int i); |
| | | |
| | | } |
| | |
| | | .eq("appUserId",appUserId )); |
| | | System.out.println(tCoursePackagePayments); |
| | | if (tCoursePackagePayments.size() > 0){ |
| | | for (TCoursePackagePayment tCoursePackagePayment : tCoursePackagePayments) { |
| | | TCoursePackage coursePackage = tcpmapper.selectById(tCoursePackagePayment.getCoursePackageId()); |
| | | Store store = stoClient.queryStoreById(coursePackage.getStoreId()); |
| | | RegisterCourseVo registerCourseVo = new RegisterCourseVo(); |
| | | // 2.0 |
| | | registerCourseVo.setType(coursePackage.getType()); |
| | | try { |
| | | for (TCoursePackagePayment tCoursePackagePayment : tCoursePackagePayments) { |
| | | TCoursePackage coursePackage = tcpmapper.selectById(tCoursePackagePayment.getCoursePackageId()); |
| | | Store store = stoClient.queryStoreById(coursePackage.getStoreId()); |
| | | RegisterCourseVo registerCourseVo = new RegisterCourseVo(); |
| | | // 2.0 |
| | | registerCourseVo.setType(coursePackage.getType()); |
| | | |
| | | registerCourseVo.setCoursePayId(tCoursePackagePayment.getId()); |
| | | registerCourseVo.setCoursePackageId(tCoursePackagePayment.getCoursePackageId()); |
| | | registerCourseVo.setCoursePackTypeId(coursePackage.getCoursePackageTypeId()); |
| | | registerCourseVo.setPackageImg(coursePackage.getCoverDrawing()); |
| | | String storeAndCourse = coursePackage.getName()+"("+ store.getName() +")"; |
| | | registerCourseVo.setCourseNameStore(storeAndCourse); |
| | | registerCourseVo.setCoursePayId(tCoursePackagePayment.getId()); |
| | | registerCourseVo.setCoursePackageId(tCoursePackagePayment.getCoursePackageId()); |
| | | registerCourseVo.setCoursePackTypeId(coursePackage.getCoursePackageTypeId()); |
| | | registerCourseVo.setPackageImg(coursePackage.getCoverDrawing()); |
| | | String storeAndCourse = coursePackage.getName()+"("+ store.getName() +")"; |
| | | registerCourseVo.setCourseNameStore(storeAndCourse); |
| | | // registerCourseVo.setCourseTime(coursePackage.getClassStartTime()+"-"+coursePackage.getClassEndTime()); |
| | | // 2.0 |
| | | registerCourseVo.setCourseTime(new SimpleDateFormat("yyyy-MM-dd").format(tCoursePackagePayment.getInsertTime())); |
| | | Coach coach = coachClient.queryCoachById(coursePackage.getCoachId()); |
| | | registerCourseVo.setCourseTeacher(ToolUtil.isEmpty(coach) ? "" : coach.getName()); |
| | | List<CoursePackageStudent> coursePackageStudents = cpsMapper.selectList(new QueryWrapper<CoursePackageStudent>() |
| | | .eq("coursePackageId",coursePackage.getId()) |
| | | .eq("studentId",appUserId )); |
| | | if (coursePackageStudents.size() > 0 ){ |
| | | registerCourseVo.setCourseNums(coursePackageStudents.size() * 2); |
| | | // 2.0 |
| | | registerCourseVo.setCourseTime(new SimpleDateFormat("yyyy-MM-dd").format(tCoursePackagePayment.getInsertTime())); |
| | | Coach coach = coachClient.queryCoachById(coursePackage.getCoachId()); |
| | | registerCourseVo.setCourseTeacher(ToolUtil.isEmpty(coach) ? "" : coach.getName()); |
| | | List<CoursePackageStudent> coursePackageStudents = cpsMapper.selectList(new QueryWrapper<CoursePackageStudent>() |
| | | .eq("coursePackageId",coursePackage.getId()) |
| | | .eq("studentId",appUserId )); |
| | | if (coursePackageStudents.size() > 0 ){ |
| | | registerCourseVo.setCourseNums(coursePackageStudents.size() * 2); |
| | | } |
| | | registerCourseVo.setPayStatus(tCoursePackagePayment.getPayStatus()); |
| | | courseVos.add(registerCourseVo); |
| | | } |
| | | registerCourseVo.setPayStatus(tCoursePackagePayment.getPayStatus()); |
| | | courseVos.add(registerCourseVo); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | } |
| | | |
| | | if (ToolUtil.isNotEmpty(courseTypeId.getSearch())){ |
| | |
| | | return this.baseMapper.getStudentIds(payId); |
| | | } |
| | | |
| | | @Override |
| | | public boolean updateHoursById(TCoursePackagePayment byId, int i) { |
| | | return this.baseMapper.updateHoursById(byId.getId(),i); |
| | | } |
| | | |
| | | |
| | | } |
| | |
| | | set useTime = #{date} |
| | | where id = #{id} |
| | | </update> |
| | | <update id="updateHoursById"> |
| | | update t_course_package_payment set totalClassHours =totalClassHours +#{i},classHours =classHours+#{i},laveClassHours =laveClassHours+#{i} where id =#{id} |
| | | </update> |
| | | |
| | | |
| | | <select id="queryCountNumber" resultType="int"> |
| | |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date insertTime; |
| | | |
| | | @TableField("operatorId") |
| | | private Integer operatorId; |
| | | @TableField("typeName") |
| | | private String typeName; |
| | | @TableField("nextName") |
| | | private String nextName; |
| | | @TableField("ishalf") |
| | | private Integer ishalf; |
| | | @TableField("cashPriceOne") |
| | | private Double cashPriceOne; |
| | | @TableField("playPaiCoinOne") |
| | | private Double playPaiCoinOne; |
| | | @TableField("halfName") |
| | | private String halfName; |
| | | @TableField("introduce") |
| | | private String introduce; |
| | | @TableField("imgs") |
| | | private String imgs; |
| | | @TableField("ids") |
| | | private String ids; |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.course.mapper; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.dsh.guns.modular.system.model.TOperatorCity; |
| | | |
| | | /** |
| | | * <p> |
| | | * 运营商 Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-22 |
| | | */ |
| | | public interface TOperatorCityMapper extends BaseMapper<TOperatorCity> { |
| | | |
| | | } |
| | |
| | | import com.dsh.guns.modular.system.service.IRegionService; |
| | | import com.dsh.guns.modular.system.service.IStoreService; |
| | | import com.dsh.guns.modular.system.util.OBSUploadUtil; |
| | | import com.dsh.guns.modular.system.util.OssUploadUtil; |
| | | import com.dsh.guns.modular.system.util.ResultUtil; |
| | | import org.apache.commons.beanutils.ConvertUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | if (imgFile != null){ |
| | | String originalFilename = imgFile.getOriginalFilename(); |
| | | String newName = originalFilename.substring(imgFile.getOriginalFilename().lastIndexOf(".")); |
| | | String url = OBSUploadUtil.inputStreamUpload(imgFile); |
| | | String url = OssUploadUtil.ossUpload("img/",imgFile); |
| | | Map<String, String> map = new HashMap<String, String>(); |
| | | //是否上传成功 |
| | | map.put("state", "SUCCESS"); |
| | |
| | | @Autowired |
| | | private TStoreOtherService storeOtherService; |
| | | |
| | | |
| | | @Autowired |
| | | private TOperatorService tOperatorService; |
| | | |
| | | |
| | | /** |
| | |
| | | model.addAttribute("list",list); |
| | | String roleid = UserExt.getUser().getRoleid(); |
| | | model.addAttribute("role",roleid); |
| | | List<TOperator> list1 = tOperatorService.list(); |
| | | model.addAttribute("yysList",list1); |
| | | return PREFIX + "tShop_add.html"; |
| | | } |
| | | @RequestMapping("/tShop_add_one") |
| | |
| | | return PREFIX + "tShop_add_one.html"; |
| | | } |
| | | @RequestMapping("/tShop_add_two") |
| | | public String tCompetitionAddTwo(Model model) { |
| | | public String tCompetitionAddTwo(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"; |
| | | return PREFIX + "TShop_edit_three.html"; |
| | | } |
| | | |
| | | |
| | |
| | | TStore byId = storeService.getById(id); |
| | | model.addAttribute("item",byId); |
| | | List<TCity> list = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId, 0)); |
| | | model.addAttribute("list",list); |
| | | TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getProvinceCode())); |
| | | List<TCity> list1 = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId,one.getId())); |
| | | |
| | | // 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){ |
| | | model.addAttribute("list1",list3); |
| | | }else { |
| | | 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); |
| | | } |
| | | CityListQuery cityListQuery = new CityListQuery(); |
| | | cityListQuery.setOffset(1); |
| | | cityListQuery.setLimit(10000); |
| | | cityListQuery.setCityCode(byId.getCityCode()); |
| | | Page<TCityManager> list2 = cityClient.list(cityListQuery); |
| | | model.addAttribute("list1",list1); |
| | | |
| | | List<TOperator> list1 = tOperatorService.list(); |
| | | model.addAttribute("yysList",list1); |
| | | |
| | | model.addAttribute("list2",list2.getRecords()); |
| | | String roleid = UserExt.getUser().getRoleid(); |
| | | model.addAttribute("role",roleid); |
| | | model.addAttribute("role",roleid); |
| | | model.addAttribute("time",byId.getStartTime()+" - "+byId.getEndTime()); |
| | | User byId1 = userMapper.selectById(byId.getStoreStaffId()); |
| | | model.addAttribute("city",byId1); |
| | | model.addAttribute("type",1); |
| | | return PREFIX + "tShop_edit.html"; |
| | | } |
| | | @RequestMapping("/tShop_update1/{id}") |
| | | public String tCityUpdate1(@PathVariable Integer id, Model model) { |
| | | TStoreOther byId = storeOtherService.getById(id); |
| | | model.addAttribute("item",byId); |
| | | return PREFIX + "tShop_edit_one.html"; |
| | | } |
| | | |
| | | |
| | |
| | | model.addAttribute("list1",list1); |
| | | |
| | | return PREFIX + "tShop_edit_two.html"; |
| | | } |
| | | @RequestMapping("/tShop_update_one1/{id}") |
| | | public String tCityUpdateOne1(@PathVariable Integer id, Model model) { |
| | | TStoreOtherConfigTrue byId = tStoreOtherConfigTrueService.getById(id); |
| | | TTurn one = tTurnService.getOne(new LambdaQueryWrapper<TTurn>().eq(TTurn::getName, byId.getName())); |
| | | // page list |
| | | List<TTurn> list = tTurnService.list(new LambdaQueryWrapper<TTurn>().eq(TTurn::getPid, one.getId())); |
| | | // type list |
| | | List<TTurn> list1 = tTurnService.list(new LambdaQueryWrapper<TTurn>().eq(TTurn::getPid, byId.getPageId())); |
| | | model.addAttribute("item",byId); |
| | | model.addAttribute("list",list); |
| | | model.addAttribute("list1",list1); |
| | | |
| | | return PREFIX + "tShop_add_three.html"; |
| | | } |
| | | |
| | | |
| | |
| | | page.setRecords(list); |
| | | return super.packForBT(page); |
| | | } |
| | | @RequestMapping(value = "/listTwo1") |
| | | @ResponseBody |
| | | public Object listTwo1(Integer id) { |
| | | Page<TStoreOtherConfigTrue> page = new PageFactory<TStoreOtherConfigTrue>().defaultPage(); |
| | | List<TStoreOtherConfigTrue> list = tStoreOtherConfigTrueService.page(page,new LambdaQueryWrapper<TStoreOtherConfigTrue>().eq(TStoreOtherConfigTrue::getPid, id).eq(TStoreOtherConfigTrue::getState,1)).getRecords(); |
| | | page.setRecords(list); |
| | | return super.packForBT(page); |
| | | } |
| | | |
| | | @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) { |
| | | try { |
| | | if(ToolUtil.isNotEmpty(tStore.getProvinceCode())) { |
| | | TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, tStore.getProvinceCode())); |
| | | TOperatorCity byId = operatorCityService.getById(tStore.getProvinceCode()); |
| | | TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, byId.getCode())); |
| | | tStore.setProvince(one.getName()); |
| | | TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, tStore.getCityCode())); |
| | | tStore.setCity(one1.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()); |
| | | } |
| | | } |
| | | tStore.setStartTime(time.split(" - ")[0]); |
| | | tStore.setEndTime(time.split(" - ")[1]); |
| | |
| | | |
| | | @RequestMapping(value = "/update") |
| | | @ResponseBody |
| | | public Object update(TStore tStore,String time,String userName,String userPhone,String ids,Integer type,Integer yyId) { |
| | | public Object update(TStore tStore,String time,String userName,String userPhone,String ids,Integer type,Integer yyId,String lat,String lon) { |
| | | try { |
| | | TStore byId = storeService.getById(tStore.getId()); |
| | | |
| | | if(ToolUtil.isNotEmpty(tStore.getProvinceCode())) { |
| | | TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, tStore.getProvinceCode())); |
| | | TOperatorCity tOperatorCity = operatorCityService.getById(tStore.getProvinceCode()); |
| | | TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, tOperatorCity.getCode())); |
| | | tStore.setProvince(one.getName()); |
| | | TCity one1 = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, tStore.getCityCode())); |
| | | tStore.setCity(one1.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()); |
| | | }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()); |
| | | } |
| | | } |
| | | tStore.setStartTime(time.split(" - ")[0]); |
| | | tStore.setEndTime(time.split(" - ")[1]); |
| | |
| | | user.setName(userName); |
| | | user.setPhone(userPhone); |
| | | userMapper.updateById(user); |
| | | tStore.setLon(lon); |
| | | tStore.setLat(lat); |
| | | storeService.updateById(tStore); |
| | | return new SuccessTip<>(); |
| | | }catch (Exception e){ |
| | |
| | | } |
| | | } |
| | | |
| | | @Autowired |
| | | private TOperatorCityService operatorCityService; |
| | | |
| | | @RequestMapping(value = "/onChange1") |
| | | @ResponseBody |
| | | public Object onChange1(Integer oneId) { |
| | | try { |
| | | List<TOperatorCity> list = operatorCityService.list(new LambdaQueryWrapper<TOperatorCity>().eq(TOperatorCity::getOperatorId, oneId).eq(TOperatorCity::getType, 1)); |
| | | return list; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | |
| | | @RequestMapping(value = "/onChange2") |
| | | @ResponseBody |
| | | public Object onChange2(Integer oneId) { |
| | | 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(list.size()==0){ |
| | | TOperatorCity tOperatorCity = list1.get(0); |
| | | Integer code = tOperatorCity.getCode(); |
| | | TCity one = cityService.getOne(new LambdaQueryWrapper<TCity>().eq(TCity::getCode, code)); |
| | | List<TCity> list2 = cityService.list(new LambdaQueryWrapper<TCity>().eq(TCity::getParentId, one.getId())); |
| | | return list2; |
| | | }else { |
| | | return list; |
| | | } |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | |
| | | |
| | | @RequestMapping(value = "/cancel") |
| | | public Object cancel(Integer id) { |
| | |
| | | public Object delete1(Integer id) { |
| | | try { |
| | | storeService.delete1(id); |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | @ResponseBody |
| | | @RequestMapping(value = "/deleteTwo") |
| | | public Object delete2(Integer id) { |
| | | try { |
| | | TStoreOtherConfigTrue byId = tStoreOtherConfigTrueService.getById(id); |
| | | |
| | | byId.setState(2); |
| | | tStoreOtherConfigTrueService.updateById(byId); |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | @ResponseBody |
| | | @RequestMapping(value = "/del") |
| | | public Object del(Integer id) { |
| | | try { |
| | | storeOtherService.removeById(id); |
| | | tStoreOtherConfigTrueService.remove(new LambdaQueryWrapper<TStoreOtherConfigTrue>().eq(TStoreOtherConfigTrue::getPid,id)); |
| | | |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | |
| | | TStore byId = storeService.getById(id); |
| | | byId.setState(1); |
| | | storeService.updateById(byId); |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | |
| | | @RequestMapping(value = "/unfreeze1") |
| | | @ResponseBody |
| | | public Object unfreeze1(Integer id,Integer type) { |
| | | try { |
| | | TStoreOther byId = storeOtherService.getById(id); |
| | | byId.setState(type); |
| | | storeOtherService.updateById(byId); |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | |
| | | * ajax.set("type",type); |
| | | * ajax.set("turnId",turnId); |
| | | * ajax.set("sort",sort); |
| | | * @param id |
| | | * @return |
| | | */ |
| | | @RequestMapping(value = "/addConfigOne") |
| | |
| | | return ERROR; |
| | | } |
| | | } |
| | | @RequestMapping(value = "/addConfig1") |
| | | @ResponseBody |
| | | public Object addConfig1(String name,Integer id) { |
| | | try { |
| | | TStoreOther byId = storeOtherService.getById(id); |
| | | byId.setName( |
| | | name |
| | | ); |
| | | storeOtherService.updateById(byId); |
| | | |
| | | |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | @RequestMapping(value = "/updateConfigOne") |
| | | @ResponseBody |
| | | public Object addConfigOne(String url,String name,Integer page,Integer type,String turnId,Integer sort,Integer id) { |
| | |
| | | return ERROR; |
| | | } |
| | | } |
| | | @RequestMapping(value = "/updateConfigOne3") |
| | | @ResponseBody |
| | | public Object addConfigOne3(String url,String name,Integer page,Integer type,String turnId,Integer sort,Integer id) { |
| | | try { |
| | | TStoreOtherConfigTrue byId = tStoreOtherConfigTrueService.getById(id); |
| | | if(ToolUtil.isNotEmpty(url)){ |
| | | byId.setUrl(url); |
| | | } |
| | | byId.setName(name); |
| | | TTurn byId1 = tTurnService.getById(page); |
| | | TTurn byId2 = tTurnService.getById(type); |
| | | byId.setPage(byId1.getName()); |
| | | byId.setType(byId2.getName()); |
| | | byId.setTurnId(turnId); |
| | | byId.setSort(sort); |
| | | byId.setPageId(page); |
| | | byId.setTypeId(type); |
| | | tStoreOtherConfigTrueService.updateById(byId); |
| | | return SUCCESS_TIP; |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | |
| | | } |
| | | Integer objectType = UserExt.getUser().getObjectType(); |
| | | Integer objectId = UserExt.getUser().getObjectId(); |
| | | |
| | | List<TOperator> list = tOperatorService.list(); |
| | | model.addAttribute("yysList",list); |
| | | |
| | | model.addAttribute("userType",objectType); |
| | | HashSet<String> set = new HashSet<String>(list1); |
| | | QueryWrapper<TSiteType> wrapper = new QueryWrapper<>(); |
| | |
| | | model.addAttribute("objectType",objectType); |
| | | model.addAttribute("objectId",objectId); |
| | | model.addAttribute("stores",stores); |
| | | |
| | | String nextName = site.getNextName(); |
| | | ArrayList<String> strings1 = new ArrayList<>(); |
| | | for (String s : nextName.split(",")) { |
| | | strings1.add(s); |
| | | } |
| | | model.addAttribute("nextNames",strings1); |
| | | |
| | | |
| | | String halfNames = site.getHalfName(); |
| | | ArrayList<String> strings2 = new ArrayList<>(); |
| | | String[] split = halfNames.split(","); |
| | | String halfName=null; |
| | | for (int i = 0; i < split.length; i++) { |
| | | if(i==0){ |
| | | halfName = split[0]; |
| | | }else { |
| | | strings2.add(split[i]); |
| | | } |
| | | } |
| | | model.addAttribute("halfNames",strings2); |
| | | model.addAttribute("halfName",halfName); |
| | | |
| | | return PREFIX + "TSite_edit.html"; |
| | | } |
| | | |
| | |
| | | list1.add(cityManager.getProvince()); |
| | | } |
| | | Integer objectType = UserExt.getUser().getObjectType(); |
| | | List<TOperator> list = tOperatorService.list(); |
| | | model.addAttribute("yysList",list); |
| | | Integer objectId = UserExt.getUser().getObjectId(); |
| | | model.addAttribute("userType",objectType); |
| | | HashSet<String> set = new HashSet<String>(list1); |
| | |
| | | } |
| | | } |
| | | |
| | | @RequestMapping(value = "/getChangeOne") |
| | | @ResponseBody |
| | | public Object getChangeOne(Integer oneId) { |
| | | try { |
| | | return storeService.list(new LambdaQueryWrapper<TStore>().eq(TStore::getOperatorId,oneId).eq(TStore::getState,1)); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ERROR; |
| | | } |
| | | } |
| | | |
| | | // 选择市后 获取对应账号 |
| | | @RequestMapping(value = "/accountChangeNext") |
| | | @ResponseBody |
| | |
| | | */ |
| | | @RequestMapping(method = RequestMethod.POST, path = "/uploadImg") |
| | | @ResponseBody |
| | | public ResultUtil uploadImg(@RequestPart("file") MultipartFile picture, HttpServletResponse response) { |
| | | String value = ""; |
| | | public String uploadImg(@RequestPart("file") MultipartFile picture) { |
| | | String pictureName = ""; |
| | | try { |
| | | value = OssUploadUtil.ossUpload("img/", picture); |
| | | pictureName = OssUploadUtil.ossUpload("img/", picture); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | } |
| | | System.out.println("图片返回地址-------"+value); |
| | | Map<String, String> map = new HashMap<>(); |
| | | map.put("value",value); |
| | | // return ResultUtil.success(0,map); |
| | | return ResultUtil.getResult(0,null,null,map); |
| | | return pictureName; |
| | | } |
| | | |
| | | |
New file |
| | |
| | | package com.dsh.guns.modular.system.model; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import java.io.Serializable; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | /** |
| | | * <p> |
| | | * 运营商 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-22 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @Accessors(chain = true) |
| | | @TableName("t_operator_city") |
| | | public class TOperatorCity extends Model<TOperatorCity> { |
| | | |
| | | private static final long serialVersionUID=1L; |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | /** |
| | | * 名称 |
| | | */ |
| | | private String name; |
| | | |
| | | /** |
| | | * code |
| | | */ |
| | | private Integer code; |
| | | |
| | | /** |
| | | * 1 省 2市 |
| | | */ |
| | | private Integer type; |
| | | |
| | | private Integer pid; |
| | | |
| | | @TableField("operatorId") |
| | | private Integer operatorId; |
| | | |
| | | |
| | | @Override |
| | | protected Serializable pkVal() { |
| | | return this.id; |
| | | } |
| | | |
| | | } |
| | |
| | | @TableField("insertTime") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private Date insertTime; |
| | | |
| | | @TableField("operatorId") |
| | | private Integer operatorId; |
| | | @TableField("typeName") |
| | | private String typeName; |
| | | @TableField("nextName") |
| | | private String nextName; |
| | | @TableField("ishalf") |
| | | private Integer ishalf; |
| | | @TableField("cashPriceOne") |
| | | private Double cashPriceOne; |
| | | @TableField("playPaiCoinOne") |
| | | private Double playPaiCoinOne; |
| | | @TableField("halfName") |
| | | private String halfName; |
| | | @TableField("introduce") |
| | | private String introduce; |
| | | @TableField("imgs") |
| | | private String imgs; |
| | | @TableField("ids") |
| | | private String ids; |
| | | } |
New file |
| | |
| | | package com.dsh.guns.modular.system.service; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.dsh.guns.modular.system.model.TOperatorCity; |
| | | |
| | | /** |
| | | * <p> |
| | | * 运营商 服务类 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-22 |
| | | */ |
| | | public interface TOperatorCityService extends IService<TOperatorCity> { |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.guns.modular.system.service.impl; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.dsh.course.mapper.TOperatorCityMapper; |
| | | import com.dsh.guns.modular.system.model.TOperatorCity; |
| | | import com.dsh.guns.modular.system.service.TOperatorCityService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * 运营商 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author administrator0 |
| | | * @since 2023-09-22 |
| | | */ |
| | | @Service |
| | | public class TOperatorCityServiceImpl extends ServiceImpl<TOperatorCityMapper, TOperatorCity> implements TOperatorCityService { |
| | | |
| | | } |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.dsh.course.mapper.TOperatorCityMapper"> |
| | | |
| | | |
| | | </mapper> |
| | |
| | | <div class="col-sm-9"> |
| | | <select class="form-control" id="account" name="account" onchange="TCarInfoDlg.oneChange1(this)"> |
| | | <option value="">选择运营商</option> |
| | | @for(i in yysList){ |
| | | <option value="${i.id}">${i.name}</option> |
| | | @} |
| | | </select> |
| | | </div> |
| | | </div> |
| | | <div class="form-group" id="provinceCode"> |
| | | <label class="col-sm-3 control-label">所在省:</label> |
| | | <div class="col-sm-9"> |
| | | <select class="form-control" id="pCode" name="pCode" onchange="TCarInfoDlg.oneChange(this)"> |
| | | <option value="">选择省</option> |
| | | @for(obj in list){ |
| | | <option value="${obj.code}">${obj.name}</option> |
| | | @} |
| | | <select class="form-control" id="pCode" name="pCode" onchange="TCarInfoDlg.oneChange2(this)"> |
| | | </select> |
| | | </div> |
| | | </div> |
| | |
| | | </div> |
| | | <div class="form-group" style="margin-left:-410px"> |
| | | <label class="col-sm-3 control-label">内容设置:</label> |
| | | <#button name="添加" icon="fa-plus" clickFun="TCompetition.openAdd()"/> |
| | | <#button name="添加" icon="fa-plus" clickFun="TCompetition.openAdd(1)"/> |
| | | </div> |
| | | <#table id="TCompetitionOtherTable"/> |
| | | |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal" id="carInfoForm"> |
| | | <input id="id" value="${item.id}" hidden> |
| | | <input id="name1" value="${item.name}" hidden> |
| | | |
| | | |
| | | <#avatar id="url" name="图片(推荐像素宽度316px)" avatarImg="${item.url}"/> |
| | | |
| | | <div class="input-group" style="margin-left: 342px;"> |
| | | <div class="input-group-btn"> |
| | | <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button"> |
| | | 跳转模块 |
| | | </button> |
| | | </div> |
| | | <select class="form-control" id="name" style="width: 400px;" onclick="updateType(this)"> |
| | | <option value="不跳转">不跳转</option> |
| | | <option value="加入玩湃">加入玩湃</option> |
| | | <option value="开始课程">开始课程</option> |
| | | <option value="使用福利">使用福利</option> |
| | | <option value="探索玩湃">探索玩湃</option> |
| | | </select> |
| | | </div> |
| | | |
| | | <div class="input-group" style="margin-left: 342px;" id="t1" hidden > |
| | | <div class="input-group-btn"> |
| | | <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button"> |
| | | 跳转页面 |
| | | </button> |
| | | </div> |
| | | <select class="form-control" id="page" style="width: 400px;" onchange="updateOne(this)"> |
| | | @for(obj in list){ |
| | | <option value="${obj.id}" ${obj.id == item.pageId ? 'selected=selected' : ''}>${obj.name}</option> |
| | | @} |
| | | </select> |
| | | </div> |
| | | |
| | | <div class="input-group" style="margin-left: 342px;" id="t2" > |
| | | <div class="input-group-btn"> |
| | | <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button"> |
| | | 跳转类型 |
| | | </button> |
| | | </div> |
| | | <select class="form-control" id="type" style="width: 400px;" > |
| | | @for(obj in list1){ |
| | | <option value="${obj.id}" ${obj.id == item.typeId ? 'selected=selected' : ''}>${obj.name}</option> |
| | | @} |
| | | </select> |
| | | </div> |
| | | |
| | | <div class="form-group" id="t3" > |
| | | <label class="col-sm-3 control-label">跳转ID:</label> |
| | | <div class="col-sm-9"> |
| | | <input class="form-control" id="turnId" name="turnId" type="text" style="width: 400px;" value="${item.turnId}"> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="form-group" id="t4" > |
| | | <label class="col-sm-3 control-label">排序:</label> |
| | | <div class="col-sm-9"> |
| | | <input class="form-control" id="sort" name="sort" type="text" style="width: 400px;" value="${item.sort}"> |
| | | |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10 col-sm-offset-5"> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TCompetition.close()"/> |
| | | <#button btnCss="info" name="确认" id="ensure" icon="fa-check" clickFun="TCompetition.addSubmit3()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/modular/system/tShop/tShopOtherTwo.js"></script> |
| | | <script> |
| | | laydate.render({ |
| | | elem: '#time', |
| | | range:true |
| | | }); |
| | | |
| | | function updateType(e) { |
| | | let name = $("#name").val() |
| | | console.log(name |
| | | ) |
| | | if(name =='不跳转'){ |
| | | $("#t1").hide() |
| | | $("#t2").hide() |
| | | $("#t3").hide() |
| | | }else { |
| | | $("#t1").show() |
| | | $("#t2").show() |
| | | $("#t3").show() |
| | | |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/typeChange", function(data){ |
| | | if(data!=null){ |
| | | var content; |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#page").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("name",oneId); |
| | | ajax.start(); |
| | | } |
| | | } |
| | | |
| | | |
| | | function updateOne(e) { |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/typeChangeOne", function(data){ |
| | | if(data!=null){ |
| | | var content1; |
| | | $.each(data, function(k,v) { |
| | | content1 += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#type").empty().append(content1); |
| | | } |
| | | }); |
| | | ajax.set("id",oneId); |
| | | ajax.start(); |
| | | } |
| | | |
| | | window.onload = function() { |
| | | $("#name").val($("#name1").val()); |
| | | } |
| | | </script> |
| | | @} |
| | |
| | | <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)"> |
| | | <option value="">选择运营商</option> |
| | | @for(obj in yysList){ |
| | | <option value="${obj.id}" ${obj.id == item.operatorId ? 'selected=selected' : ''}>${obj.name}</option> |
| | | @} |
| | | </select> |
| | | </div> |
| | | </div> |
| | | <div class="form-group" id="provinceCode"> |
| | | <label class="col-sm-3 control-label">所在省:</label> |
| | | <div class="col-sm-9"> |
| | | <select class="form-control" id="pCode" name="pCode" onchange="TCarInfoDlg.oneChange(this)"> |
| | | <option value="">选择省</option> |
| | | <select class="form-control" id="pCode" name="pCode" onchange="TCarInfoDlg.oneChange2(this)"> |
| | | @for(obj in list){ |
| | | <option value="${obj.code}" ${obj.code == item.provinceCode ? 'selected=selected' : ''}>${obj.name}</option> |
| | | <option value="${obj.id}" ${obj.code == item.provinceCode ? 'selected=selected' : ''}>${obj.name}</option> |
| | | @} |
| | | </select> |
| | | </div> |
| | |
| | | <div class="form-group" id="cityCode"> |
| | | <label class="col-sm-3 control-label">所在市:</label> |
| | | <div class="col-sm-9"> |
| | | <select class="form-control" id="cCode" name="cCode" onchange="TCarInfoDlg.oneChangeNext(this)"> |
| | | <select class="form-control" id="cCode" name="cCode" > |
| | | <option value="">选择市</option> |
| | | @for(obj in list1){ |
| | | <option value="${obj.code}" ${obj.code == item.cityCode ? 'selected=selected' : ''}>${obj.name}</option> |
| | | <option value="${obj.id}" ${obj.code == item.cityCode ? 'selected=selected' : ''}>${obj.name}</option> |
| | | @} |
| | | </select> |
| | | </div> |
| | |
| | | @} |
| | | <#input id="name" name="门店名称" type="text" value="${item.name}"/> |
| | | <#input id="phone" name="联系电话" type="text" value="${item.phone}"/> |
| | | <div hidden id="longitude" value="${item.lon}"></div> |
| | | <div hidden id="latitude" value="${item.lat}"></div> |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">门店地址:</label> |
| | | <div class="col-sm-9"> |
| | |
| | | range:true |
| | | }); |
| | | |
| | | window.onload = function(){ |
| | | var OBJradio=document.getElementsByName("type") |
| | | for(i=0;i<OBJradio.length;i++){//循环查找这个radio |
| | | if($("#type").val()==OBJradio[i].value){//判断是否与radio的值相同 |
| | | OBJradio[i].checked=true//修改选中状态 |
| | | } |
| | | } |
| | | } |
| | | let id = "https://evmoto.obs.ap-southeast-4.myhuaweicloud.com:443/b1d6f9e362414d1b895d916657776573.png,https://evmoto.obs.ap-southeast-4.myhuaweicloud.com:443/b1d6f9e362414d1b895d916657776573.png" |
| | | let id = "${item.realPicture}" |
| | | let obj = [] |
| | | |
| | | |
| | |
| | | }, |
| | | methods: { |
| | | handleAvatarSuccess(res, file) { |
| | | file.url =file.response |
| | | TCarInfoDlg.goodsPicArray.push(file); |
| | | console.log(TCarInfoDlg.goodsPicArray) |
| | | }, |
| | | changeImg(){ |
| | | var i = id.split(",") |
| | |
| | | let obj={ |
| | | fileName:i[j], |
| | | uuid:i[j], |
| | | url:i[j] |
| | | url:i[j], |
| | | response:i[j], |
| | | } |
| | | this.imageUrl2.push(obj) |
| | | |
| | |
| | | TCarInfoDlg.goodsPicArray = TCarInfoDlg.goodsPicArray.filter(item => { |
| | | return item.uid != file.uid; |
| | | }); |
| | | |
| | | }, |
| | | }, |
| | | created() { |
| | | this.changeImg() |
| | | TCarInfoDlg.goodsPicArray = this.imageUrl2 |
| | | }, |
| | | }); |
| | | |
| | |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | window.onload = function(){ |
| | | console.log("${item.operatorId}") |
| | | var OBJradio=document.getElementsByName("type") |
| | | if("${item.operatorId}"==0){ |
| | | OBJradio[0].checked=true |
| | | }else { |
| | | OBJradio[1].checked=true |
| | | $("#yys").show() |
| | | } |
| | | |
| | | |
| | | var OBJradio=document.getElementsByName("ishalf") |
| | | if($("#type_").val()==1){ |
| | | $("#halfCode").show() |
| | | } |
| | | for(i=0;i<OBJradio.length;i++){//循环查找这个radio |
| | | if($("#type_").val()==OBJradio[i].value){//判断是否与radio的值相同 |
| | | OBJradio[i].checked=true//修改选中状态 |
| | | } |
| | | } |
| | | |
| | | |
| | | } |
| | | </script> |
| | | <script type="application/javascript"> |
| | | |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal" id="carInfoForm"> |
| | | <input id="id" value="${id}" hidden> |
| | | <div class="form-group" style="margin-left:-410px"> |
| | | <label class="col-sm-3 control-label">板块名称:</label> |
| | | <div class="col-sm-9"> |
| | | <input class="form-control" id="name" name="name" type="text" style="width: 400px;" value="${item.name}"> |
| | | |
| | | </div> |
| | | </div> |
| | | <div class="form-group" style="margin-left:-410px"> |
| | | <label class="col-sm-3 control-label">内容设置:</label> |
| | | <#button name="添加" icon="fa-plus" clickFun="TCompetition.openAdd(2)"/> |
| | | </div> |
| | | <#table id="TCompetitionOtherTable"/> |
| | | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10 col-sm-offset-5"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TCompetition.addSubmit4()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TCompetition.close()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/modular/system/tShop/tShopOtherTwo.js"></script> |
| | | <script> |
| | | laydate.render({ |
| | | elem: '#time', |
| | | range:true |
| | | }); |
| | | |
| | | |
| | | </script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal" id="carInfoForm"> |
| | | |
| | | <input id="id" value="${id}" hidden> |
| | | <#avatar id="url" name="图片(推荐像素宽度316px)"/> |
| | | |
| | | <div class="input-group" style="margin-left: 342px;"> |
| | | <div class="input-group-btn"> |
| | | <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button"> |
| | | 跳转模块 |
| | | </button> |
| | | </div> |
| | | <select class="form-control" id="name" style="width: 400px;" onclick="updateType(this)"> |
| | | <option value="" selected disabled>选择跳转模块</option> |
| | | <option value="不跳转">不跳转</option> |
| | | <option value="加入玩湃">加入玩湃</option> |
| | | <option value="开始课程">开始课程</option> |
| | | <option value="使用福利">使用福利</option> |
| | | <option value="探索玩湃">探索玩湃</option> |
| | | </select> |
| | | </div> |
| | | |
| | | <div class="input-group" style="margin-left: 342px;" id="t1" hidden > |
| | | <div class="input-group-btn"> |
| | | <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button"> |
| | | 跳转页面 |
| | | </button> |
| | | </div> |
| | | <select class="form-control" id="page" style="width: 400px;" onchange="updateOne(this)"> |
| | | |
| | | </select> |
| | | </div> |
| | | |
| | | <div class="input-group" style="margin-left: 342px;" id="t2" > |
| | | <div class="input-group-btn"> |
| | | <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button"> |
| | | 跳转类型 |
| | | </button> |
| | | </div> |
| | | <select class="form-control" id="type" style="width: 400px;" > |
| | | |
| | | </select> |
| | | </div> |
| | | |
| | | <div class="form-group" id="t3" > |
| | | <label class="col-sm-3 control-label">跳转ID:</label> |
| | | <div class="col-sm-9"> |
| | | <input class="form-control" id="turnId" name="turnId" type="text" style="width: 400px;"> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="form-group" id="t4" > |
| | | <label class="col-sm-3 control-label">排序:</label> |
| | | <div class="col-sm-9"> |
| | | <input class="form-control" id="sort" name="sort" type="text" style="width: 400px;"> |
| | | |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10 col-sm-offset-5"> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TCompetition.close()"/> |
| | | <#button btnCss="info" name="保存" id="ensure" icon="fa-check" clickFun="TCompetition.addSubmit3()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | |
| | | </div> |
| | | <script src="${ctxPath}/modular/system/tShop/tShopOtherTwo.js"></script> |
| | | <script> |
| | | laydate.render({ |
| | | elem: '#time', |
| | | range:true |
| | | }); |
| | | |
| | | function updateType(e) { |
| | | let name = $("#name").val() |
| | | console.log(name |
| | | ) |
| | | if(name =='不跳转'){ |
| | | $("#t1").hide() |
| | | $("#t2").hide() |
| | | $("#t3").hide() |
| | | }else { |
| | | $("#t1").show() |
| | | $("#t2").show() |
| | | $("#t3").show() |
| | | |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/typeChange", function(data){ |
| | | if(data!=null){ |
| | | var content; |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#page").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("name",oneId); |
| | | ajax.start(); |
| | | } |
| | | } |
| | | |
| | | |
| | | function updateOne(e) { |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/typeChangeOne", function(data){ |
| | | if(data!=null){ |
| | | var content1; |
| | | $.each(data, function(k,v) { |
| | | content1 += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#type").empty().append(content1); |
| | | } |
| | | }); |
| | | ajax.set("id",oneId); |
| | | ajax.start(); |
| | | } |
| | | </script> |
| | | @} |
| | |
| | | </div> |
| | | |
| | | |
| | | <div>首页其他板块设置</div> |
| | | <div style="font-size: x-large;">首页其他板块设置</div> |
| | | <#button name="添加" icon="fa-plus" clickFun="TCompetition.openAddTCompetition(id)"/> |
| | | <#button name="编辑" icon="fa-edit" clickFun="TCompetition.openTCompetitionDetail()" space="true"/> |
| | | <#button name="删除" icon="fa-remove" clickFun="TCompetition.freeze()" space="true"/> |
| | | <#button name="开启" icon="fa-remove" clickFun="TCompetition.unfreeze()" space="true"/> |
| | | <#button name="关闭" icon="fa-remove" clickFun="TCompetition.info()" space="true"/> |
| | | <#button name="编辑" icon="fa-edit" clickFun="TCompetition.openTCompetitionDetail1()" space="true"/> |
| | | <#button name="删除" icon="fa-remove" clickFun="TCompetition.del()" space="true"/> |
| | | <#button name="开启" icon="fa-remove" clickFun="TCompetition.unfreeze1(1)" space="true"/> |
| | | <#button name="关闭" icon="fa-remove" clickFun="TCompetition.unfreeze1(2)" space="true"/> |
| | | <#table id="TCompetitionOtherTable"/> |
| | | |
| | | |
| | |
| | | <div class="form-group" > |
| | | <label class="col-sm-3 control-label">*所属运营商:</label> |
| | | <div class="col-sm-8"> |
| | | <select style="width: 300px" class="form-control" id="yys" name="yys" onchange="TSite.oneChangeYys(2)"> |
| | | <select style="width: 300px" class="form-control" id="yys" name="yys" onchange="TSite.oneChangeYys(this)"> |
| | | <option style="width: 300px" value="">选择运营商</option> |
| | | @for(obj in yysList){ |
| | | <option style="width: 300px" value="${obj.id}">${obj.name}</option> |
| | | @} |
| | | </select> |
| | | <input type="checkbox" value="0" name="pt">平台</input> |
| | | <input type="checkbox" value="0" name="pt" onchange="TSite.oneChangeYys(this)">平台</input> |
| | | </div> |
| | | </div> |
| | | @} |
| | |
| | | <div class="form-group" > |
| | | <label class="col-sm-3 control-label">*场地类型:</label> |
| | | <div class="col-sm-9"> |
| | | <select style="width: 300px" class="form-control" id="siteTypeOne" name = "typeId"> |
| | | <select style="width: 300px" class="form-control" id="siteTypeOne" name = "typeId" onchange="updateTime1()"> |
| | | <option value="普通场地">普通场地</option> |
| | | <option value="智慧场地">智慧场地</option> |
| | | </select> |
| | |
| | | <label class="col-sm-3 control-label">*可预约时间段:</label> |
| | | <!-- <input style="width: 300px" class="form-control" type="time">--> |
| | | <div class="col-sm-9" style="display: flex"> |
| | | <input style="width: 136px;" value="开始时间" id="start-time" class="form-control" type="time"> |
| | | <input style="width: 136px;" value="开始时间" id="start-time" class="form-control" type="time" onchange="updateTime(1)"> |
| | | <span style="margin-top: 7px"> 至 </span> |
| | | <input style="width: 136px;" value="结束时间" id="end-time" class="form-control" type="time"> |
| | | <input style="width: 136px;" value="结束时间" id="end-time" class="form-control" type="time" onchange="updateTime(2)"> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | </div> |
| | | @} |
| | | @if(objectType==1){ |
| | | <#input style="width: 300px" id="name" name="*添加闸机:" placeholder="请输入闸机ID" type="text"/> |
| | | <#input style="width: 300px" id="ids" name="*添加闸机:" placeholder="请输入闸机ID" type="text"/> |
| | | @} |
| | | <div class="form-group" style=" margin-left: 17%;" > |
| | | <label class="col-sm-1 control-label">场地说明:</label> |
| | |
| | | <script src="${ctxPath}/js/elementui/index.js"></script> |
| | | <link rel="stylesheet" href="${ctxPath}/js/elementui/index.css"> |
| | | <script> |
| | | var vue2 = new Vue({ |
| | | el: '#app1', |
| | | props: { |
| | | // 数量限制 |
| | | limit: { |
| | | type: Number, |
| | | default: 2 |
| | | }, |
| | | }, |
| | | data: { |
| | | autoUpload: true,//自动上传 |
| | | imageUrl1: '',//模型数据,用于上传图片完成后图片预览 |
| | | dialogVisible: false |
| | | }, |
| | | methods: { |
| | | handleAvatarSuccess(res, file) { |
| | | TSite.goodsPicArray.push(file); |
| | | }, |
| | | beforeAvatarUpload(file) { |
| | | const isLt2M = file.size / 1024 / 1024 < 10; |
| | | if (!isLt2M) { |
| | | this.$message.error('上传图片大小不能超过 10MB!'); |
| | | } |
| | | return isLt2M; |
| | | }, |
| | | handleRemove(file, fileList) { |
| | | TSite.goodsPicArray = TSite.goodsPicArray.filter(item => { |
| | | return item.uid != file.uid; |
| | | }); |
| | | }, |
| | | }, |
| | | created() { |
| | | }, |
| | | }); |
| | | laydate.render({ |
| | | elem: '#start-time', type: "time", format: "HH:mm", ready: formatminutes |
| | | }); |
| | | laydate.render({ |
| | | elem: '#end-time' |
| | | , type: "time", format: "HH:mm", ready: formatminutes |
| | | }); |
| | | |
| | | function addBox() { |
| | | var a=" <div class=\"col-sm-8 control-label\" id=\"far\">\n" + |
| | |
| | | endTime.disabled = true; |
| | | } |
| | | }); |
| | | function updateTime1() { |
| | | $("#end-time").val(''); |
| | | $("#start-time").val(''); |
| | | } |
| | | |
| | | function updateTime(e) { |
| | | let one = $("#siteTypeOne").val() |
| | | var timeInputs = document.querySelectorAll('input[type="time"]'); |
| | | console.log(timeInputs) |
| | | var selectedTime=''; |
| | | if(e==1){ |
| | | var selectedTime = $("#start-time").val(); |
| | | }else { |
| | | var selectedTime = $("#end-time").val(); |
| | | } |
| | | |
| | | |
| | | var hour = selectedTime.split(':')[0]; |
| | | var minute = selectedTime.split(':')[1]; |
| | | if(one=="普通场地"){ |
| | | console.log( |
| | | one |
| | | ) |
| | | if (minute < 30 &&minute>0) { |
| | | minute = '30'; |
| | | } else if (minute >30) { |
| | | hour++; |
| | | minute = '00'; |
| | | if (hour<10){ |
| | | hour = '0'+hour; |
| | | } |
| | | } |
| | | }else { |
| | | console.log( |
| | | one,minute |
| | | ) |
| | | if (minute <= 15 && minute>0) { |
| | | console.log(1) |
| | | minute = '15'; |
| | | }else if(minute<=30){ |
| | | console.log(2) |
| | | minute = '30'; |
| | | }else if(minute<=45){ |
| | | console.log(3) |
| | | minute = '45'; |
| | | }else if (minute >45) { |
| | | console.log(4) |
| | | hour++; |
| | | minute = '00'; |
| | | if (hour<10){ |
| | | hour = '0'+hour; |
| | | } |
| | | } |
| | | } |
| | | if(e==1){ |
| | | $("#start-time").val(hour + ':' + minute) |
| | | }else { |
| | | $("#end-time").val(hour + ':' + minute) |
| | | } |
| | | } |
| | | </script> |
| | | @} |
| | |
| | | @layout("/common/_container.html"){ |
| | | <script type="text/javascript" src="http://webapi.amap.com/maps?v=1.4.15&key=77b37f0753049c4e712ea79a24e0719c"></script> |
| | | <style> |
| | | .avatar-uploader .el-upload { |
| | | border: 1px dashed #d9d9d9; |
| | | border-radius: 6px; |
| | | cursor: pointer; |
| | | position: relative; |
| | | height: 100px; |
| | | width: 100px; |
| | | overflow: hidden; |
| | | } |
| | | |
| | | .avatar-uploader .el-upload:hover { |
| | | border-color: #409EFF; |
| | | } |
| | | .avatar-uploader-icon { |
| | | font-size: 28px; |
| | | color: #8c939d; |
| | | width: 100px; |
| | | height: 100px; |
| | | line-height: 100px; |
| | | margin-top: 32px; |
| | | text-align: center; |
| | | } |
| | | .avatar { |
| | | width: 100px; |
| | | height: 100px; |
| | | display: block; |
| | | } |
| | | |
| | | .col-sm-12 { |
| | | margin-top: 20px; |
| | | } |
| | | |
| | | .col-sm-12 select { |
| | | height: 33px; |
| | | } |
| | | #app1{ |
| | | margin-left: 255px; |
| | | } |
| | | |
| | | |
| | | </style> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal" id="carInfoForm"> |
| | | |
| | | <input id="type_" value="${list.ishalf}" hidden> |
| | | |
| | | @if(objectType == 1){ |
| | | <div class="form-group" id="provinceCode"> |
| | | <label class="col-sm-3 control-label">*所在省:</label> |
| | | <div class="col-sm-9"> |
| | | <select style="width: 300px" class="form-control" id="pCode" name="pCode" onchange="TSiteInfo.oneChange(this)"> |
| | | <!-- <option style="width: 300px" value="${list.province}">${list.province}</option>--> |
| | | @for(obj in province){ |
| | | <option value="${obj}" ${obj == list.province ? 'selected=selected' : ''}>${obj}</option> |
| | | <!-- <option style="width: 300px" value="${obj}">${obj}</option>--> |
| | | @} |
| | | </select> |
| | | </div> |
| | | </div> |
| | | <div class="form-group" id="cityCode"> |
| | | <label class="col-sm-3 control-label">*所在市:</label> |
| | | <div class="col-sm-9"> |
| | | <select style="width: 300px" class="form-control" id="cCode" name="cCode" onchange="TSiteInfo.oneChangeNext(this)"> |
| | | @for(obj in city1){ |
| | | <option value="${obj.city}" ${obj.city == list.city ? 'selected=selected' : ''}>${obj.city}</option> |
| | | <!-- <option style="width: 300px" value="${obj.city}">${obj.city}</option>--> |
| | | @} |
| | | </select> |
| | | </div> |
| | | </div> |
| | | <div class="form-group" > |
| | | <label class="col-sm-3 control-label">*所属账号:</label> |
| | | <div class="col-sm-9"> |
| | | <select style="width: 300px" class="form-control" id="account" name="account"> |
| | | @for(obj in accounts){ |
| | | <option style="width: 300px" value="${obj.id}">${obj.name}</option> |
| | | <label class="col-sm-3 control-label">*所属运营商:</label> |
| | | <div class="col-sm-8"> |
| | | <select style="width: 300px" class="form-control" id="yys" name="yys" onchange="TSiteInfo.oneChangeYys(this)"> |
| | | <option style="width: 300px" value="">选择运营商</option> |
| | | @for(obj in yysList){ |
| | | <option value="${obj.id}" ${obj.id == list.operatorId ? 'selected=selected' : ''}>${obj.name}</option> |
| | | @} |
| | | </select> |
| | | <input type="checkbox" value="0" name="pt" id="pt" onchange="TSiteInfo.oneChangeYys(this)">平台</input> |
| | | </div> |
| | | </div> |
| | | @} |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="form-group" id="siteMore" style=" margin-left: 255px;"> |
| | | <div class="form-group">多场地配置:<i class="fa fa-plus" onclick="addBox()"></i></div> |
| | | @for(n in nextNames){ |
| | | <div class="col-sm-8 control-label" id="far"> |
| | | <label class="col-sm-2 control-label">*单个场地名</label> |
| | | <div class="col-sm-3"> |
| | | <input type="text" name="name1" class="form-control newWidth" value="${n}"/> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <i class="col-sm-1 fa fa-remove" onclick="delBox(this)" style="margin-top:10px"></i> |
| | | </div> |
| | | </div> |
| | | @} |
| | | </div> |
| | | |
| | | |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">是否可预定半场:</label> |
| | | <div class="col-sm-9"> |
| | | <input type="radio" name="ishalf" value="2" checked onclick="updateHalf(1)"> 否 |
| | | <input type="radio" name="ishalf" value="1" onclick="updateHalf(2)"> 是 |
| | | </div> |
| | | </div> |
| | | <div id="halfCode" hidden> |
| | | <div class="form-group" style="margin-left: 100px;" > |
| | | <label class="col-sm-3 control-label">*现金价格:</label> |
| | | <div class="col-sm-9" style="display: flex;"> |
| | | <input style="width: 300px" class="form-control" id="cashPriceOne" name="playPaiCoin" placeholder="请输入价格" type="text" value="${list.cashPriceOne}"> |
| | | <span style="margin-left: 5px;margin-top: 5px">元/半小时</span> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="form-group" style="margin-left: 100px;"> |
| | | <label class="col-sm-3 control-label">*玩湃币价格:</label> |
| | | <div class="col-sm-9" style="display: flex;"> |
| | | <input style="width: 300px" class="form-control" id="playPaiCoinOne" name="playPaiCoin" placeholder="请输入价格" type="text" value="${list.playPaiCoinOne}"> |
| | | <span style="margin-left: 5px;margin-top: 5px">币/半小时</span> |
| | | </div> |
| | | </div> |
| | | |
| | | |
| | | <div class="form-group" id="halfName" > |
| | | <label class="col-sm-3 control-label">*半场名称:</label> |
| | | <div class="col-sm-8" style="display: flex;"> |
| | | <input style="width: 240px" class="form-control" name="name2" type="text" value="${halfName}"><i class="fa fa-plus" onclick="addBox1()" style="margin-left: 32px;margin-top: 10px;"></i> |
| | | </div> |
| | | </div> |
| | | @for(h in halfNames){ |
| | | <div class="form-group" > |
| | | <label class="col-sm-3 control-label">*半场名称:</label> |
| | | <div class="col-sm-8" style="display: flex;"> |
| | | <input style="width: 240px" class="form-control" name="name2" type="text" value="${h}"> <i class="col-sm-1 fa fa-remove" onclick="delBox(this)" style="margin-top:10px"></i> |
| | | </div> |
| | | </div> |
| | | @} |
| | | </div> |
| | | |
| | | |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">*场地责任险有效期:</label> |
| | | <div class="col-sm-9"> |
| | |
| | | action="/tCouponManage/uploadPic" |
| | | list-type="picture-card" |
| | | accept="." |
| | | :file-list="imageUrl2" |
| | | :on-success="handleAvatarSuccess" |
| | | :on-remove="handleRemove"> |
| | | <i class="el-icon-plus"></i> |
| | | </el-upload> |
| | | <el-dialog :visible.sync="dialogVisible"> |
| | | <img width="100%" :src="imageUrl1" alt=""> |
| | | <img width="100%" :src="imageUrl2" alt=""> |
| | | </el-dialog> |
| | | </div> |
| | | </div> |
| | |
| | | @} |
| | | </div> |
| | | @if(objectType==1){ |
| | | <#input style="width: 300px" id="name" name="*添加闸机:" placeholder="请输入闸机ID" type="text"/> |
| | | <div class="form-group" style="margin-left: 205px;"> |
| | | <label class="col-sm-1 control-label">*添加闸机:</label> |
| | | <div class="col-sm-9"> |
| | | <input class="form-control" id="ids" name="ids" value="${list.ids}" type="text" style="width: 300px" placeholder="请输入闸机ID"> |
| | | </div> |
| | | </div> |
| | | @} |
| | | <div class="form-group" style="margin-left: 13%;display: inline-flex;margin-top: 16px;" > |
| | | <label class="col-sm-2 control-label">场地说明:</label> |
| | | <div class="col-sm-5" style="margin-left: -35px;"> |
| | | <textarea type="text/plain" id="editor" style="height: 300px;width: 800px;">${list.introduce}</textarea> |
| | | </div> |
| | | </div> |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10 col-sm-offset-5" > |
| | | @if(type==1){ |
| | |
| | | <script src="${ctxPath}/js/elementui/index.js"></script> |
| | | <link rel="stylesheet" href="${ctxPath}/js/elementui/index.css"> |
| | | <script> |
| | | let id = "${list.imgs}" |
| | | let obj = [] |
| | | |
| | | var vue2 = new Vue({ |
| | | el: '#app1', |
| | | props: { |
| | |
| | | data: { |
| | | autoUpload: true,//自动上传 |
| | | imageUrl1: '',//模型数据,用于上传图片完成后图片预览 |
| | | imageUrl2: [], |
| | | dialogVisible: false |
| | | }, |
| | | methods: { |
| | | handleAvatarSuccess(res, file) { |
| | | TCarInfoDlg.goodsPicArray.push(file); |
| | | file.url =file.response |
| | | TSiteInfo.goodsPicArray.push(file); |
| | | }, |
| | | changeImg(){ |
| | | var i = id.split(",") |
| | | for (let j = 0; j <i.length; j++) { |
| | | let obj={ |
| | | fileName:i[j], |
| | | uuid:i[j], |
| | | url:i[j], |
| | | response:i[j], |
| | | } |
| | | this.imageUrl2.push(obj) |
| | | |
| | | } |
| | | }, |
| | | beforeAvatarUpload(file) { |
| | | const isLt2M = file.size / 1024 / 1024 < 10; |
| | |
| | | return isLt2M; |
| | | }, |
| | | handleRemove(file, fileList) { |
| | | TCarInfoDlg.goodsPicArray = TCarInfoDlg.goodsPicArray.filter(item => { |
| | | TSiteInfo.goodsPicArray = TSiteInfo.goodsPicArray.filter(item => { |
| | | return item.uid != file.uid; |
| | | }); |
| | | }, |
| | | }, |
| | | created() { |
| | | this.changeImg() |
| | | TSiteInfo.goodsPicArray = this.imageUrl2 |
| | | }, |
| | | }); |
| | | |
| | | var selectElement = document.getElementById('store'); |
| | | var startTime = document.getElementById('start-time'); |
| | | var endTime = document.getElementById('end-time'); |
| | |
| | | endTime.disabled = true; |
| | | } |
| | | }); |
| | | |
| | | |
| | | window.onload = function(){ |
| | | console.log("${list.operatorId}") |
| | | if("${list.operatorId}"==0){ |
| | | console.log(233232) |
| | | $("#pt").attr('checked', true) |
| | | } |
| | | |
| | | |
| | | var OBJradio=document.getElementsByName("ishalf") |
| | | if($("#type_").val()==1){ |
| | | $("#halfCode").show() |
| | | } |
| | | for(i=0;i<OBJradio.length;i++){//循环查找这个radio |
| | | if($("#type_").val()==OBJradio[i].value){//判断是否与radio的值相同 |
| | | OBJradio[i].checked=true//修改选中状态 |
| | | } |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | function addBox1() { |
| | | var a=" <div class=\"col-sm-8 control-label\" id=\"far\" style=\"margin-left: 210px;\">\n" + |
| | | " <label class=\"col-sm-2 control-label\">*半场名称:</label>\n" + |
| | | " <div class=\"col-sm-3\">\n" + |
| | | " <input type=\"text\" name=\"name2\" class=\"form-control newWidth\" style=\"margin-left: 8px;width: 240px;\"/> \n" + |
| | | " </div> \n" + |
| | | " <div class=\"col-sm-1\">\n" + |
| | | " <i class=\"col-sm-1 fa fa-remove\" onclick=\"delBox(this)\" style=\"margin-top:10px\"></i>\n" + |
| | | " </div> \n" + |
| | | " </div> " |
| | | |
| | | |
| | | $("#halfName").append($(a)) |
| | | } |
| | | function addBox() { |
| | | var a=" <div class=\"col-sm-8 control-label\" id=\"far\">\n" + |
| | | " <label class=\"col-sm-2 control-label\">*单个场地名</label>\n" + |
| | | " <div class=\"col-sm-3\">\n" + |
| | | " <input type=\"text\" name=\"name1\" class=\"form-control newWidth\" /> \n" + |
| | | " </div> \n" + |
| | | " <div class=\"col-sm-1\">\n" + |
| | | " <i class=\"col-sm-1 fa fa-remove\" onclick=\"delBox(this)\" style=\"margin-top:10px\"></i>\n" + |
| | | " </div> \n" + |
| | | " </div> " |
| | | |
| | | |
| | | $("#siteMore").append($(a)) |
| | | } |
| | | |
| | | function delBox(o) { |
| | | $(o).parent("div").parent("div").remove() |
| | | } |
| | | </script> |
| | | @} |
| | |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | TCompetition.openTCompetitionDetail1 = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title:'编辑', |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tShop/tShop_update1/' + TCompetition.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | TCompetition.info = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | TCompetition.del = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/del", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("删除失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | TCompetition.unfreeze = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/unfreeze", function (data) { |
| | |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | TCompetition.unfreeze1 = function (e) { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/unfreeze1", function (data) { |
| | | Feng.success("操作成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("操作失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",this.seItem.id); |
| | | ajax.set("type",e); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | TCompetition.reload = function () { |
| | | if (this.check()) { |
| | | let id = this.seItem.id |
| | |
| | | |
| | | TCompetition.delete1= function (e) { |
| | | console.log(e) |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/deleteOne", function (data) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/deleteTwo", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.start(); |
| | | } |
| | | |
| | | |
| | | |
| | | TCompetition.close = function() { |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | } |
New file |
| | |
| | | /** |
| | | * 车辆管理管理初始化 |
| | | */ |
| | | var TCompetition = { |
| | | id: "TCompetitionOtherTable", //表格id |
| | | seItem: null, //选中的条目 |
| | | table: null, |
| | | layerIndex: -1 |
| | | }; |
| | | var language =1 |
| | | var role =1 |
| | | /** |
| | | * 初始化表格的列 |
| | | */ |
| | | TCompetition.initColumn = function () { |
| | | return [ |
| | | {field: 'selectItem', radio: true}, |
| | | {title: 'id', field: 'id', visible: false, align: 'center', valign: 'middle', |
| | | }, |
| | | {title: '图片', field: 'url', visible: role==1?true:false, align: 'center', valign: 'middle', |
| | | }, |
| | | {title: '跳转模块', field: 'name', visible: role==1?true:false, align: 'center', valign: 'middle', |
| | | }, |
| | | {title: '跳转页面', field: 'page', visible: role==1?true:false, align: 'center', valign: 'middle', |
| | | }, |
| | | {title: '排序', field: 'sort', visible: role==1?true:false, align: 'center', valign: 'middle', |
| | | }, |
| | | {title: '操作', visible: role==1?true:false, align: 'center', valign: 'middle', |
| | | formatter:function (value,row) { |
| | | return '<a href="javascript:void(0);" style="color: blue" onclick="TCompetition.delete1(' + row.id +')">删除 </a> <a href="javascript:void(0);" style="color: blue" onclick="TCompetition.openTCompetitionDetail(' + row.id +')">编辑</a>' |
| | | } |
| | | }, |
| | | ]; |
| | | }; |
| | | function currentTime(timestamp){ |
| | | var time = timestamp + ''; |
| | | if(time.length != 13){ |
| | | timestamp = timestamp * 1000; |
| | | } |
| | | var date = new Date(timestamp);; |
| | | var Y = date.getFullYear() + '-'; |
| | | var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-'; |
| | | var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + ' '; |
| | | |
| | | var h = (date.getHours() < 10 ? '0' + (date.getHours()) : date.getHours()) + ':'; |
| | | var m = (date.getMinutes() < 10 ? '0' + (date.getMinutes()) : date.getMinutes()) + ':'; |
| | | var s = (date.getSeconds() < 10 ? '0' + (date.getSeconds()) : date.getSeconds()); |
| | | var strDate = Y + M + D + h + m + s; |
| | | return strDate |
| | | } |
| | | |
| | | function currentTime1(timestamp){ |
| | | var time = timestamp + ''; |
| | | if(time.length != 13){ |
| | | timestamp = timestamp * 1000; |
| | | } |
| | | var date = new Date(timestamp);; |
| | | var Y = date.getFullYear() + '-'; |
| | | var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-'; |
| | | var D = (date.getDate() < 10 ? '0' + (date.getDate()) : date.getDate()) + ' '; |
| | | |
| | | var h = (date.getHours() < 10 ? '0' + (date.getHours()) : date.getHours()) + ':'; |
| | | var m = (date.getMinutes() < 10 ? '0' + (date.getMinutes()) : date.getMinutes()) + ':'; |
| | | var s = (date.getSeconds() < 10 ? '0' + (date.getSeconds()) : date.getSeconds()); |
| | | var strDate = Y + M + D ; |
| | | return strDate |
| | | } |
| | | |
| | | TCompetition.delete1= function (e) { |
| | | console.log(e) |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/deleteTwo", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("删除失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",e); |
| | | ajax.start(); |
| | | } |
| | | /** |
| | | * 检查是否选中 |
| | | */ |
| | | TCompetition.check = function () { |
| | | var selected = $('#' + this.id).bootstrapTable('getSelections'); |
| | | if(selected.length == 0){ |
| | | Feng.info("请先选中表格中的某一记录!"); |
| | | return false; |
| | | }else{ |
| | | TCompetition.seItem = selected[0]; |
| | | return true; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 点击添加车辆管理 |
| | | */ |
| | | TCompetition.openAdd = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '添加内容', |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tShop/tShop_add_two?id='+$("#id").val() |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 打开查看车辆管理详情 |
| | | */ |
| | | TCompetition.openTCompetitionDetail = function (e) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title:'编辑', |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tShop/tShop_update_one1/' + e |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | TCompetition.info = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title:'详情', |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tShop/tShop_info/' + TCompetition.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | TCompetition.gift = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title:'免费福利', |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tShop/tShop_gift/' + TCompetition.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | TCompetition.indexSet = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title:'首页设置', |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tShop/tShop_indexSet/' + TCompetition.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 删除车辆管理 |
| | | */ |
| | | TCompetition.delete = function () { |
| | | if (this.check()) { |
| | | var nickname = TCompetition.seItem.carLicensePlate; |
| | | if (nickname == "" || nickname == null || nickname == undefined){ |
| | | nickname = "该车辆"; |
| | | }else{ |
| | | nickname = "【"+nickname+"】"; |
| | | } |
| | | swal({ |
| | | title: language==1?"您是否确认删除" + nickname + "?":(language==2?"Are you sure to delete the" + nickname + "?":"Apakah Anda pasti akan menghapus" + nickname + "?"), |
| | | text: language==1?"请谨慎操作!":(language==2?' Please operate with caution!':'Harap beroperasi dengan hati -hati!'), |
| | | type: "warning", |
| | | showCancelButton: true, |
| | | confirmButtonColor: "#DD6B55", |
| | | confirmButtonText: language==1?"删除":(language==2?'Delete':'Hapus'), |
| | | closeOnConfirm: true |
| | | }, function () { |
| | | var ajax = new $ax(Feng.ctxPath + "/TCompetition/delete", function (data) { |
| | | if(language==1){ |
| | | swal("删除成功", "您已经成功删除了" + nickname + "。", "success"); |
| | | }else if(language==2){ |
| | | swal("Delete succeeded!", "You have successfully deleted it" + nickname + "。", "success"); |
| | | }else { |
| | | swal("Hapus berhasil!", "Anda berhasil menghapus" + nickname + "。", "success"); |
| | | } |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | if(language==1){ |
| | | swal("删除失败", data.responseJSON.message + "!", "warning"); |
| | | }else if(language==2){ |
| | | swal("Failed to delete", data.responseJSON.message + "!", "warning"); |
| | | }else { |
| | | swal("Hapus Gagal", data.responseJSON.message + "!", "warning"); |
| | | } |
| | | |
| | | }); |
| | | ajax.set("TCompetitionId",TCompetition.seItem.id); |
| | | ajax.start(); |
| | | }); |
| | | } |
| | | }; |
| | | TCompetition.oneChange = function (e) { |
| | | console.log(111) |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tCompetition/onChange", function(data){ |
| | | if(data!=null){ |
| | | if(language==1){ |
| | | var content='<option value="">选择市</option>'; |
| | | }else if(language==2){ |
| | | var content='<option value="">Choose your franchisee</option>'; |
| | | }else { |
| | | var content='<option value="">Pilih franchisee Anda</option>'; |
| | | } |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.code+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#cCode").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | } |
| | | TCompetition.oneChangeNext = function (e) { |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tCompetition/oneChangeNext", function(data){ |
| | | if(data!=null){ |
| | | if(language==1){ |
| | | var content='<option value="">选择账号</option>'; |
| | | }else if(language==2){ |
| | | var content='<option value="">Choose your franchisee</option>'; |
| | | }else { |
| | | var content='<option value="">Pilih franchisee Anda</option>'; |
| | | } |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#account").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | } |
| | | |
| | | TCompetition.freeze = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/freeze", function (data) { |
| | | Feng.success("冻结成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("冻结失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | TCompetition.unfreeze = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/unfreeze", function (data) { |
| | | Feng.success("解冻成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("解冻失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | TCompetition.reload = function () { |
| | | if (this.check()) { |
| | | let id = this.seItem.id |
| | | var operation = function(){ |
| | | var ajax = new $ax(Feng.ctxPath + "/tCity/pwd", function (data) { |
| | | Feng.success("重置成功!"); |
| | | TCompetition.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("重置失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",id); |
| | | ajax.start(); |
| | | } |
| | | Feng.confirm("确认重置密码?重置后密码为:a123456", operation); |
| | | } |
| | | |
| | | }; |
| | | |
| | | TCompetition.saveAllImg = function (e) { |
| | | var id = $("#id").val() |
| | | var px1 = $("#px1").val() |
| | | var px2 = $("#px2").val() |
| | | var px3 = $("#px3").val() |
| | | var px4 = $("#px4").val() |
| | | var px5 = $("#px5").val() |
| | | var px6 = $("#px6").val() |
| | | var px7 = $("#px7").val() |
| | | var px8 = $("#px8").val() |
| | | var c1 = $("#c1").val() |
| | | var c2 = $("#c2").val() |
| | | var c3 = $("#c3").val() |
| | | var c4 = $("#c4").val() |
| | | var c5 = $("#c5").val() |
| | | var c6 = $("#c6").val() |
| | | var c7 = $("#7").val() |
| | | var c8 = $("#c8").val() |
| | | var r1 = document.querySelector('input[name="r1"]').checked; |
| | | var r2 = document.querySelector('input[name="r2"]').checked; |
| | | var r3 = document.querySelector('input[name="r3"]').checked; |
| | | var r4 = document.querySelector('input[name="r4"]').checked; |
| | | var r5 = document.querySelector('input[name="r5"]').checked; |
| | | var r6 = document.querySelector('input[name="r6"]').checked; |
| | | var r7 = document.querySelector('input[name="r7"]').checked; |
| | | var r8 = document.querySelector('input[name="r8"]').checked; |
| | | if(r1){ |
| | | r1 =1 |
| | | }else{ |
| | | r1=0 |
| | | } |
| | | if(r2){ |
| | | r2 =1 |
| | | }else{ |
| | | r2=0 |
| | | } |
| | | if(r3){ |
| | | r3 =1 |
| | | }else{ |
| | | r3=0 |
| | | } |
| | | if(r4){ |
| | | r4 =1 |
| | | }else{ |
| | | r4=0 |
| | | } |
| | | if(r5){ |
| | | r5 =1 |
| | | }else{ |
| | | r5=0 |
| | | } |
| | | if(r6){ |
| | | r6 =1 |
| | | }else{ |
| | | r6=0 |
| | | } |
| | | if(r7){ |
| | | r7 =1 |
| | | }else{ |
| | | r7=0 |
| | | } |
| | | if(r8){ |
| | | r8 =1 |
| | | }else{ |
| | | r8=0 |
| | | } |
| | | |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/saveImgAll", function(data){ |
| | | if(data.code == 200){ |
| | | Feng.success("保存成功!"); |
| | | }else{ |
| | | Feng.error(data.msg); |
| | | } |
| | | },function(data){ |
| | | Feng.error("保存失败!" + data.responseJSON.message + "!"); |
| | | |
| | | }); |
| | | ajax.set("id",id); |
| | | ajax.set("px1",px1); |
| | | ajax.set("px2",px2); |
| | | ajax.set("px3",px3); |
| | | ajax.set("px4",px4); |
| | | ajax.set("px5",px5); |
| | | ajax.set("px6",px6); |
| | | ajax.set("px7",px7); |
| | | ajax.set("px8",px8); |
| | | ajax.set("c1",c1); |
| | | ajax.set("c2",c2); |
| | | ajax.set("c3",c3); |
| | | ajax.set("c4",c4); |
| | | ajax.set("c5",c5); |
| | | ajax.set("c6",c6); |
| | | ajax.set("c7",c7); |
| | | ajax.set("c8",c8); |
| | | ajax.set("r1",r1); |
| | | ajax.set("r2",r2); |
| | | ajax.set("r3",r3); |
| | | ajax.set("r4",r4); |
| | | ajax.set("r5",r5); |
| | | ajax.set("r6",r6); |
| | | ajax.set("r7",r7); |
| | | ajax.set("r8",r8); |
| | | ajax.start(); |
| | | } |
| | | |
| | | TCompetition.carInsurance = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: language==1?'车辆保险':(language==2?'Vehicle insurance':'Asuransi kendaraan'), |
| | | area: ['100%', '100%'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/TCompetition/carInsurance?carId=' + TCompetition.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | |
| | | |
| | | |
| | | /** |
| | | * 查询车辆管理列表 |
| | | */ |
| | | TCompetition.search = function () { |
| | | var queryData = {}; |
| | | queryData['provinceCode'] = $("#pCode").val(); |
| | | queryData['cityCode'] = $("#cCode").val(); |
| | | queryData['name'] = $("#name").val(); |
| | | queryData['phone'] = $("#phone").val(); |
| | | queryData['shopName'] = $("#shopName").val(); |
| | | TCompetition.table.refresh({query: queryData}); |
| | | }; |
| | | |
| | | TCompetition.resetSearch = function () { |
| | | $("#pCode").val(""); |
| | | $("#cCode").val(""); |
| | | $("#name").val(""); |
| | | $("#phone").val(""); |
| | | $("#shopName").val(""); |
| | | TCompetition.search(); |
| | | }; |
| | | |
| | | $(function () { |
| | | var defaultColunms = TCompetition.initColumn(); |
| | | |
| | | // 初始化图片上传 |
| | | var carPhoto = new $WebUpload("url"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c2"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c3"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c4"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c5"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c6"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c7"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("c8"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var carPhoto = new $WebUpload("img"); |
| | | carPhoto.setUploadBarId("progressBar"); |
| | | carPhoto.init(); |
| | | var drivingLicensePhoto = new $WebUpload("drivingLicensePhoto"); |
| | | drivingLicensePhoto.setUploadBarId("progressBar"); |
| | | drivingLicensePhoto.init(); |
| | | |
| | | var table = new BSTable(TCompetition.id, "/tShop/listTwo1?id="+$("#id").val(), defaultColunms); |
| | | table.setPaginationType("server"); |
| | | TCompetition.table = table.init(); |
| | | }); |
| | | |
| | | /** |
| | | * 下载模板 |
| | | */ |
| | | TCompetition.uploadCarModel = function () { |
| | | window.location.href = Feng.ctxPath + "/TCompetition/uploadCarModel"; |
| | | } |
| | | |
| | | var agreement = function(){ |
| | | this.init = function(){ |
| | | //模拟上传excel |
| | | $("#uploadEventBtn").unbind("click").bind("click",function(){ |
| | | $("#uploadEventFile").click(); |
| | | }); |
| | | }; |
| | | } |
| | | /** |
| | | * 导入合同 |
| | | */ |
| | | TCompetition.exporTCompetition = function () { |
| | | var uploadEventFile = $("#uploadEventFile").val(); |
| | | if(uploadEventFile == ''){ |
| | | if(language==1){ |
| | | Feng.info("请选择Excel,再上传"); |
| | | }else if(language==2){ |
| | | Feng.info("Please select Excel and upload"); |
| | | }else { |
| | | Feng.info("Silakan pilih Excel dan upload"); |
| | | } |
| | | }else if(uploadEventFile.lastIndexOf(".xls")<0){//可判断以.xls和.xlsx结尾的excel |
| | | if(language==1){ |
| | | Feng.info("只能上传Excel文件"); |
| | | }else if(language==2){ |
| | | Feng.info("Only Excel files can be uploaded"); |
| | | }else { |
| | | Feng.info("Hanya berkas Excel yang dapat diunggah"); |
| | | } |
| | | }else{ |
| | | var url = Feng.ctxPath + '/TCompetition/exporTCompetition'; |
| | | var file = document.querySelector('input[name=file]').files[0]; |
| | | var reader = new FileReader(); |
| | | if (file) { |
| | | var formData = new FormData(); |
| | | formData.append("myfile", file); |
| | | this.sendAjaxRequest(url, 'POST', formData); |
| | | } |
| | | } |
| | | } |
| | | TCompetition.sendAjaxRequest = function(url,type,data){ |
| | | $.ajax({ |
| | | url : url, |
| | | type : type, |
| | | data : data, |
| | | success : function(result) { |
| | | if(result.code==500) { |
| | | Feng.info(result.message); |
| | | }else { |
| | | if(language==1){ |
| | | Feng.success("导入成功!"); |
| | | }else if(language==2){ |
| | | Feng.success("SUCCESSFUL IMPORT!"); |
| | | }else { |
| | | Feng.success("Import berhasil!"); |
| | | } |
| | | } |
| | | TCompetition.table.refresh(); |
| | | }, |
| | | error : function() { |
| | | if(language==1){ |
| | | Feng.error("excel上传失败!"); |
| | | }else if(language==2){ |
| | | Feng.error("Uploading excel Fails. Procedure!"); |
| | | }else { |
| | | Feng.error("Gagal mengunggah excel!"); |
| | | } |
| | | }, |
| | | cache : false, |
| | | contentType : false, |
| | | processData : false |
| | | }); |
| | | }; |
| | | |
| | | var agreement; |
| | | $(function(){ |
| | | agreement = new agreement(); |
| | | agreement.init(); |
| | | }); |
| | | |
| | | /** |
| | | * 导出车辆操作 |
| | | */ |
| | | TCompetition.ouTCompetition = function () { |
| | | var operation = function() { |
| | | window.location.href = Feng.ctxPath + "/TCompetition/ouTCompetition"; |
| | | }; |
| | | if(language==1){ |
| | | Feng.confirm("是否确认导出车辆信息?", operation); |
| | | }else if(language==2){ |
| | | Feng.confirm("Are you sure to export vehicle information?", operation); |
| | | }else { |
| | | Feng.confirm("Apakah Anda pasti akan mengekspor informasi kendaraan?", operation); |
| | | } |
| | | } |
| | | |
| | | TCompetition.addSubmit = function() { |
| | | |
| | | let url = $("#url").val() |
| | | if(url==''){ |
| | | Feng.info("请上传图片") |
| | | return; |
| | | } |
| | | |
| | | let name = $("#name").val() |
| | | console.log(name) |
| | | |
| | | if(name=='' || name ==null){ |
| | | Feng.info("请选择跳转模块") |
| | | return; |
| | | } |
| | | let page = $("#page").val() |
| | | if(page=='' && name !='不跳转'){ |
| | | Feng.info("请选择跳转页面") |
| | | return; |
| | | } |
| | | let type = $("#type").val() |
| | | |
| | | if(type=='' && name !='不跳转'){ |
| | | } |
| | | let turnId = $("#turnId").val() |
| | | |
| | | if( type =='11' || type=='13'|| type=='16'|| type=='19'|| type=='21'|| type=='40'|| type=='43'){ |
| | | Feng.info("请输入跳转ID") |
| | | return; |
| | | } |
| | | let sort = $("#sort").val() |
| | | |
| | | if(sort==''){ |
| | | Feng.info("请输入排序") |
| | | return; |
| | | } |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/addConfigOne", function(data){ |
| | | if(data.code == 200){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TCompetition.table.refresh(); |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | }else{ |
| | | Feng.error(data.msg); |
| | | } |
| | | |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("url",url); |
| | | ajax.set("name",name); |
| | | ajax.set("page",page); |
| | | ajax.set("type",type); |
| | | ajax.set("turnId",turnId); |
| | | ajax.set("sort",sort); |
| | | ajax.start(); |
| | | } |
| | | |
| | | TCompetition.addSubmit1 = function() { |
| | | |
| | | let url = $("#url").val() |
| | | if(url==''){ |
| | | } |
| | | |
| | | let name = $("#name").val() |
| | | console.log(name) |
| | | |
| | | if(name=='' || name ==null){ |
| | | Feng.info("请选择跳转模块") |
| | | return; |
| | | } |
| | | let page = $("#page").val() |
| | | if(page=='' && name !='不跳转'){ |
| | | Feng.info("请选择跳转页面") |
| | | return; |
| | | } |
| | | let type = $("#type").val() |
| | | |
| | | if(type=='' && name !='不跳转'){ |
| | | } |
| | | let turnId = $("#turnId").val() |
| | | |
| | | if( type =='11' || type=='13'|| type=='16'|| type=='19'|| type=='21'|| type=='40'|| type=='43'){ |
| | | if(turnId==""){ |
| | | Feng.info("请输入跳转ID") |
| | | return; |
| | | } |
| | | } |
| | | let sort = $("#sort").val() |
| | | |
| | | if(sort==''){ |
| | | Feng.info("请输入排序") |
| | | return; |
| | | } |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/updateConfigOne", function(data){ |
| | | if(data.code == 200){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TCompetition.table.refresh(); |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | }else{ |
| | | Feng.error(data.msg); |
| | | } |
| | | |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("url",url); |
| | | ajax.set("name",name); |
| | | ajax.set("page",page); |
| | | ajax.set("type",type); |
| | | ajax.set("turnId",turnId); |
| | | ajax.set("sort",sort); |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.start(); |
| | | } |
| | | TCompetition.addSubmit2 = function() { |
| | | |
| | | |
| | | let name = $("#name").val() |
| | | |
| | | if(name=='' || name ==null){ |
| | | Feng.info("请填写板块名称") |
| | | return; |
| | | } |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/addConfig", function(data){ |
| | | if(data.code == 200){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TCompetition.table.refresh(); |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | }else{ |
| | | Feng.error(data.msg); |
| | | } |
| | | |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("name",name); |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.start(); |
| | | } |
| | | TCompetition.addSubmit3 = function() { |
| | | |
| | | let url = $("#url").val() |
| | | if(url==''){ |
| | | } |
| | | |
| | | let name = $("#name").val() |
| | | console.log(name) |
| | | |
| | | if(name=='' || name ==null){ |
| | | Feng.info("请选择跳转模块") |
| | | return; |
| | | } |
| | | let page = $("#page").val() |
| | | if(page=='' && name !='不跳转'){ |
| | | Feng.info("请选择跳转页面") |
| | | return; |
| | | } |
| | | let type = $("#type").val() |
| | | |
| | | if(type=='' && name !='不跳转'){ |
| | | } |
| | | let turnId = $("#turnId").val() |
| | | |
| | | if( type =='11' || type=='13'|| type=='16'|| type=='19'|| type=='21'|| type=='40'|| type=='43'){ |
| | | if(turnId==""){ |
| | | Feng.info("请输入跳转ID") |
| | | return; |
| | | } |
| | | } |
| | | let sort = $("#sort").val() |
| | | |
| | | if(sort==''){ |
| | | Feng.info("请输入排序") |
| | | return; |
| | | } |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/updateConfigOne3", function(data){ |
| | | if(data.code == 200){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TCompetition.table.refresh(); |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | }else{ |
| | | Feng.error(data.msg); |
| | | } |
| | | |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("url",url); |
| | | ajax.set("name",name); |
| | | ajax.set("page",page); |
| | | ajax.set("type",type); |
| | | ajax.set("turnId",turnId); |
| | | ajax.set("sort",sort); |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.start(); |
| | | } |
| | | |
| | | |
| | | TCompetition.addSubmit4 = function() { |
| | | |
| | | |
| | | let name = $("#name").val() |
| | | |
| | | if(name=='' || name ==null){ |
| | | Feng.info("请填写板块名称") |
| | | return; |
| | | } |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/addConfig1", function(data){ |
| | | if(data.code == 200){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TCompetition.table.refresh(); |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | }else{ |
| | | Feng.error(data.msg); |
| | | } |
| | | |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("name",name); |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.start(); |
| | | } |
| | | TCompetition.close = function() { |
| | | parent.layer.close(window.parent.TCompetition.layerIndex); |
| | | } |
| | |
| | | let img = $("#img").val() |
| | | |
| | | |
| | | let imgOne = $("#imgOne").val() |
| | | |
| | | if(imgOne==''){ |
| | | var goodImgs = this.goodsPicArray; |
| | | if(goodImgs.length==0){ |
| | | Feng.info("请上传实景图") |
| | | return; |
| | | } |
| | | var imgOne =""; |
| | | for (let i = 0; i <goodImgs.length; i++) { |
| | | if(i==goodImgs.length-1){ |
| | | imgOne += (goodImgs[i].response) |
| | | }else { |
| | | imgOne+=(goodImgs[i].response+",") |
| | | } |
| | | |
| | | } |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/update", function(data){ |
| | |
| | | ajax.set("userPhone",userPhone); |
| | | ajax.set("coverDrawing",img); |
| | | ajax.set("realPicture",imgOne); |
| | | ajax.set("lat",$("#latitude").val()); |
| | | ajax.set("lon",$("#longitude").val()); |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.set("ids",$("#ids").val()); |
| | | ajax.set("type",OBJradio); |
| | | ajax.set("yyId",$("#account").val()); |
| | | ajax.start(); |
| | | } |
| | | |
| | |
| | | $("#kcModelDiv").hide(); |
| | | } |
| | | } |
| | | |
| | | |
| | | TCarInfoDlg.oneChange1 = function (e) { |
| | | console.log(111) |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/onChange1", function(data){ |
| | | if(data!=null){ |
| | | if(language==1){ |
| | | var content='<option value="">选择省</option>'; |
| | | }else if(language==2){ |
| | | var content='<option value="">Choose your franchisee</option>'; |
| | | }else { |
| | | var content='<option value="">Pilih franchisee Anda</option>'; |
| | | } |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#pCode").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | } |
| | | TCarInfoDlg.oneChange2 = function (e) { |
| | | console.log(111) |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/onChange2", function(data){ |
| | | if(data!=null){ |
| | | if(language==1){ |
| | | var content='<option value="">选择市</option>'; |
| | | }else if(language==2){ |
| | | var content='<option value="">Choose your franchisee</option>'; |
| | | }else { |
| | | var content='<option value="">Pilih franchisee Anda</option>'; |
| | | } |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#cCode").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | } |
| | |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | } |
| | | |
| | | TCarInfoDlg.oneChangeNext = function (e) { |
| | | var oneId=$(e).val(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tShop/oneChangeNext", function(data){ |
| | |
| | | ajax.set("province",oneId); |
| | | ajax.start(); |
| | | }; |
| | | TSite.oneChangeYys = function(e){ |
| | | var oneId=$(e).val(); |
| | | var SelectValue=""; |
| | | var getSelectValueMenbers = $("input[name='pt']:checked").each(function(j) { |
| | | if (j >= 0) { |
| | | SelectValue += $(this).val() |
| | | } |
| | | }); |
| | | if(SelectValue=='0' ){ |
| | | oneId=0 |
| | | } |
| | | var ajax = new $ax(Feng.ctxPath + "/tSite/getChangeOne", function(data){ |
| | | if(data!=null){ |
| | | var content='<option value="">选择门店</option>'; |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#store").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | }; |
| | | // 场地管理首页 选择对应的省市 |
| | | // 传1是场地管理首页 传2是场地管理添加页面 |
| | | TSite.oneChange = function (e) { |
| | |
| | | managementPlan:"", |
| | | operatorId:"", |
| | | typeName:"", |
| | | nextName:"" |
| | | nextName:"", |
| | | ishalf:"", |
| | | cashPriceOne:"", |
| | | playPaiCoinOne:"", |
| | | halfName:"", |
| | | introduce:"", |
| | | imgs:"", |
| | | ids:"" |
| | | }; |
| | | data.province = $("#pCode").val() |
| | | data.city = $("#cCode").val() |
| | |
| | | let num24 = $('input[name="name1"]'); |
| | | var nextName=""; |
| | | for (let i = 0; i < num24.length; i++) { |
| | | if(console.log($(num24[i]).val()=='')){ |
| | | if($(num24[i]).val()==''){ |
| | | Feng.info("请填写场地名称") |
| | | return; |
| | | } |
| | |
| | | nextName += $(num24[i]).val()+"," |
| | | } |
| | | } |
| | | console.log(nextName) |
| | | data.nextName= nextName; |
| | | |
| | | |
| | | var ishalf= $("input[name='ishalf']:checked").val(); |
| | | data.ishalf= ishalf; |
| | | var halfName=""; |
| | | if(ishalf==1){ |
| | | let cashPriceOne = $("#cashPriceOne").val() |
| | | if(cashPriceOne=='' ){ |
| | | Feng.info("请填写现金价格") |
| | | return; |
| | | } |
| | | data.cashPriceOne= cashPriceOne; |
| | | |
| | | if($("#account").val()=='' ){ |
| | | Feng.info("请选择账号") |
| | | let playPaiCoinOne = $("#playPaiCoinOne").val() |
| | | if(playPaiCoinOne=='' ){ |
| | | Feng.info("请填写玩湃币价格") |
| | | return; |
| | | } |
| | | |
| | | data.playPaiCoinOne= playPaiCoinOne; |
| | | let num2 = $('input[name="name2"]'); |
| | | for (let i = 0; i < num2.length; i++) { |
| | | if($(num2[i]).val()==''){ |
| | | Feng.info("请填写半场名称") |
| | | return; |
| | | } |
| | | if(i==num2.length-1){ |
| | | halfName += $(num2[i]).val() |
| | | }else { |
| | | halfName += $(num2[i]).val()+"," |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | data.halfName= halfName; |
| | | data.ids= $("#ids").val(); |
| | | let introduce = TSite.editor.getContent(); |
| | | |
| | | |
| | | |
| | | console.log(introduce) |
| | | if(introduce==""){ |
| | | Feng.info("请输入公告内容") |
| | | return; |
| | | } |
| | | data.introduce= introduce; |
| | | |
| | | |
| | | var goodImgs = this.goodsPicArray; |
| | | if(goodImgs.length==0){ |
| | | Feng.info("请上传实景图") |
| | | return; |
| | | } |
| | | var imgOne =""; |
| | | for (let i = 0; i <goodImgs.length; i++) { |
| | | if(i==goodImgs.length-1){ |
| | | imgOne += (goodImgs[i].response) |
| | | }else { |
| | | imgOne+=(goodImgs[i].response+",") |
| | | } |
| | | |
| | | } |
| | | data.imgs = imgOne |
| | | |
| | | |
| | | |
| | | if($("#store").val()=='' ){ |
| | | Feng.info("请选择门店") |
| | | return; |
| | |
| | | var rStime = ""; //门店的经营开始时间 |
| | | var rEtime = ""; //门店的经营结束时间 |
| | | var selectedText = $('#store option:selected').text(); |
| | | // $.ajax({ |
| | | // url: Feng.ctxPath + "/tSite/getTime/" + selectedText, |
| | | // type: "GET", |
| | | // contentType: "application/json", // 设置请求头的 Content-Type |
| | | // success: function (response) { |
| | | // rStime = response.startTime; |
| | | // sh = rStime.split(':')[0];// 门店经营开始时间:小时 |
| | | // sm = rStime.split(':')[1];// 门店经营开始时间:分钟 |
| | | // |
| | | // rEtime = response.endTime; |
| | | // eh = rEtime.split(':')[0];// 门店经营结束时间:小时 |
| | | // em = rEtime.split(':')[1];// 门店经营结束时间:分钟 |
| | | // |
| | | // var start = sTime.value; |
| | | // var startHour = start.split(':')[0]; // 输入的可预约开始时间:小时 |
| | | // var startMinute = start.split(':')[1];// 输入的可预约开始时间:分钟 |
| | | // if (Number(sh)>Number(startHour)){ |
| | | // Feng.error("预约的开始时间不应小于营业开始时间!") |
| | | // return false; |
| | | // }else if(Number(sh) === Number(startHour) ){ |
| | | // if (Number(sm)>Number(startMinute)){ |
| | | // Feng.error("预约的开始时间不应大于营业开始时间!") |
| | | // return false; |
| | | // } |
| | | // }else if (Number(eh)<Number(startHour)){ |
| | | // Feng.error("预约的开始时间不应大于营业结束时间!") |
| | | // return false; |
| | | // }else if(Number(eh)===Number(startHour)){ |
| | | // Feng.error("预约的开始时间不应大于等于营业结束时间!") |
| | | // return false; |
| | | // } |
| | | // var end = eTime.value; |
| | | // var endHour = end.split(':')[0]; // 输入的可预约结束时间:小时 |
| | | // var endMinute = end.split(':')[1];// 输入的可预约结束时间:分钟 |
| | | // if (Number(eh)<Number(endHour)){ |
| | | // Feng.error("预约的结束时间不应大于营业结束时间!") |
| | | // return ; |
| | | // }else if(Number(eh) === Number(endHour) ){ |
| | | // if (Number(em)<Number(endMinute)){ |
| | | // Feng.error("预约的开始时间不应大于开始营业时间!") |
| | | // return ; |
| | | // } |
| | | // }else if(Number(sh)>Number(endHour)){ |
| | | // Feng.error("预约的结束时间不应小于营业开始时间!") |
| | | // return ; |
| | | // } |
| | | // if (Number(endHour)===Number(sh)){ |
| | | // if(Number(endMinute) < Number(sm)){ |
| | | // Feng.error("预约结束时间不应小于营业开始时间"); |
| | | // return; |
| | | // } |
| | | // } |
| | | // if (Number(startHour)===Number(endHour) && Number(startMinute)===Number(endMinute)){ |
| | | // Feng.error("至少预约半个小时"); |
| | | // return; |
| | | // } |
| | | // $.ajax({ |
| | | // url: Feng.ctxPath + "/tSite/addSite" , |
| | | // type: "POST", |
| | | // data: JSON.stringify(data), |
| | | // contentType: "application/json", |
| | | // success: function (response) { |
| | | // window.parent.TSite.table.refresh(); |
| | | // TSite.close(); |
| | | // Feng.success("添加成功"); |
| | | // }, |
| | | // error: function (xhr, status, error) { |
| | | // Feng.error("添加失败!" + error); |
| | | // } |
| | | // }); |
| | | // }, |
| | | // error: function (xhr, status, error) { |
| | | // var errorMessage = xhr.responseText ? xhr.responseText : "上架失败!"; |
| | | // Feng.error("您的网络异常!"); |
| | | // return false; |
| | | // } |
| | | // }); |
| | | $.ajax({ |
| | | url: Feng.ctxPath + "/tSite/getTime/" + selectedText, |
| | | type: "GET", |
| | | contentType: "application/json", // 设置请求头的 Content-Type |
| | | success: function (response) { |
| | | rStime = response.startTime; |
| | | sh = rStime.split(':')[0];// 门店经营开始时间:小时 |
| | | sm = rStime.split(':')[1];// 门店经营开始时间:分钟 |
| | | |
| | | rEtime = response.endTime; |
| | | eh = rEtime.split(':')[0];// 门店经营结束时间:小时 |
| | | em = rEtime.split(':')[1];// 门店经营结束时间:分钟 |
| | | |
| | | var start = sTime.value; |
| | | var startHour = start.split(':')[0]; // 输入的可预约开始时间:小时 |
| | | var startMinute = start.split(':')[1];// 输入的可预约开始时间:分钟 |
| | | if (Number(sh)>Number(startHour)){ |
| | | Feng.error("预约的开始时间不应小于营业开始时间!") |
| | | return false; |
| | | }else if(Number(sh) === Number(startHour) ){ |
| | | if (Number(sm)>Number(startMinute)){ |
| | | Feng.error("预约的开始时间不应大于营业开始时间!") |
| | | return false; |
| | | } |
| | | }else if (Number(eh)<Number(startHour)){ |
| | | Feng.error("预约的开始时间不应大于营业结束时间!") |
| | | return false; |
| | | }else if(Number(eh)===Number(startHour)){ |
| | | Feng.error("预约的开始时间不应大于等于营业结束时间!") |
| | | return false; |
| | | } |
| | | var end = eTime.value; |
| | | var endHour = end.split(':')[0]; // 输入的可预约结束时间:小时 |
| | | var endMinute = end.split(':')[1];// 输入的可预约结束时间:分钟 |
| | | if (Number(eh)<Number(endHour)){ |
| | | Feng.error("预约的结束时间不应大于营业结束时间!") |
| | | return ; |
| | | }else if(Number(eh) === Number(endHour) ){ |
| | | if (Number(em)<Number(endMinute)){ |
| | | Feng.error("预约的开始时间不应大于开始营业时间!") |
| | | return ; |
| | | } |
| | | }else if(Number(sh)>Number(endHour)){ |
| | | Feng.error("预约的结束时间不应小于营业开始时间!") |
| | | return ; |
| | | } |
| | | if (Number(endHour)===Number(sh)){ |
| | | if(Number(endMinute) < Number(sm)){ |
| | | Feng.error("预约结束时间不应小于营业开始时间"); |
| | | return; |
| | | } |
| | | } |
| | | if (Number(startHour)===Number(endHour) && Number(startMinute)===Number(endMinute)){ |
| | | Feng.error("至少预约半个小时"); |
| | | return; |
| | | } |
| | | $.ajax({ |
| | | url: Feng.ctxPath + "/tSite/addSite" , |
| | | type: "POST", |
| | | data: JSON.stringify(data), |
| | | contentType: "application/json", |
| | | success: function (response) { |
| | | window.parent.TSite.table.refresh(); |
| | | TSite.close(); |
| | | Feng.success("添加成功"); |
| | | }, |
| | | error: function (xhr, status, error) { |
| | | Feng.error("添加失败!" + error); |
| | | } |
| | | }); |
| | | }, |
| | | error: function (xhr, status, error) { |
| | | var errorMessage = xhr.responseText ? xhr.responseText : "上架失败!"; |
| | | Feng.error("您的网络异常!"); |
| | | return false; |
| | | } |
| | | }); |
| | | }; |
| | | |
| | | TSite.search = function () { |
| | |
| | | //初始化编辑器 |
| | | TSite.editor = UE.getEditor('editor'); |
| | | // 限制分钟选项为 0 和 30 |
| | | var timeInputs = document.querySelectorAll('input[type="time"]'); |
| | | timeInputs.forEach(function(input) { |
| | | input.addEventListener('change', function() { |
| | | var selectedTime = input.value; |
| | | var hour = selectedTime.split(':')[0]; |
| | | var minute = selectedTime.split(':')[1]; |
| | | if (minute < 30 &&minute>0) { |
| | | minute = '30'; |
| | | } else if (minute >30) { |
| | | hour++; |
| | | minute = '00'; |
| | | if (hour<10){ |
| | | hour = '0'+hour; |
| | | } |
| | | } |
| | | input.value = hour + ':' + minute; |
| | | }); |
| | | }); |
| | | // var timeInputs = document.querySelectorAll('input[type="time"]'); |
| | | // timeInputs.forEach(function(input) { |
| | | // input.addEventListener('change', function() { |
| | | // var selectedTime = input.value; |
| | | // var hour = selectedTime.split(':')[0]; |
| | | // var minute = selectedTime.split(':')[1]; |
| | | // if (minute < 30 &&minute>0) { |
| | | // minute = '30'; |
| | | // } else if (minute >30) { |
| | | // hour++; |
| | | // minute = '00'; |
| | | // if (hour<10){ |
| | | // hour = '0'+hour; |
| | | // } |
| | | // } |
| | | // input.value = hour + ':' + minute; |
| | | // }); |
| | | // }); |
| | | |
| | | |
| | | var defaultColunms = TSite.initColumn(); |
| | |
| | | var TSiteInfo = { |
| | | layerIndex: -1, |
| | | validateFields: { |
| | | } |
| | | }, |
| | | goodsPicArray:[], |
| | | }; |
| | | |
| | | /** |
| | |
| | | insuranceEndTime:"", |
| | | name:"", |
| | | insuranceImg:"", |
| | | managementPlan:"" |
| | | managementPlan:"", |
| | | operatorId:"", |
| | | typeName:"", |
| | | nextName:"", |
| | | ishalf:"", |
| | | cashPriceOne:"", |
| | | playPaiCoinOne:"", |
| | | halfName:"", |
| | | introduce:"", |
| | | imgs:"", |
| | | ids:"" |
| | | }; |
| | | data.province = $("#pCode").val() |
| | | data.id = $("#id").val() |
| | |
| | | var eh =data.appointmentEndTime.split(':')[0]; |
| | | var em =data.appointmentEndTime.split(':')[1]; |
| | | |
| | | if($("#pCode").val()==''){ |
| | | Feng.info("请选择省") |
| | | |
| | | |
| | | |
| | | var SelectValue=""; |
| | | var getSelectValueMenbers = $("input[name='pt']:checked").each(function(j) { |
| | | if (j >= 0) { |
| | | SelectValue += $(this).val() |
| | | } |
| | | }); |
| | | if(SelectValue==''){ |
| | | let yys = $("#yys").val() |
| | | if(yys==""){ |
| | | Feng.info("请选择运营商") |
| | | return; |
| | | } |
| | | SelectValue= yys |
| | | } |
| | | data.operatorId= SelectValue; |
| | | |
| | | |
| | | |
| | | let num24 = $('input[name="name1"]'); |
| | | var nextName=""; |
| | | for (let i = 0; i < num24.length; i++) { |
| | | if($(num24[i]).val()==''){ |
| | | Feng.info("请填写场地名称") |
| | | return; |
| | | } |
| | | if(i==num24.length-1){ |
| | | nextName += $(num24[i]).val() |
| | | }else { |
| | | nextName += $(num24[i]).val()+"," |
| | | } |
| | | } |
| | | data.nextName= nextName; |
| | | |
| | | |
| | | var ishalf= $("input[name='ishalf']:checked").val(); |
| | | data.ishalf= ishalf; |
| | | var halfName=""; |
| | | if(ishalf==1){ |
| | | let cashPriceOne = $("#cashPriceOne").val() |
| | | if(cashPriceOne=='' ){ |
| | | Feng.info("请填写现金价格") |
| | | return; |
| | | } |
| | | data.cashPriceOne= cashPriceOne; |
| | | |
| | | let playPaiCoinOne = $("#playPaiCoinOne").val() |
| | | if(playPaiCoinOne=='' ){ |
| | | Feng.info("请填写玩湃币价格") |
| | | return; |
| | | } |
| | | |
| | | data.playPaiCoinOne= playPaiCoinOne; |
| | | let num2 = $('input[name="name2"]'); |
| | | for (let i = 0; i < num2.length; i++) { |
| | | if($(num2[i]).val()==''){ |
| | | Feng.info("请填写半场名称") |
| | | return; |
| | | } |
| | | if(i==num2.length-1){ |
| | | halfName += $(num2[i]).val() |
| | | }else { |
| | | halfName += $(num2[i]).val()+"," |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | data.halfName= halfName; |
| | | data.ids= $("#ids").val(); |
| | | let introduce = TSiteInfo.editor.getContent(); |
| | | |
| | | |
| | | console.log(introduce) |
| | | if(introduce==""){ |
| | | Feng.info("请输入公告内容") |
| | | return; |
| | | } |
| | | if($("#cCode").val()==''){ |
| | | Feng.info("请选择市") |
| | | data.introduce= introduce; |
| | | |
| | | |
| | | var goodImgs = TSiteInfo.goodsPicArray; |
| | | |
| | | if(goodImgs.length==0){ |
| | | Feng.info("请上传实景图") |
| | | return; |
| | | } |
| | | if($("#account").val()=='' ){ |
| | | Feng.info("请选择账号") |
| | | return; |
| | | var imgOne =""; |
| | | console.log(goodImgs) |
| | | console.log(goodImgs.length) |
| | | for (let i = 0; i <goodImgs.length; i++) { |
| | | console.log(goodImgs[i].response,11) |
| | | if(i==goodImgs.length-1){ |
| | | imgOne += (goodImgs[i].response) |
| | | }else { |
| | | imgOne+=(goodImgs[i].response+",") |
| | | } |
| | | |
| | | } |
| | | console.log(imgOne) |
| | | data.imgs = imgOne |
| | | |
| | | |
| | | |
| | | |
| | | if($("#store").val()=='' ){ |
| | | Feng.info("请选择门店") |
| | | return; |
| | |
| | | }); |
| | | |
| | | }; |
| | | |
| | | TSiteInfo.oneChangeYys = function(e){ |
| | | var oneId=$(e).val(); |
| | | var SelectValue=""; |
| | | var getSelectValueMenbers = $("input[name='pt']:checked").each(function(j) { |
| | | if (j >= 0) { |
| | | SelectValue += $(this).val() |
| | | } |
| | | }); |
| | | if(SelectValue=='0' ){ |
| | | oneId=0 |
| | | } |
| | | var ajax = new $ax(Feng.ctxPath + "/tSite/getChangeOne", function(data){ |
| | | if(data!=null){ |
| | | var content='<option value="">选择门店</option>'; |
| | | $.each(data, function(k,v) { |
| | | content += "<option value='"+v.id+"'>"+v.name+"</option>"; |
| | | }); |
| | | $("#store").empty().append(content); |
| | | } |
| | | }); |
| | | ajax.set("oneId",oneId); |
| | | ajax.start(); |
| | | }; |
| | | /** |
| | | * 关闭此对话框 |
| | | */ |
| | |
| | | $('#upFile').click(); |
| | | } |
| | | $(function () { |
| | | TSiteInfo.editor = UE.getEditor('editor'); |
| | | // 限制分钟选项为 0 和 30 |
| | | var timeInputs = document.querySelectorAll('input[type="time"]'); |
| | | timeInputs.forEach(function(input) { |
| | |
| | | return list; |
| | | } |
| | | |
| | | @ResponseBody |
| | | @PostMapping("/base/notice/queryQuestionDetails") |
| | | public List<QuestionIns> getSysQuestionDetails(){ |
| | | List<QuestionIns> sysS = new ArrayList<>(); |
| | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.dsh.other.entity.Store; |
| | | import com.dsh.other.entity.TStoreOther; |
| | | import com.dsh.other.entity.TStoreOtherConfigTrue; |
| | | import com.dsh.other.feignclient.model.*; |
| | | import com.dsh.other.model.*; |
| | | import com.dsh.other.service.StoreService; |
| | | import com.dsh.other.service.TStoreOtherConfigTrueService; |
| | | import com.dsh.other.service.TStoreOtherService; |
| | | import com.dsh.other.util.GDMapGeocodingUtil; |
| | | import com.dsh.other.util.ResultUtil; |
| | | import com.dsh.other.util.ToolUtil; |
| | |
| | | @Autowired |
| | | private GDMapGeocodingUtil gdMapGeocodingUtil; |
| | | |
| | | @Autowired |
| | | private TStoreOtherService tStoreOtherService; |
| | | |
| | | /** |
| | | * 根据城市管理员id获取门店 |
| | |
| | | } |
| | | } |
| | | |
| | | @Autowired |
| | | private TStoreOtherConfigTrueService tStoreOtherConfigTrueService; |
| | | @ResponseBody |
| | | @PostMapping("/base/store/queryIndexSet") |
| | | @ApiOperation(value = "获取门店首页设置 2.0", tags = {"APP-免费福利"}) |
| | | @ApiImplicitParams({ |
| | | @ApiImplicitParam(value = "门店id", name = "id", dataType = "int", required = true), |
| | | }) |
| | | public ResultUtil<List<TStoreOtherConfigTrue>> queryIndexSet(Integer id){ |
| | | try { |
| | | List<TStoreOtherConfigTrue> tStoreOtherConfigTrues = new ArrayList<>(); |
| | | |
| | | List<TStoreOther> list = tStoreOtherService.list(new LambdaQueryWrapper<TStoreOther>().eq(TStoreOther::getStoreId, id)); |
| | | if(list.size()>0){ |
| | | tStoreOtherConfigTrues= tStoreOtherConfigTrueService.list(new LambdaQueryWrapper<TStoreOtherConfigTrue>().eq(TStoreOtherConfigTrue::getPid, list.get(0).getId())); |
| | | } |
| | | return ResultUtil.success(tStoreOtherConfigTrues); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | return ResultUtil.runErr(); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | |
| | | private String nextName; |
| | | @TableField("halfName") |
| | | private String halfName; |
| | | @TableField("cashPriceOne") |
| | | private Double cashPriceOne; |
| | | @TableField("playPaiCoinOne") |
| | | private Double playPaiCoinOne; |
| | | @TableField("ids") |
| | | private String ids; |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @Accessors(chain = true) |
| | | @TableName("t_store_other") |
| | | public class TStoreOther extends Model<TStoreOther> { |
| | | |
| | | private static final long serialVersionUID=1L; |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | private String name; |
| | | |
| | | @TableField("storeId") |
| | | private Integer storeId; |
| | | |
| | | private Integer sort; |
| | | |
| | | /** |
| | | * 1开启 2关闭 |
| | | */ |
| | | private Integer state; |
| | | |
| | | |
| | | @Override |
| | | protected Serializable pkVal() { |
| | | return this.id; |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.extension.activerecord.Model; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.experimental.Accessors; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = false) |
| | | @Accessors(chain = true) |
| | | @TableName("t_store_other_config_true") |
| | | public class TStoreOtherConfigTrue extends Model<TStoreOtherConfigTrue> { |
| | | |
| | | private static final long serialVersionUID=1L; |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | /** |
| | | * 图片 |
| | | */ |
| | | private String url; |
| | | |
| | | /** |
| | | * 跳转模块 |
| | | */ |
| | | private String name; |
| | | |
| | | /** |
| | | * 跳转页面 |
| | | */ |
| | | private String page; |
| | | |
| | | /** |
| | | * 跳转类型 |
| | | */ |
| | | private String type; |
| | | |
| | | /** |
| | | * 跳转id |
| | | */ |
| | | @TableField("turnId") |
| | | private String turnId; |
| | | |
| | | /** |
| | | * 排序 |
| | | */ |
| | | private Integer sort; |
| | | |
| | | /** |
| | | * 1开启 2关闭 |
| | | */ |
| | | private Integer state; |
| | | |
| | | private Integer pid; |
| | | |
| | | @TableField("pageId") |
| | | private Integer pageId; |
| | | |
| | | @TableField("typeId") |
| | | private Integer typeId; |
| | | |
| | | |
| | | |
| | | @Override |
| | | protected Serializable pkVal() { |
| | | return this.id; |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.mapper; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.dsh.other.entity.TStoreOtherConfigTrue; |
| | | |
| | | /** |
| | | * <p> |
| | | * Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | public interface TStoreOtherConfigTrueMapper extends BaseMapper<TStoreOtherConfigTrue> { |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.mapper; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.dsh.other.entity.TStoreOther; |
| | | |
| | | /** |
| | | * <p> |
| | | * Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | public interface TStoreOtherMapper extends BaseMapper<TStoreOther> { |
| | | |
| | | } |
| | |
| | | private Integer ishalf; |
| | | @ApiModelProperty("场地说明") |
| | | private String introduce; |
| | | @ApiModelProperty("现金价格(x/半小时)半场") |
| | | |
| | | private Double cashPriceOne; |
| | | @ApiModelProperty("玩湃币价格(x/半小时)半场") |
| | | private Double playPaiCoinOne; |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.service; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.dsh.other.entity.TStoreOtherConfigTrue; |
| | | |
| | | /** |
| | | * <p> |
| | | * 服务类 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | public interface TStoreOtherConfigTrueService extends IService<TStoreOtherConfigTrue> { |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.service; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.dsh.other.entity.TStoreOther; |
| | | |
| | | /** |
| | | * <p> |
| | | * 服务类 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | public interface TStoreOtherService extends IService<TStoreOther> { |
| | | |
| | | } |
| | |
| | | querySiteInfoVo.setStorePhone(store.getPhone()); |
| | | querySiteInfoVo.setImgs(site.getImgs()); |
| | | querySiteInfoVo.setDistance(0D); |
| | | querySiteInfoVo.setCashPriceOne(site.getCashPriceOne()); |
| | | querySiteInfoVo.setPlayPaiCoinOne(site.getPlayPaiCoinOne()); |
| | | querySiteInfoVo.setIntroduce(site.getIntroduce()); |
| | | ArrayList<String> nextName = new ArrayList<>(); |
| | | ArrayList<String> halfName = new ArrayList<>(); |
New file |
| | |
| | | package com.dsh.other.service.impl; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.dsh.other.entity.TStoreOtherConfigTrue; |
| | | import com.dsh.other.mapper.TStoreOtherConfigTrueMapper; |
| | | import com.dsh.other.service.TStoreOtherConfigTrueService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | @Service |
| | | public class TStoreOtherConfigTrueServiceImpl extends ServiceImpl<TStoreOtherConfigTrueMapper, TStoreOtherConfigTrue> implements TStoreOtherConfigTrueService { |
| | | |
| | | } |
New file |
| | |
| | | package com.dsh.other.service.impl; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.dsh.other.entity.TStoreOther; |
| | | import com.dsh.other.mapper.TStoreOtherMapper; |
| | | import com.dsh.other.service.TStoreOtherService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author administrator |
| | | * @since 2023-09-19 |
| | | */ |
| | | @Service |
| | | public class TStoreOtherServiceImpl extends ServiceImpl<TStoreOtherMapper, TStoreOther> implements TStoreOtherService { |
| | | |
| | | } |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.dsh.other.mapper.TStoreOtherConfigTrueMapper"> |
| | | |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.dsh.other.mapper.TStoreOtherMapper"> |
| | | |
| | | |
| | | </mapper> |