Commit 3a7093bc by huluobin

update

parent 04b44409
...@@ -396,7 +396,7 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper, ...@@ -396,7 +396,7 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper,
List<Integer> technicianIds = treeProgramList.stream().map(StoreTechnicianPeriod::getTechnicianId).collect(Collectors.toList()); List<Integer> technicianIds = treeProgramList.stream().map(StoreTechnicianPeriod::getTechnicianId).collect(Collectors.toList());
Integer technicianId = storeTechnician.getTechnicianId(); Integer technicianId = storeTechnician.getTechnicianId();
log.info("technicianIds:{},technicianId:{}", technicianIds, technicianId); log.debug("technicianIds:{},technicianId:{}", technicianIds, technicianId);
boolean b = technicianIds.contains(technicianId); boolean b = technicianIds.contains(technicianId);
//如果已经设置该美甲师的节点不为空 需要把当前节点的服务时间加上 //如果已经设置该美甲师的节点不为空 需要把当前节点的服务时间加上
......
...@@ -78,11 +78,17 @@ public class GogirlTokenServiceImpl implements GogirlTokenService { ...@@ -78,11 +78,17 @@ public class GogirlTokenServiceImpl implements GogirlTokenService {
GogirlToken gogirlToken = SessionUtils.getCustomerToken(); GogirlToken gogirlToken = SessionUtils.getCustomerToken();
Customer customer = customerMapper.selectById(gogirlToken.getCustomerId()); Customer customer = customerMapper.selectById(gogirlToken.getCustomerId());
if (StringUtils.isEmpty(realName)) {
customer.setRealName(realName); customer.setRealName(realName);
}
customer.setBirthday(birthday); customer.setBirthday(birthday);
customer.setSex(sex); if (StringUtils.isNotEmpty(sex)) {
customer.setPhone(phone); customer.setSex(sex);
}
if (StringUtils.isEmpty(phone)) {
customer.setPhone(phone);
}
List<Customer> phoneCustomer = customerMapper.selectList(new LambdaQueryWrapper<Customer>() List<Customer> phoneCustomer = customerMapper.selectList(new LambdaQueryWrapper<Customer>()
.eq(Customer::getPhone, phone)); .eq(Customer::getPhone, phone));
......
package com.gogirl.infrastructure.config; package com.gogirl.infrastructure.config;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.gogirl.infrastructure.interceptor.LogHandlerInterceptor; import com.gogirl.infrastructure.interceptor.LogHandlerInterceptor;
import com.gogirl.infrastructure.interceptor.LoginHandlerInterceptor; import com.gogirl.infrastructure.interceptor.LoginHandlerInterceptor;
import com.gogirl.infrastructure.interceptor.SessionHandlerInterceptor; import com.gogirl.infrastructure.interceptor.SessionHandlerInterceptor;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
import org.springframework.http.converter.HttpMessageConverter;
import org.springframework.http.converter.json.Jackson2ObjectMapperBuilder;
import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry; import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry; import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport; import org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport;
import java.text.SimpleDateFormat;
import java.util.List;
import java.util.TimeZone;
@Configuration @Configuration
@AllArgsConstructor @AllArgsConstructor
public class MvcInterceptorConfig extends WebMvcConfigurationSupport { public class MvcInterceptorConfig extends WebMvcConfigurationSupport {
...@@ -37,6 +28,9 @@ public class MvcInterceptorConfig extends WebMvcConfigurationSupport { ...@@ -37,6 +28,9 @@ public class MvcInterceptorConfig extends WebMvcConfigurationSupport {
.addPathPatterns("/**") .addPathPatterns("/**")
.excludePathPatterns("/swagger-resources/**", "/webjars/**", "/v2/**", "/swagger-ui.html/**", "/error") .excludePathPatterns("/swagger-resources/**", "/webjars/**", "/v2/**", "/swagger-ui.html/**", "/error")
//登陆 //登陆
.excludePathPatterns("/customer/message/loginLog")
.excludePathPatterns("/customer/message/pageIn")
.excludePathPatterns("/customer/xcx/login") .excludePathPatterns("/customer/xcx/login")
.excludePathPatterns("/customer/csrf") .excludePathPatterns("/customer/csrf")
.excludePathPatterns("/customer/mallCategory/getCategoryTree") .excludePathPatterns("/customer/mallCategory/getCategoryTree")
......
...@@ -2,12 +2,10 @@ package com.gogirl.interfaces.xcx; ...@@ -2,12 +2,10 @@ package com.gogirl.interfaces.xcx;
import com.gogirl.application.store.store.StoreTechnicianService; import com.gogirl.application.store.store.StoreTechnicianService;
import com.gogirl.application.xcx.GogirlTokenService; import com.gogirl.application.xcx.GogirlTokenService;
import com.gogirl.application.xcx.WechatService;
import com.gogirl.domain.user.customer.Customer; import com.gogirl.domain.user.customer.Customer;
import com.gogirl.infrastructure.common.annotation.GogirlMember; import com.gogirl.infrastructure.common.annotation.GogirlMember;
import com.gogirl.infrastructure.common.annotation.GogirlShop; import com.gogirl.infrastructure.common.annotation.GogirlShop;
import com.gogirl.infrastructure.common.base.JsonResult; import com.gogirl.infrastructure.common.base.JsonResult;
import com.gogirl.infrastructure.mapper.store.store.StoreManageMapper;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
...@@ -43,12 +41,12 @@ public class PhoneLoginController { ...@@ -43,12 +41,12 @@ public class PhoneLoginController {
@ApiOperation(value = "小程序用户根据验证码绑定手机号码和称呼 生日的格式是:yyyy-MM-dd") @ApiOperation(value = "小程序用户根据验证码绑定手机号码和称呼 生日的格式是:yyyy-MM-dd")
@PostMapping("/customer/phone/bindPhoneAndName") @PostMapping("/customer/phone/bindPhoneAndName")
public JsonResult<Customer> bindPhoneAndCode(@RequestHeader String token, public JsonResult<Customer> bindPhoneAndCode(@RequestHeader String token,
@RequestParam String phone, @RequestParam(required = false) String phone,
@RequestParam String code, @RequestParam(required = false) String code,
@RequestParam String realName, @RequestParam(required = false) String realName,
@RequestParam @RequestParam(required = false)
@DateTimeFormat(pattern = "yyyy-MM-dd") Date birthday, @DateTimeFormat(pattern = "yyyy-MM-dd") Date birthday,
@RequestParam String sex) { @RequestParam(required = false) String sex) {
Customer customer = gogirlTokenService.bindPhoneAndCode(phone, code, realName, birthday, sex); Customer customer = gogirlTokenService.bindPhoneAndCode(phone, code, realName, birthday, sex);
return JsonResult.success(customer); return JsonResult.success(customer);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment