订单列表、登录、注册、新增司机

localizer
lzq 2025-09-12 19:10:02 +08:00
parent 6335242846
commit 2d1dd6c0db
48 changed files with 1775 additions and 198 deletions

View File

@ -31,16 +31,25 @@ public class OSSController {
return R.success();
}
/**
*
*/
@GetMapping("/obtain_presigned_url")
public R<Map<String, String>> obtainPresignedUrl(@RequestParam(value = "filename") String filename) {
return R.success(ossService.obtainPresignedUrl(filename));
}
/**
*
*/
@PostMapping("/upload")
public void uploadFile(@RequestPart MultipartFile file) {
ossService.uploadFile(file);
}
/**
*
*/
@GetMapping("/download/{bucketName}/{objectName}")
public void obtainFile(
@PathVariable("bucketName") String bucketName,

View File

@ -76,9 +76,8 @@ public class WebSecurityAutoConfiguration {
}
@Bean
@ConditionalOnBean({IUserService.class})
public VerificationCodeService verificationCodeService(IUserService iUserService) {
return new VerificationCodeService(true, iUserService);
public VerificationCodeService verificationCodeService() {
return new VerificationCodeService(true);
}
@Bean

View File

@ -45,6 +45,7 @@ public class PasswordAuthenticationProvider extends AbstractAuthenticationProvid
@Override
protected void afterCheck(LoginForm loginForm, UserDetail userDetail) throws UserLoginException {
String secret = userDetail.getSecret();
Assert.notBlank(secret, () -> new UserLoginException(ExceptionMsg.CLI_ERR_MSG, "当前账号不支持密码登录"));
PasswordLoginForm passwordLoginForm = (PasswordLoginForm) loginForm;
Assert.isTrue(EncryptUtil.matches(passwordLoginForm.getSecret(), secret), () -> new UserLoginException(ExceptionMsg.CLI_ERR_MSG, "账号或密码错误"));
}

View File

@ -6,7 +6,6 @@ import cn.hutool.cache.impl.TimedCache;
import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.RandomUtil;
import com.njzscloud.common.core.ex.Exceptions;
import com.njzscloud.common.security.contant.AuthWay;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
@ -14,21 +13,23 @@ import lombok.extern.slf4j.Slf4j;
@RequiredArgsConstructor
public class VerificationCodeService {
private final boolean fixed;
private final IUserService iUserService;
private final TimedCache<String, String> codeMap = CacheUtil.newTimedCache(1000 * 60 * 5);
private final TimedCache<String, String> phoneMap = CacheUtil.newTimedCache(1000 * 60);
public String obtainCode(String phone) {
UserDetail userDetail = iUserService.selectUser(phone, AuthWay.PHONE);
if (userDetail == null) {
throw Exceptions.clierr("账号未注册");
if (!fixed) {
String s = phoneMap.get(phone);
if (s != null) {
throw Exceptions.clierr("请勿平繁获取");
}
}
String s = phoneMap.get(phone);
if (s != null) {
throw Exceptions.clierr("请勿平繁获取");
String codeId;
if (fixed) {
codeId = "00000";
} else {
codeId = IdUtil.simpleUUID();
}
String codeId = IdUtil.simpleUUID();
phoneMap.put(phone, codeId);
String code = null;
if (fixed) {
@ -44,6 +45,9 @@ public class VerificationCodeService {
}
public boolean checkCode(String codeId, String code) {
if (fixed) {
return true;
}
String oldCode = codeMap.get(codeId);
boolean succ = oldCode != null && oldCode.equals(code);
if (succ) {

View File

@ -5,10 +5,11 @@ import com.njzscloud.common.security.support.VerificationCodeService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
/**
*
*
*/
@RestController
@RequestMapping("/auth")
@ -16,8 +17,14 @@ import org.springframework.web.bind.annotation.RestController;
public class VerificationCodeController {
private final VerificationCodeService verificationCodeService;
/**
*
*
* @param phone
* @return
*/
@GetMapping("/obtain_code")
public R<String> obtainCode(String phone) {
public R<String> obtainCode(@RequestParam("phone") String phone) {
return R.success(verificationCodeService.obtainCode(phone));
}
}

View File

@ -1,13 +1,15 @@
package com.njzscloud.common.security.util;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.extra.spring.SpringUtil;
import com.njzscloud.common.security.contant.AuthWay;
import com.njzscloud.common.security.contant.Constants;
import com.njzscloud.common.security.support.ITokenService;
import com.njzscloud.common.security.support.Token;
import com.njzscloud.common.security.support.UserDetail;
import com.njzscloud.common.security.support.*;
import org.springframework.security.core.Authentication;
import org.springframework.security.core.context.SecurityContextHolder;
import java.util.Set;
/**
*
*/
@ -78,4 +80,24 @@ public class SecurityUtil {
public static void removeToken(Long userId) {
SpringUtil.getBean(ITokenService.class).removeToken(userId);
}
public static String registrationToken(String account, AuthWay authWay) {
IUserService userService = SpringUtil.getBean(IUserService.class);
UserDetail userDetail = userService.selectUser(account, authWay);
Long userId = userDetail.getUserId();
Set<String> roles = SpringUtil.getBean(IRoleService.class).selectRoleByUserId(userId);
if (CollUtil.isEmpty(roles)) {
roles.add(Constants.ROLE_ANONYMOUS);
roles.add(Constants.ROLE_AUTHENTICATED);
}
Resource resource = SpringUtil.getBean(IResourceService.class).selectResourceByUserId(userId);
Token token = Token.create(userDetail.getUserId(), userDetail.getAccountId(), authWay);
userDetail.setAuthWay(authWay)
.setRoles(roles)
.setResource(resource)
.setToken(token);
SecurityUtil.registrationToken(userDetail);
return token.toString();
}
}

View File

@ -17,6 +17,8 @@ public enum BizObj implements DictStr {
WuYe("WuYe", "物业"),
QingYunGongSi("QingYunGongSi", "清运公司"),
SiJi("SiJi", "司机"),
JianGuan("JianGuan", "监管"),
SiBang("SiBang", "司磅"),
XiaoNaCang("XiaoNaCang", "消纳场"),
ZhengFuBuMen("ZhengFuBuMen", "政府部门");

View File

@ -7,15 +7,12 @@ import com.njzscloud.supervisory.biz.contant.AuditStatus;
import com.njzscloud.supervisory.biz.pojo.entity.BizCompanyEntity;
import com.njzscloud.supervisory.biz.pojo.param.ModifyBizCompanyParam;
import com.njzscloud.supervisory.biz.pojo.param.SearchCompanyParam;
import com.njzscloud.supervisory.biz.pojo.result.MatchingBizCompanyResult;
import com.njzscloud.supervisory.biz.pojo.result.SearchCompanyResult;
import com.njzscloud.supervisory.biz.service.BizCompanyService;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
*
*/
@ -84,9 +81,4 @@ public class BizCompanyController {
public R<PageResult<BizCompanyEntity>> paging(PageParam pageParam, SearchCompanyParam searchCompanyParam) {
return R.success(bizCompanyService.paging(pageParam, searchCompanyParam));
}
@GetMapping("/matching")
public R<List<MatchingBizCompanyResult>> matching() {
return R.success(bizCompanyService.matching());
}
}

View File

@ -79,6 +79,9 @@ public class BizDriverController {
return R.success(bizDriverService.paging(pageParam, bizDriverEntity));
}
/**
*
*/
@GetMapping("/dispensability")
public R<PageResult<BizDriverEntity>> dispensabilityList(PageParam pageParam, @RequestParam(required = false) String keywords) {
return R.success(bizDriverService.dispensabilityList(pageParam, keywords));

View File

@ -2,17 +2,11 @@ package com.njzscloud.supervisory.biz.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.njzscloud.supervisory.biz.pojo.entity.BizCompanyEntity;
import com.njzscloud.supervisory.biz.pojo.result.MatchingBizCompanyResult;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
*
*/
@Mapper
public interface BizCompanyMapper extends BaseMapper<BizCompanyEntity> {
List<MatchingBizCompanyResult> matching(@Param("companyId") Long companyId);
}

View File

@ -8,6 +8,7 @@ import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;
@ -35,6 +36,10 @@ public class BizCompanyEntity {
* ; biz_obj
*/
private BizObj bizObj;
/**
*
*/
private Boolean station;
/**
* ; biz_company.uscc
@ -59,8 +64,8 @@ public class BizCompanyEntity {
/**
* ; []
*/
@TableField(value = "business_license_date", typeHandler = JsonTypeHandler.class)
private List<String> businessLicenseDate;
private LocalDate licenseStartTime;
private LocalDate licenseEndTime;
/**
* ; []

View File

@ -1,14 +1,13 @@
package com.njzscloud.supervisory.biz.pojo.entity;
import com.baomidou.mybatisplus.annotation.*;
import com.njzscloud.common.mp.support.handler.j.JsonTypeHandler;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;
/**
*
@ -44,23 +43,16 @@ public class BizDriverEntity {
/**
*
*/
private String phoneNum;
private String phone;
/**
* ;
*/
private String drivingLicence;
/**
* ; []
*/
@TableField(typeHandler = JsonTypeHandler.class)
private List<String> drivingLicenceDate;
private LocalDate licenceStartTime;
/**
* ; 0-->1-->
*/
private Boolean busy;
private LocalDate licenceEndTime;
/**
* Id; sys_user.id

View File

@ -6,6 +6,7 @@ import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.time.LocalDate;
import java.util.List;
/**
@ -50,7 +51,8 @@ public class AddBizCompanyParam {
/**
* ; []
*/
private List<String> businessLicenseDate;
private LocalDate licenseStartTime;
private LocalDate licenseEndTime;
/**
* ; []
@ -95,5 +97,5 @@ public class AddBizCompanyParam {
/**
*
*/
private String phoneNum;
private String phone;
}

View File

@ -6,7 +6,7 @@ import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.util.List;
import java.time.LocalDate;
/**
*
@ -25,7 +25,7 @@ public class AddDriverParam {
/**
*
*/
private String phoneNum;
private String phone;
/**
* ;
@ -35,7 +35,9 @@ public class AddDriverParam {
/**
* ; []
*/
private List<String> drivingLicenceDate;
private LocalDate licenceStartTime;
private LocalDate licenceEndTime;
private AddUserParam user;

View File

@ -7,6 +7,7 @@ import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.time.LocalDate;
import java.util.List;
/**
@ -57,7 +58,8 @@ public class ModifyBizCompanyParam {
/**
* ; []
*/
private List<String> businessLicenseDate;
private LocalDate licenseStartTime;
private LocalDate licenseEndTime;
/**
* ; []
@ -112,7 +114,7 @@ public class ModifyBizCompanyParam {
/**
*
*/
private String phoneNum;
private String phone;
/**
* ; audit_status

View File

@ -7,6 +7,7 @@ import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.time.LocalDate;
import java.util.List;
/**
@ -56,7 +57,8 @@ public class MatchingBizCompanyResult {
/**
* ; []
*/
private List<String> businessLicenseDate;
private LocalDate licenseStartTime;
private LocalDate licenseEndTime;
/**
* ; []
@ -113,7 +115,7 @@ public class MatchingBizCompanyResult {
/**
*
*/
private String phoneNum;
private String phone;
/**
* ; audit_status

View File

@ -7,6 +7,7 @@ import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.time.LocalDate;
import java.util.List;
/**
@ -53,7 +54,8 @@ public class SearchCompanyResult {
/**
* ; []
*/
private List<String> businessLicenseDate;
private LocalDate licenseStartTime;
private LocalDate licenseEndTime;
/**
* ; []
@ -108,7 +110,7 @@ public class SearchCompanyResult {
/**
*
*/
private String phoneNum;
private String phone;
/**
* ; audit_status

View File

@ -1,12 +1,17 @@
package com.njzscloud.supervisory.biz.service;
import cn.hutool.core.lang.Assert;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.njzscloud.common.core.ex.Exceptions;
import com.njzscloud.common.mp.support.PageParam;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.supervisory.biz.mapper.BizAuditConfigMapper;
import com.njzscloud.supervisory.biz.pojo.entity.BizAuditConfigEntity;
import com.njzscloud.supervisory.config.AppProperties;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@ -18,12 +23,25 @@ import java.util.List;
*/
@Slf4j
@Service
@RequiredArgsConstructor
public class BizAuditConfigService extends ServiceImpl<BizAuditConfigMapper, BizAuditConfigEntity> implements IService<BizAuditConfigEntity> {
private final AppProperties appProperties;
/**
*
*/
public void add(BizAuditConfigEntity bizAuditConfigEntity) {
AppProperties.DefaultPlace defaultPlace = appProperties.getDefaultPlace();
bizAuditConfigEntity.setProvince(defaultPlace.getProvince())
.setCity(defaultPlace.getCity())
.setProvinceName(defaultPlace.getProvinceName())
.setCityName(defaultPlace.getCityName());
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getArea()), () -> Exceptions.clierr("区县不能为空"));
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getAreaName()), () -> Exceptions.clierr("区县名称不能为空"));
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getCityRole()), () -> Exceptions.clierr("市级审核员不能为空"));
Assert.isTrue(StrUtil.isNotBlank(bizAuditConfigEntity.getCityRole()), () -> Exceptions.clierr("市级审核员不能为空"));
this.save(bizAuditConfigEntity);
}

View File

@ -18,16 +18,12 @@ import com.njzscloud.supervisory.biz.pojo.entity.BizCompanyEntity;
import com.njzscloud.supervisory.biz.pojo.param.AddBizCompanyParam;
import com.njzscloud.supervisory.biz.pojo.param.ModifyBizCompanyParam;
import com.njzscloud.supervisory.biz.pojo.param.SearchCompanyParam;
import com.njzscloud.supervisory.biz.pojo.result.MatchingBizCompanyResult;
import com.njzscloud.supervisory.biz.pojo.result.SearchCompanyResult;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.Collections;
import java.util.List;
/**
*
*/
@ -129,7 +125,6 @@ public class BizCompanyService extends ServiceImpl<BizCompanyMapper, BizCompanyE
* @param searchCompanyParam
* @return PageResult&lt;BizCompanyEntity&gt;
*/
public PageResult<BizCompanyEntity> paging(PageParam pageParam, SearchCompanyParam searchCompanyParam) {
BizObj bizObj = searchCompanyParam.getBizObj();
String uscc = searchCompanyParam.getUscc();
@ -164,14 +159,4 @@ public class BizCompanyService extends ServiceImpl<BizCompanyMapper, BizCompanyE
throw Exceptions.exception("数据状态已改变,无法审核");
}
}
public List<MatchingBizCompanyResult> matching() {
UserDetail userDetail = SecurityUtil.loginUser();
if (userDetail.getBizObj().equals(BizObj.ShiGongDanWei.getVal())) {
return Collections.emptyList();
}
BizCompanyEntity company = this.getOne(Wrappers.lambdaQuery(BizCompanyEntity.class).eq(BizCompanyEntity::getUserId, userDetail.getUserId()));
return baseMapper.matching(company.getId());
}
}

View File

@ -92,12 +92,6 @@ public class BizDriverService extends ServiceImpl<BizDriverMapper, BizDriverEnti
.like(StrUtil.isNotBlank(driverName), BizDriverEntity::getDriverName, driverName)));
}
@Transactional(rollbackFor = Exception.class)
public void busy(List<Long> id, Boolean busy) {
update(Wrappers.<BizDriverEntity>update()
.lambda().in(BizDriverEntity::getId, id).set(BizDriverEntity::getBusy, busy));
}
public PageResult<BizDriverEntity> dispensabilityList(PageParam pageParam, String keywords) {
UserDetail userDetail = SecurityUtil.loginUser();
SearchCompanyResult searchCompanyResult = baseMapper.selectCompanyByUserId(userDetail.getUserId());
@ -107,7 +101,7 @@ public class BizDriverService extends ServiceImpl<BizDriverMapper, BizDriverEnti
.eq(BizDriverEntity::getCompanyId, searchCompanyResult.getId())
.and(StrUtil.isNotBlank(keywords), it ->
it.like(BizDriverEntity::getDriverName, keywords)
.or().like(BizDriverEntity::getPhoneNum, keywords))
.or().like(BizDriverEntity::getPhone, keywords))
));
}
}

View File

@ -0,0 +1,9 @@
package com.njzscloud.supervisory.config;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;
@Configuration
@EnableConfigurationProperties(AppProperties.class)
public class AppConfiguration {
}

View File

@ -0,0 +1,28 @@
package com.njzscloud.supervisory.config;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import org.springframework.boot.context.properties.ConfigurationProperties;
@Getter
@Setter
@ToString
@Accessors(chain = true)
@ConfigurationProperties(prefix = "app")
public class AppProperties {
private DefaultPlace defaultPlace;
@Getter
@Setter
@ToString
@Accessors(chain = true)
public static class DefaultPlace {
private String province;
private String city;
private String provinceName;
private String cityName;
}
}

View File

@ -0,0 +1,68 @@
package com.njzscloud.supervisory.order.controller;
import com.njzscloud.common.core.utils.R;
import com.njzscloud.common.mp.support.PageParam;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.supervisory.order.pojo.entity.OrderCargoPlaceEntity;
import com.njzscloud.supervisory.order.service.OrderCargoPlaceService;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/**
*
*/
@Slf4j
@RestController
@RequestMapping("/order_cargo_place")
@RequiredArgsConstructor
public class OrderCargoPlaceController {
private final OrderCargoPlaceService orderCargoPlaceService;
/**
*
*/
@PostMapping("/add")
public R<?> add(@RequestBody OrderCargoPlaceEntity orderCargoPlaceEntity) {
orderCargoPlaceService.add(orderCargoPlaceEntity);
return R.success();
}
/**
*
*/
@PostMapping("/modify")
public R<?> modify(@RequestBody OrderCargoPlaceEntity orderCargoPlaceEntity) {
orderCargoPlaceService.modify(orderCargoPlaceEntity);
return R.success();
}
/**
*
*/
@PostMapping("/del")
public R<?> del(@RequestBody List<Long> ids) {
orderCargoPlaceService.del(ids);
return R.success();
}
/**
*
*/
@GetMapping("/detail")
public R<OrderCargoPlaceEntity> detail(@RequestParam Long id) {
return R.success(orderCargoPlaceService.detail(id));
}
/**
*
*/
@GetMapping("/paging")
public R<PageResult<OrderCargoPlaceEntity>> paging(PageParam pageParam, OrderCargoPlaceEntity orderCargoPlaceEntity) {
return R.success(orderCargoPlaceService.paging(pageParam, orderCargoPlaceEntity));
}
}

View File

@ -3,13 +3,19 @@ package com.njzscloud.supervisory.order.controller;
import com.njzscloud.common.core.utils.R;
import com.njzscloud.common.mp.support.PageParam;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.common.security.support.UserDetail;
import com.njzscloud.common.security.util.SecurityUtil;
import com.njzscloud.supervisory.order.pojo.entity.OrderInfoEntity;
import com.njzscloud.supervisory.order.pojo.param.AuditOrderParam;
import com.njzscloud.supervisory.order.pojo.param.OrderPagingSearchParam;
import com.njzscloud.supervisory.order.pojo.result.OrderPagingResult;
import com.njzscloud.supervisory.order.service.OrderInfoService;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;
import java.util.List;
import java.util.Set;
/**
*
@ -53,7 +59,7 @@ public class OrderInfoController {
*
*/
@GetMapping("/detail")
public R<OrderInfoEntity> detail(@RequestParam Long id) {
public R<OrderPagingResult> detail(@RequestParam Long id) {
return R.success(orderInfoService.detail(id));
}
@ -61,8 +67,27 @@ public class OrderInfoController {
*
*/
@GetMapping("/paging")
public R<PageResult<OrderInfoEntity>> paging(PageParam pageParam, OrderInfoEntity orderInfoEntity) {
return R.success(orderInfoService.paging(pageParam, orderInfoEntity));
public R<PageResult<OrderPagingResult>> paging(PageParam pageParam, OrderPagingSearchParam orderPagingSearchParam) {
return R.success(orderInfoService.paging(pageParam, orderPagingSearchParam));
}
/**
*
*/
@GetMapping("/audit_paging")
public R<PageResult<OrderPagingResult>> auditPaging(PageParam pageParam, OrderPagingSearchParam orderPagingSearchParam) {
UserDetail userDetail = SecurityUtil.loginUser();
Set<String> roles = userDetail.getRoles();
return R.success(orderInfoService.auditPaging(pageParam, orderPagingSearchParam.setRoles(roles)));
}
/**
*
*/
@GetMapping("/audit")
public R<PageResult<OrderPagingResult>> audit(AuditOrderParam auditOrderParam) {
orderInfoService.audit(auditOrderParam);
return R.success();
}
}

View File

@ -0,0 +1,13 @@
package com.njzscloud.supervisory.order.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.njzscloud.supervisory.order.pojo.entity.OrderCargoPlaceEntity;
import org.apache.ibatis.annotations.Mapper;
/**
*
*/
@Mapper
public interface OrderCargoPlaceMapper extends BaseMapper<OrderCargoPlaceEntity> {
}

View File

@ -1,8 +1,12 @@
package com.njzscloud.supervisory.order.mapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.njzscloud.supervisory.order.pojo.entity.OrderInfoEntity;
import com.njzscloud.supervisory.order.pojo.result.OrderPagingResult;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
/**
*
@ -10,4 +14,7 @@ import org.apache.ibatis.annotations.Mapper;
@Mapper
public interface OrderInfoMapper extends BaseMapper<OrderInfoEntity> {
Page<OrderPagingResult> paging(Page<OrderPagingResult> page, @Param("ew") QueryWrapper<OrderPagingResult> ew);
OrderPagingResult detail(@Param("ew") QueryWrapper<OrderPagingResult> ew);
}

View File

@ -70,10 +70,4 @@ public class OrderCarInOutEntity {
*
*/
private LocalDateTime outTime;
/**
* ;
*/
private String checkPhoto;
}

View File

@ -0,0 +1,82 @@
package com.njzscloud.supervisory.order.pojo.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
/**
*
*/
@Getter
@Setter
@ToString
@Accessors(chain = true)
@TableName("order_cargo_place")
public class OrderCargoPlaceEntity {
/**
* Id
*/
@TableId(type = IdType.ASSIGN_ID)
private Long id;
/**
* ;
*/
private String province;
/**
* ;
*/
private String city;
/**
* ;
*/
private String area;
/**
* ;
*/
private String town;
/**
* ;
*/
private String provinceName;
/**
* ;
*/
private String cityName;
/**
* ;
*/
private String areaName;
/**
* ;
*/
private String townName;
/**
*
*/
private String address;
/**
*
*/
private Double lng;
/**
*
*/
private Double lat;
}

View File

@ -34,7 +34,7 @@ public class OrderGoodsEntity {
/**
* Id
*/
private Long goodsId;
private Long originGoodsId;
/**
*

View File

@ -1,6 +1,7 @@
package com.njzscloud.supervisory.order.pojo.entity;
import com.baomidou.mybatisplus.annotation.*;
import com.njzscloud.supervisory.biz.contant.AuditStatus;
import com.njzscloud.supervisory.order.contant.OrderCategory;
import com.njzscloud.supervisory.order.contant.OrderStatus;
import com.njzscloud.supervisory.order.contant.PayerCategory;
@ -34,6 +35,11 @@ public class OrderInfoEntity {
*/
private String sn;
/**
* Id
*/
private Long cargoPlaceId;
/**
* Id
*/
@ -52,7 +58,7 @@ public class OrderInfoEntity {
/**
* ; audit_status
*/
private String auditStatus;
private AuditStatus auditStatus;
/**
*

View File

@ -0,0 +1,28 @@
package com.njzscloud.supervisory.order.pojo.param;
import com.njzscloud.supervisory.biz.contant.AuditStatus;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
@Getter
@Setter
@ToString
@Accessors(chain = true)
public class AuditOrderParam {
/**
* Id
*/
private Long id;
/**
* ; audit_status
*/
private AuditStatus auditStatus;
/**
*
*/
private String auditMemo;
}

View File

@ -0,0 +1,50 @@
package com.njzscloud.supervisory.order.pojo.param;
import com.njzscloud.supervisory.biz.contant.AuditStatus;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.time.LocalDateTime;
import java.util.Set;
@Getter
@Setter
@ToString
@Accessors(chain = true)
public class OrderPagingSearchParam {
private Set<String> roles;
/**
* ; audit_status
*/
private AuditStatus auditStatus;
/**
* ; order_status
*/
private String orderStatus;
/**
*
*/
private String sn;
/**
*
*/
private String licensePlate;
/**
*
*/
private String nickname;
/**
*
*/
private String phone;
private LocalDateTime startTime;
private LocalDateTime endTime;
}

View File

@ -0,0 +1,421 @@
package com.njzscloud.supervisory.order.pojo.result;
import com.njzscloud.supervisory.biz.contant.AuditStatus;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;
@Getter
@Setter
@ToString
@Accessors(chain = true)
public class OrderPagingResult {
// region 用户信息
/**
*
*/
private String nickname;
/**
*
*/
private String phone;
// endregion
// region 订单信息
/**
* Id
*/
private Long id;
/**
*
*/
private String sn;
/**
* Id
*/
private Long stationId;
/**
*
*/
private String laneId;
/**
* Id
*/
private Long projectId;
/**
* Id
*/
private Long cargoPlaceId;
/**
* Id
*/
private Long trafficCompanyId;
/**
* Id; sys_user.id
*/
private Long userId;
/**
* ; audit_status
*/
private AuditStatus auditStatus;
/**
*
*/
private String auditMemo;
/**
* ; order_category
*/
private String orderCategory;
/**
* ; order_status
*/
private String orderStatus;
/**
* Id; sys_user.id
*/
private Long checkerId;
/**
* ; check_status
*/
private String checkStatus;
/**
* Id
*/
private Long truckId;
/**
* Id
*/
private Long driverId;
/**
* Id; order_goods.id
*/
private Long goodsId;
/**
* ;
*/
private BigDecimal discountMoney;
/**
* ;
*/
private BigDecimal reviseMoney;
/**
* ;
*/
private BigDecimal settleMoney;
/**
* Id
*/
private Long payer;
/**
* ; payer_category
*/
private String payerCategory;
/**
* ; payment_status
*/
private String paymentStatus;
/**
*
*/
private LocalDateTime paymentTime;
/**
*
*/
private String customerMemo;
/**
*
*/
private String checkerMemo;
/**
*
*/
private String cargoPhoto;
/**
*
*/
private String checkPhoto;
/**
*
*/
private Long carInOutId;
// endregion
// region 产品信息
/**
* Id
*/
private Long goodsCategoryId;
/**
* Id
*/
private Long originGoodsId;
/**
*
*/
private String goodsName;
/**
* ;
*/
private BigDecimal unitPrice;
/**
* ; unit
*/
private String unit;
/**
* ; money_strategy
*/
private String moneyStrategy;
/**
* Id
*/
private Long moneyConfigId;
/**
*
*/
private String picture;
/**
*
*/
private BigDecimal taxRate;
/**
*
*/
private Integer quantity;
/**
* ;
*/
private BigDecimal totalMoney;
// endregion
// region 装货地址
/**
* ;
*/
private String province;
/**
* ;
*/
private String city;
/**
* ;
*/
private String area;
/**
* ;
*/
private String town;
/**
* ;
*/
private String provinceName;
/**
* ;
*/
private String cityName;
/**
* ;
*/
private String areaName;
/**
* ;
*/
private String townName;
/**
*
*/
private String address;
/**
*
*/
private Double lng;
/**
*
*/
private Double lat;
// endregion
// region 进出场信息
/**
* ;
*/
private Integer roughWeight;
/**
* ;
*/
private Integer tareWeight;
/**
*
*/
private Integer settleWeight;
/**
*
*/
private String inFrontPhoto;
/**
*
*/
private String inBodyPhoto;
/**
*
*/
private String outFrontPhoto;
/**
*
*/
private String outBodyPhoto;
/**
*
*/
private LocalDateTime inTime;
/**
*
*/
private LocalDateTime outTime;
// endregion
// region 车辆信息
/**
*
*/
private String licensePlate;
/**
*
*/
private String truckLicense;
/**
*
*/
private String vnCode;
/**
*
*/
private String qualification;
/**
* ;
*/
private Integer carryingCapacity;
/**
* ;
*/
private Integer historyTareWeight;
// endregion
// region 司机信息
/**
*
*/
private String driverName;
/**
*
*/
private String driverPhone;
/**
*
*/
private String drivingLicence;
/**
*
*/
private LocalDate licenceStartTime;
/**
*
*/
private LocalDate licenceEndTime;
// endregion
// region 企业信息
private String trafficCompanyUscc;
private String trafficCompanyCompanyName;
private String trafficCompanyBusinessLicense;
private LocalDate trafficCompanyLicenseStartTime;
private LocalDate trafficCompanyLicenseEndTime;
private String trafficCompanyLegalRepresentative;
private String trafficCompanyProvince;
private String trafficCompanyCity;
private String trafficCompanyArea;
private String trafficCompanyTown;
private String trafficCompanyProvinceName;
private String trafficCompanyCityName;
private String trafficCompanyAreaName;
private String trafficCompanyTownName;
private String trafficCompanyAddress;
private Double trafficCompanyLng;
private Double trafficCompanyLat;
private String trafficCompanyContacts;
private String trafficCompanyPhone;
// endregion
}

View File

@ -0,0 +1,59 @@
package com.njzscloud.supervisory.order.service;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.njzscloud.common.mp.support.PageParam;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.supervisory.order.mapper.OrderCargoPlaceMapper;
import com.njzscloud.supervisory.order.pojo.entity.OrderCargoPlaceEntity;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;
/**
*
*/
@Slf4j
@Service
public class OrderCargoPlaceService extends ServiceImpl<OrderCargoPlaceMapper, OrderCargoPlaceEntity> implements IService<OrderCargoPlaceEntity> {
/**
*
*/
public void add(OrderCargoPlaceEntity orderCargoPlaceEntity) {
this.save(orderCargoPlaceEntity);
}
/**
*
*/
public void modify(OrderCargoPlaceEntity orderCargoPlaceEntity) {
this.updateById(orderCargoPlaceEntity);
}
/**
*
*/
@Transactional(rollbackFor = Exception.class)
public void del(List<Long> ids) {
this.removeBatchByIds(ids);
}
/**
*
*/
public OrderCargoPlaceEntity detail(Long id) {
return this.getById(id);
}
/**
*
*/
public PageResult<OrderCargoPlaceEntity> paging(PageParam pageParam, OrderCargoPlaceEntity orderCargoPlaceEntity) {
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<OrderCargoPlaceEntity>query(orderCargoPlaceEntity)));
}
}

View File

@ -1,25 +1,43 @@
package com.njzscloud.supervisory.order.service;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.lang.Assert;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.njzscloud.common.core.ex.Exceptions;
import com.njzscloud.common.mp.support.PageParam;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.common.security.util.SecurityUtil;
import com.njzscloud.supervisory.biz.contant.AuditStatus;
import com.njzscloud.supervisory.biz.pojo.entity.BizAuditConfigEntity;
import com.njzscloud.supervisory.biz.service.BizAuditConfigService;
import com.njzscloud.supervisory.order.mapper.OrderInfoMapper;
import com.njzscloud.supervisory.order.pojo.entity.OrderInfoEntity;
import com.njzscloud.supervisory.order.pojo.param.AuditOrderParam;
import com.njzscloud.supervisory.order.pojo.param.OrderPagingSearchParam;
import com.njzscloud.supervisory.order.pojo.result.OrderPagingResult;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Set;
import java.util.stream.Collectors;
/**
*
*/
@Slf4j
@Service
@RequiredArgsConstructor
public class OrderInfoService extends ServiceImpl<OrderInfoMapper, OrderInfoEntity> implements IService<OrderInfoEntity> {
private final BizAuditConfigService bizAuditConfigService;
/**
*
*/
@ -45,15 +63,89 @@ public class OrderInfoService extends ServiceImpl<OrderInfoMapper, OrderInfoEnti
/**
*
*/
public OrderInfoEntity detail(Long id) {
return this.getById(id);
public OrderPagingResult detail(Long id) {
return baseMapper.detail(Wrappers.<OrderPagingResult>query()
.in("a.id", id));
}
/**
*
*/
public PageResult<OrderInfoEntity> paging(PageParam pageParam, OrderInfoEntity orderInfoEntity) {
return PageResult.of(this.page(pageParam.toPage(), Wrappers.<OrderInfoEntity>query(orderInfoEntity)));
public PageResult<OrderPagingResult> paging(PageParam pageParam, OrderPagingSearchParam orderPagingSearchParam) {
AuditStatus auditStatus = orderPagingSearchParam.getAuditStatus();
String orderStatus = orderPagingSearchParam.getOrderStatus();
String sn = orderPagingSearchParam.getSn();
String licensePlate = orderPagingSearchParam.getLicensePlate();
String nickname = orderPagingSearchParam.getNickname();
String phone = orderPagingSearchParam.getPhone();
LocalDateTime startTime = orderPagingSearchParam.getStartTime();
LocalDateTime endTime = orderPagingSearchParam.getEndTime();
return PageResult.of(baseMapper.paging(pageParam.toPage(), Wrappers.<OrderPagingResult>query()
.like(StrUtil.isNotBlank(sn), "a.sn", sn)
.like(StrUtil.isNotBlank(licensePlate), "a.license_plate", licensePlate)
.like(StrUtil.isNotBlank(nickname), "h.nickname", nickname)
.like(StrUtil.isNotBlank(phone), "h.phone", phone)
.eq(auditStatus != null, "a.audit_status", auditStatus)
.eq(orderStatus != null, "a.order_status", orderStatus)
.between(startTime != null && endTime != null, "a.create_time", startTime, endTime)
));
}
public PageResult<OrderPagingResult> auditPaging(PageParam pageParam, OrderPagingSearchParam orderPagingSearchParam) {
Set<String> roles = orderPagingSearchParam.getRoles();
List<String> areas = bizAuditConfigService.list(Wrappers.<BizAuditConfigEntity>query()
.select("DISTINCT area")
.in("area_role", roles)
.or().in("city_role", roles)
).stream().map(BizAuditConfigEntity::getArea).collect(Collectors.toList());
if (CollUtil.isEmpty(areas)) {
return PageResult.of(pageParam.toPage());
}
return PageResult.of(baseMapper.paging(pageParam.toPage(), Wrappers.<OrderPagingResult>query()
.in("b.area", areas)));
}
public void audit(AuditOrderParam auditOrderParam) {
OrderPagingResult detail = detail(auditOrderParam.getId());
Assert.notNull(detail, () -> Exceptions.clierr("订单不存在"));
AuditStatus auditStatus = detail.getAuditStatus();
Assert.isTrue(auditStatus == AuditStatus.QuDaiShenHe
|| auditStatus == AuditStatus.ShiDaiShenHe,
() -> Exceptions.clierr("订单已审核"));
Assert.isTrue(auditStatus == AuditStatus.TongGuo || auditStatus == AuditStatus.BoHui);
Set<String> roles = SecurityUtil.loginUser().getRoles();
String area = detail.getArea();
BizAuditConfigEntity config = bizAuditConfigService.getOne(Wrappers.<BizAuditConfigEntity>query()
.eq("area", detail.getArea()));
String areaRole = config.getAreaRole();
String cityRole = config.getCityRole();
if (!roles.contains(areaRole) && !roles.contains(cityRole)) {
throw Exceptions.clierr("您没有权限审核该订单");
}
AuditStatus newAuditStatus = auditOrderParam.getAuditStatus();
if (auditStatus == AuditStatus.QuDaiShenHe) {
if (StrUtil.isBlank(areaRole) && roles.contains(areaRole)) {
auditStatus = newAuditStatus == AuditStatus.TongGuo ? AuditStatus.ShiDaiShenHe : newAuditStatus;
} else {
throw Exceptions.clierr("您没有权限审核该订单");
}
} else {
if (StrUtil.isBlank(cityRole) && roles.contains(cityRole)) {
auditStatus = newAuditStatus;
} else {
throw Exceptions.clierr("您没有权限审核该订单");
}
}
detail.setAuditStatus(newAuditStatus);
detail.setAuditMemo(auditOrderParam.getAuditMemo());
this.updateById(new OrderInfoEntity()
.setAuditStatus(auditStatus)
.setAuditMemo(auditOrderParam.getAuditMemo())
);
}
}

View File

@ -9,6 +9,9 @@ import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
*
*/
@Slf4j
@RestController
@RequestMapping("/auth")

View File

@ -1,8 +1,10 @@
package com.njzscloud.supervisory.sys.district.controller;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.njzscloud.common.core.utils.R;
import com.njzscloud.common.mp.support.PageParam;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.supervisory.config.AppProperties;
import com.njzscloud.supervisory.sys.district.pojo.entity.DistrictEntity;
import com.njzscloud.supervisory.sys.district.pojo.result.DistrictTreeResult;
import com.njzscloud.supervisory.sys.district.service.DistrictService;
@ -20,8 +22,8 @@ import java.util.List;
@RequestMapping("/district")
@RequiredArgsConstructor
public class DistrictController {
private final DistrictService districtService;
private final AppProperties appProperties;
/**
*
@ -66,6 +68,17 @@ public class DistrictController {
return R.success(districtService.paging(pageParam, districtEntity));
}
/**
*
*/
@GetMapping("/obtain_area")
public R<List<DistrictEntity>> obtainArea() {
AppProperties.DefaultPlace defaultPlace = appProperties.getDefaultPlace();
return R.success(districtService.list(Wrappers.<DistrictEntity>lambdaQuery()
.eq(DistrictEntity::getPid, defaultPlace.getCity())
.orderByAsc(DistrictEntity::getSort, DistrictEntity::getId)));
}
/**
*
*/

View File

@ -1,11 +1,19 @@
package com.njzscloud.supervisory.sys.resource.cotroller;
import cn.hutool.core.util.StrUtil;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.njzscloud.common.core.utils.R;
import com.njzscloud.supervisory.sys.resource.pojo.entity.ResourceEntity;
import com.njzscloud.supervisory.sys.resource.service.ResourceService;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;
/**
*
*/
@ -16,4 +24,16 @@ import org.springframework.web.bind.annotation.RestController;
public class ResourceController {
private final ResourceService resourceService;
@GetMapping("/list")
public R<List<ResourceEntity>> list(
@RequestParam(value = "tableName", required = false) String tableName,
@RequestParam(value = "keywords", required = false) String keywords
) {
return R.success(resourceService.list(Wrappers.<ResourceEntity>lambdaQuery()
.eq(StrUtil.isNotBlank(tableName), ResourceEntity::getTableName, tableName)
.and(StrUtil.isNotBlank(keywords), ew -> ew.like(ResourceEntity::getSn, keywords)
.or().like(ResourceEntity::getMemo, keywords))
));
}
}

View File

@ -76,9 +76,10 @@ public class UserController {
*/
@PostMapping("/register")
public R<?> register(@RequestBody @Validated UserRegisterParam userRegisterParam) {
userService.register(userRegisterParam);
return R.success();
String token = userService.register(userRegisterParam);
return R.success(token);
}
/**
*
*/

View File

@ -1,6 +1,7 @@
package com.njzscloud.supervisory.sys.user.pojo.entity;
import com.baomidou.mybatisplus.annotation.*;
import com.njzscloud.supervisory.biz.contant.BizObj;
import com.njzscloud.supervisory.sys.user.contant.Gender;
import lombok.Getter;
import lombok.Setter;
@ -24,7 +25,10 @@ public class UserEntity {
*/
@TableId(type = IdType.ASSIGN_ID)
private Long id;
/**
* ; biz_obj
*/
private BizObj bizObj;
private Long tenantId;
/**

View File

@ -10,9 +10,7 @@ import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import java.util.List;
import java.time.LocalDate;
@Getter
@Setter
@ -48,7 +46,6 @@ public class UserRegisterParam implements Constrained {
/**
*
*/
@Valid
private Company company;
@ -131,48 +128,42 @@ public class UserRegisterParam implements Constrained {
/**
*
*/
@NotBlank(message = "企业名称不能为空")
private String companyName;
/**
* ; biz_company.uscc
*/
@NotBlank(message = "统一社会信用代码不能为空")
private String uscc;
/**
* ;
*/
@NotBlank(message = "营业执照不能为空")
private String businessLicense;
/**
* ; []
*/
private List<String> businessLicenseDate;
private LocalDate licenseStartTime;
private LocalDate licenseEndTime;
/**
*
*/
@NotBlank(message = "法人名称不能为空")
private String legalRepresentative;
/**
* ;
*/
@NotBlank(message = "位置信息不能为空")
private String province;
/**
* ;
*/
@NotBlank(message = "位置信息不能为空")
private String city;
/**
* ;
*/
@NotBlank(message = "位置信息不能为空")
private String county;
private String town;
@ -180,19 +171,16 @@ public class UserRegisterParam implements Constrained {
/**
* ;
*/
@NotBlank(message = "位置信息不能为空")
private String provinceName;
/**
* ;
*/
@NotBlank(message = "位置信息不能为空")
private String cityName;
/**
* ;
*/
@NotBlank(message = "位置信息不能为空")
private String countyName;
/**
@ -203,31 +191,26 @@ public class UserRegisterParam implements Constrained {
/**
*
*/
@NotBlank(message = "位置信息不能为空")
private String address;
/**
*
*/
@NotBlank(message = "位置信息不能为空")
private String lng;
/**
*
*/
@NotBlank(message = "位置信息不能为空")
private String lat;
/**
*
*/
@NotBlank(message = "联系人不能为空")
private String contacts;
/**
*
*/
@NotBlank(message = "联系电话不能为空")
private String phone;

View File

@ -36,7 +36,7 @@ public class UserAccountService extends ServiceImpl<UserAccountMapper, UserAccou
String wechatOpenid = addUserAccountParam.getWechatOpenid();
String wechatUnionid = addUserAccountParam.getWechatUnionid();
List<UserAccountEntity> oldSysUserList = this.list(Wrappers.<UserAccountEntity>lambdaQuery()
.eq(UserAccountEntity::getUsername, username)
.eq(StrUtil.isNotBlank(username), UserAccountEntity::getUsername, username)
.or().eq(StrUtil.isNotBlank(email), UserAccountEntity::getEmail, email)
.or().eq(StrUtil.isNotBlank(phone), UserAccountEntity::getPhone, phone)
.or(StrUtil.isNotBlank(wechatOpenid) && StrUtil.isNotBlank(wechatUnionid), it -> it.eq(UserAccountEntity::getWechatOpenid, wechatOpenid).eq(UserAccountEntity::getWechatUnionid, wechatUnionid))

View File

@ -8,10 +8,9 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.njzscloud.common.core.ex.ExceptionMsg;
import com.njzscloud.common.core.ex.Exceptions;
import com.njzscloud.common.mp.support.PageResult;
import com.njzscloud.common.security.ex.UserLoginException;
import com.njzscloud.common.security.contant.AuthWay;
import com.njzscloud.common.security.util.EncryptUtil;
import com.njzscloud.common.security.util.SecurityUtil;
import com.njzscloud.supervisory.biz.contant.BizObj;
@ -137,19 +136,21 @@ public class UserService extends ServiceImpl<UserMapper, UserEntity> implements
* @param userRegisterParam
*/
@Transactional(rollbackFor = Exception.class)
public void register(UserRegisterParam userRegisterParam) {
public String register(UserRegisterParam userRegisterParam) {
BizObj bizObj = userRegisterParam.getBizObj();
if (bizObj == BizObj.GeRen) {
String codeId = userRegisterParam.getAccount().getCodeId();
String code = userRegisterParam.getAccount().getCode();
Assert.isTrue(EncryptUtil.checkCode(codeId, code), () -> new UserLoginException(ExceptionMsg.CLI_ERR_MSG, "验证码错误"));
Assert.isTrue(EncryptUtil.checkCode(codeId, code), () -> Exceptions.clierr("验证码错误"));
}
AddUserParam addUserParam = BeanUtil.copyProperties(userRegisterParam, AddUserParam.class);
addUserParam.setAccount(BeanUtil.copyProperties(userRegisterParam.getAccount(), AddUserAccountParam.class));
Long userId = this.add(addUserParam);
if (bizObj == BizObj.GeRen) return;
if (bizObj == BizObj.GeRen) {
return SecurityUtil.registrationToken(userRegisterParam.getAccount().getPhone(), AuthWay.PHONE);
}
UserRegisterParam.Company company = userRegisterParam.getCompany();
Assert.notNull(company, "公司信息不能为空");
@ -159,6 +160,7 @@ public class UserService extends ServiceImpl<UserMapper, UserEntity> implements
.setUserId(userId)
.setBizObj(bizObj);
bizCompanyService.add(addBizCompanyParam);
return SecurityUtil.registrationToken(userRegisterParam.getAccount().getUsername(), AuthWay.PASSWORD);
}
/**

View File

@ -6,6 +6,16 @@ spring:
security:
auth-ignores:
- /auth/obtain_code
- /user/register
- /oss/**
- /district/tree
app:
default-place:
province: 340000
city: 341100
province-name: 安徽省
city-name: 滁州市
oss:
type: ali

View File

@ -2,17 +2,4 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.njzscloud.supervisory.biz.mapper.BizCompanyMapper">
<resultMap id="matchingMap" autoMapping="true" type="com.njzscloud.supervisory.biz.pojo.result.MatchingBizCompanyResult">
<result property="bizObj" column="biz_obj" typeHandler="com.njzscloud.common.mp.support.handler.e.EnumTypeHandlerDealer"/>
<result property="businessLicenseDate" column="business_license_date" typeHandler="com.njzscloud.common.mp.support.handler.j.JsonTypeHandler"/>
<result property="certificationDate" column="certification_date" typeHandler="com.njzscloud.common.mp.support.handler.j.JsonTypeHandler"/>
</resultMap>
<select id="matching" resultMap="matchingMap">
SELECT *
FROM biz_company a
INNER JOIN biz_contract b ON b.biz_company_id = a.id AND b.biz_company_id = #{companyId}
ORDER BY b.create_time DESC
</select>
</mapper>

View File

@ -3,4 +3,130 @@
<mapper namespace="com.njzscloud.supervisory.order.mapper.OrderInfoMapper">
</mapper>
<sql id="base_select">
SELECT a.id,
a.sn,
a.station_id,
a.lane_id,
a.project_id,
a.traffic_company_id,
a.user_id,
a.audit_status,
a.audit_memo,
a.order_category,
a.order_status,
a.checker_id,
a.check_status,
a.truck_id,
a.driver_id,
a.goods_id,
a.discount_money,
a.revise_money,
a.settle_money,
a.payer,
a.payer_category,
a.payment_status,
a.payment_time,
a.customer_memo,
a.checker_memo,
a.cargo_photo,
a.check_photo,
a.creator_id,
a.modifier_id,
a.create_time,
a.modify_time,
a.deleted,
a.cargo_place_id,
a.car_in_out_id,
b.province,
b.city,
b.area,
b.town,
b.province_name,
b.city_name,
b.area_name,
b.town_name,
b.address,
b.lng,
b.lat,
c.goods_category_id,
c.origin_goods_id,
c.goods_name,
c.unit_price,
c.unit,
c.money_strategy,
c.money_config_id,
c.picture,
c.tax_rate,
c.quantity,
c.total_money,
d.rough_weight,
d.tare_weight,
d.settle_weight,
d.in_front_photo,
d.in_body_photo,
d.out_front_photo,
d.out_body_photo,
d.in_time,
d.out_time,
e.license_plate,
e.truck_license,
e.vn_code,
e.qualification,
e.carrying_capacity,
e.tare_weight history_tare_weight,
e.audit_status,
e.audit_memo,
f.driver_name,
f.phone driver_phone,
f.driving_licence,
f.licence_start_time,
f.licence_end_time,
g.uscc tarffic_company_uscc,
g.company_name tarffic_company_company_name,
g.business_license tarffic_company_business_license,
g.license_start_time tarffic_company_license_start_time,
g.license_end_time tarffic_company_license_end_time,
g.legal_representative tarffic_company_legal_representative,
g.province tarffic_company_province,
g.city tarffic_company_city,
g.area tarffic_company_area,
g.town tarffic_company_town,
g.province_name tarffic_company_province_name,
g.city_name tarffic_company_city_name,
g.area_name tarffic_company_area_name,
g.town_name tarffic_company_town_name,
g.address tarffic_company_address,
g.lng tarffic_company_lng,
g.lat tarffic_company_lat,
g.contacts tarffic_company_contacts,
g.phone tarffic_company_phone,
h.nickname,
h.phone
FROM order_info a
INNER JOIN order_cargo_place b ON b.id = a.cargo_place_id
INNER JOIN order_goods c ON c.id = a.goods_id
INNER JOIN order_car_in_out d ON d.id = a.car_in_out_id
INNER JOIN biz_truck e ON e.id = a.truck_id
INNER JOIN biz_driver f ON f.id = a.driver_id
INNER JOIN biz_company g ON g.id = a.traffic_company_id
INNER JOIN sys_user h ON h.id = a.user_id
<if test="ew.customSqlSegment != null and ew.customSqlSegment != ''">
${ew.customSqlSegment}
</if>
</sql>
<select id="paging" resultType="com.njzscloud.supervisory.order.pojo.result.OrderPagingResult">
<include refid="base_select"/>
</select>
<select id="detail" resultType="com.njzscloud.supervisory.order.pojo.result.OrderPagingResult">
<include refid="base_select"/>
</select>
</mapper>

View File

@ -4,7 +4,7 @@
"avatar": "data:image/png;base64,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",
"version": "4.9.4",
"createdTime": "2023-4-13 11:53:52",
"updatedTime": "2025-9-12 09:53:02",
"updatedTime": "2025-9-12 16:38:16",
"dbConns": [],
"profile": {
"default": {
@ -622,7 +622,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231",
@ -678,7 +678,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231",
@ -1858,7 +1858,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -1886,7 +1886,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -1915,7 +1915,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -1943,7 +1943,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -1971,7 +1971,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -1999,7 +1999,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -3727,7 +3727,7 @@
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
@ -10042,6 +10042,23 @@
"extProps": {},
"id": "7C7B38D2-1BC8-42C9-9C76-CA65500EBB6E"
},
{
"defKey": "cargo_place_id",
"defName": "装货地址 Id",
"comment": "",
"type": "BIGINT",
"len": "",
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"baseType": "9B6B9E10-DB11-4409-878B-5868A19CD9B0",
"extProps": {},
"id": "5C0F4129-75F7-4EF4-BEFE-AEF7F2853800"
},
{
"defKey": "traffic_company_id",
"defName": "清运公司 Id",
@ -10416,6 +10433,23 @@
"extProps": {},
"id": "A05A5473-4286-4665-881E-7789ABFEB881"
},
{
"defKey": "car_in_out_id",
"defName": "进出场信息",
"comment": "",
"type": "BIGINT",
"len": "",
"scale": "",
"primaryKey": false,
"notNull": false,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"baseType": "9B6B9E10-DB11-4409-878B-5868A19CD9B0",
"extProps": {},
"id": "D7E1B58D-74B5-44DA-8263-00D1AAE40FEC"
},
{
"defKey": "creator_id",
"defName": "创建人 Id",
@ -10510,6 +10544,469 @@
"indexes": [],
"type": "P"
},
{
"id": "E24A8C8D-A81D-4BC7-B046-09E4E0FAC2A0",
"env": {
"base": {
"nameSpace": "",
"codeRoot": ""
}
},
"defKey": "order_cargo_place",
"defName": "装货地址",
"comment": "",
"properties": {},
"sysProps": {
"nameTemplate": "{defKey}[{defName}]"
},
"notes": {},
"headers": [
{
"refKey": "hideInGraph",
"hideInGraph": true
},
{
"refKey": "defKey",
"freeze": false,
"hideInGraph": false
},
{
"refKey": "type",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "len",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "scale",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "defaultValue",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "defName",
"freeze": false,
"hideInGraph": false
},
{
"refKey": "comment",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "notNull",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "primaryKey",
"freeze": false,
"hideInGraph": false
},
{
"refKey": "autoIncrement",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "refDict",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "domain",
"freeze": false,
"hideInGraph": false
},
{
"refKey": "isStandard",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "uiHint",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "extProps",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr1",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr2",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr3",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr4",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr5",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr6",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr7",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr8",
"freeze": false,
"hideInGraph": true
},
{
"refKey": "attr9",
"freeze": false,
"hideInGraph": true
}
],
"fields": [
{
"defKey": "id",
"defName": "Id",
"comment": "",
"type": "BIGINT",
"len": "",
"scale": "",
"primaryKey": true,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"domain": "",
"id": "2455E36E-06AE-42E0-AF93-A1BCF0574128",
"baseType": "9B6B9E10-DB11-4409-878B-5868A19CD9B0"
},
{
"defKey": "province",
"defName": "省",
"comment": "代码",
"type": "VARCHAR",
"len": 16,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "70411BB4-9BDD-4FD4-B066-BBD419F5A7A5",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "city",
"defName": "市",
"comment": "代码",
"type": "VARCHAR",
"len": 16,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "3A162332-AA40-467C-B289-BAE632CE9048",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "area",
"defName": "区县",
"comment": "代码",
"type": "VARCHAR",
"len": 16,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "897E6EEF-086B-450C-BB6A-7D0B62C63922",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "town",
"defName": "乡镇街道",
"comment": "代码",
"type": "VARCHAR",
"len": 16,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "023F5696-F000-4320-A72D-F0EB0EC2AE91",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "province_name",
"defName": "省",
"comment": "名称",
"type": "VARCHAR",
"len": 255,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "1732F9D9-9F25-4900-A5B7-2A4184C50E14",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "city_name",
"defName": "市",
"comment": "名称",
"type": "VARCHAR",
"len": 255,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "1B76F21A-A477-47FE-BF47-4CCBA78521B7",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "area_name",
"defName": "区县",
"comment": "名称",
"type": "VARCHAR",
"len": 255,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "70EA5A12-3D01-4AF9-86D5-3033A13F3646",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "town_name",
"defName": "乡镇街道",
"comment": "名称",
"type": "VARCHAR",
"len": 255,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "B3450C60-733B-4ED1-8F98-B84A20BDD8BD",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "address",
"defName": "详细地址",
"comment": "",
"type": "VARCHAR",
"len": 255,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "''",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "3EED215A-BA6E-43EF-A5A0-5C2A9AF9A557",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231"
},
{
"defKey": "lng",
"defName": "经度",
"comment": "",
"type": "DOUBLE",
"len": "",
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "6B06DC00-7912-4FFE-B6AE-CD6E4D27F3C8",
"baseType": "D57B7F8D-4728-43D3-9F21-A1953D885CFB"
},
{
"defKey": "lat",
"defName": "纬度",
"comment": "",
"type": "DOUBLE",
"len": "",
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"extProps": {},
"notes": {},
"attr1": "",
"attr2": "",
"attr3": "",
"attr4": "",
"attr5": "",
"attr6": "",
"attr7": "",
"attr8": "",
"attr9": "",
"id": "96720790-37B2-4E3D-B7BE-E116EE3730AC",
"baseType": "D57B7F8D-4728-43D3-9F21-A1953D885CFB"
}
],
"correlations": [],
"indexes": [],
"type": "P"
},
{
"id": "FA9176BA-E472-4ECF-B927-6C86E2F932C4",
"env": {
@ -10740,7 +11237,7 @@
"baseType": "9B6B9E10-DB11-4409-878B-5868A19CD9B0"
},
{
"defKey": "goods_id",
"defKey": "origin_goods_id",
"defName": "产品 Id",
"comment": "",
"type": "BIGINT",
@ -11448,23 +11945,6 @@
"attr9": "",
"id": "BD138B10-3292-44D8-92C9-C74463AAD81B",
"baseType": "A098BA98-4957-43EE-9F06-1CDC26D370E0"
},
{
"defKey": "check_photo",
"defName": "看料照片",
"comment": "多张",
"type": "TEXT",
"len": "",
"scale": "",
"primaryKey": false,
"notNull": false,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"baseType": "B1BC2E92-6A75-44C0-A254-76E066047F53",
"extProps": {},
"id": "8CE891EF-471D-462E-8F42-7574BA3CE630"
}
],
"correlations": [],
@ -13655,6 +14135,40 @@
"extProps": {},
"id": "451F8275-02A4-4133-A828-CE2F3FDAD267"
},
{
"defKey": "contacts",
"defName": "联系人",
"comment": "",
"type": "VARCHAR",
"len": 255,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231",
"extProps": {},
"id": "DEAAF23C-C69D-46D5-97C2-7B40454BEACC"
},
{
"defKey": "phone",
"defName": "联系电话",
"comment": "",
"type": "VARCHAR",
"len": 20,
"scale": "",
"primaryKey": false,
"notNull": true,
"autoIncrement": false,
"defaultValue": "",
"hideInGraph": false,
"refDict": "",
"baseType": "AA07828C-4FCB-4EDA-9B51-53A3F264F231",
"extProps": {},
"id": "D76BA1D7-C780-497D-9FB0-0F4F1CDAB126"
},
{
"defKey": "creator_id",
"defName": "创建人 Id",

View File

@ -1,46 +1,34 @@
### 注册
POST http://localhost:10086/sys_user/register
POST http://localhost:10086/user/register
Content-Type: application/json
{
"gender": "",
"bizObj": "GeRen",
"nickname": "小刘",
"avatar": "https://example.com/avatar.jpg",
"gender": "Man",
"nickname": "13115042121",
"account": {
"email": "",
"phone": "",
"username": "gr",
"secret": "gr"
"phone": "2",
"username": "2",
"secret": "",
"code": "00000",
"codeId": "00000"
},
"company": {
"companyName": "消纳场",
"businessLicense": "https://example.com/license.jpg",
"certification": "https://example.com/cert.jpg",
"businessLicenseDate": [
"2025-01-01",
"2026-01-01"
],
"certificationDate": [
"2025-01-01",
"2026-01-01"
],
"legalRepresentative": "小王",
"province": "北京市",
"city": "北京市",
"county": "朝阳区",
"companyName": "",
"businessLicense": "",
"certification": "",
"businessLicenseDate": [],
"certificationDate": [],
"legalRepresentative": "",
"province": "",
"city": "",
"county": "",
"street": "",
"address": "朝阳区建国路88号",
"contacts": "小王",
"phoneNum": "13900139000",
"scopeList": [
{
"province": "北京市",
"city": "北京市",
"county": "朝阳区",
"street": ""
}
]
"address": "",
"contacts": "",
"phoneNum": "",
"scopeList": []
}
}
@ -56,3 +44,10 @@ Content-Type: application/json
### 获取验证码
GET http://localhost:10086/auth/obtain_code?phone=11111111111
### 获取用户信息
GET http://localhost:10086/auth/my
Authorization: MTk2NjQ1NzUwNDMwNTA2NTk4NSwxOTY2NDU3NTA0Mzc2MzY5MTUzLGQwZDgyOTJlYzJkYzRlMzNiMDAyNjcwZTBiZWI1OTlhLDE3NTc2NzQ5Nzg3MzgsMCxQSE9ORQ==
### 获取用户信息
GET http://localhost:10086/auth/obtain_code?phone=131415042121