This commit is contained in:
Lihx 2024-09-19 17:57:05 +08:00
parent 221eb5c7ae
commit 2d97d8f21d
29 changed files with 310 additions and 52 deletions

View File

@ -39,7 +39,7 @@ public class InspectionFileController extends BaseController
*/
@GetMapping("/list")
public TableDataInfo list(InspectionFile inspectionFile) throws Exception {
ShopMallPartners partners = partnerService.shopInfo();
ShopMallPartners partners = partnerService.shopInfoByUserId();
inspectionFile.setPartnerId(partners.getPartnerId());
startPage();
List<InspectionFile> list = inspectionFileService.selectInspectionFileList(inspectionFile);

View File

@ -129,8 +129,9 @@ public class InspectionMallPartnersController extends BaseController {
}
partner.setPartnerId(worker.getPartnerId());
}
Page<InspectionInfo> page = new Page<>(pageNum,pageSize);
List<InspectionInfo> list = orderInfoService.workOrder(page,partner.getPartnerId(),carNum,goodsTitle, customerSource, payType,startTime,roleId,endTime);
// Page<InspectionInfo> page = new Page<>(pageNum,pageSize);
PageHelper.startPage(pageNum,pageSize);
List<InspectionInfo> list = orderInfoService.workOrder(partner.getPartnerId(),carNum,goodsTitle, customerSource, payType,startTime,roleId,endTime);
return getDataTable(list);
}
@ -168,8 +169,9 @@ public class InspectionMallPartnersController extends BaseController {
}
partner.setPartnerId(worker.getPartnerId());
}
Page<InspectionInfo> page = new Page<>(pageNum,pageSize);
List<InspectionInfo> list = orderInfoService.delworkOrder(page,partner.getPartnerId(),carNum,goodsTitle, customerSource, payType,startTime,roleId,endTime);
// Page<InspectionInfo> page = new Page<>(pageNum,pageSize);
PageHelper.startPage(pageNum,pageSize);
List<InspectionInfo> list = orderInfoService.delworkOrder(partner.getPartnerId(),carNum,goodsTitle, customerSource, payType,startTime,roleId,endTime);
return getDataTable(list);
}
@ -200,7 +202,7 @@ public class InspectionMallPartnersController extends BaseController {
int pageNum = Convert.toInt(ServletUtils.getParameter("pageNum"), 1);
int pageSize = Convert.toInt(ServletUtils.getParameter("pageSize"), 10);
Page<InspectionInfo> page = new Page<>(pageNum,pageSize);
List<InspectionInfo> list = orderInfoService.workOrder(page,partner.getPartnerId(),carNum,goodsTitle, customerSource, payType,startTime,roleId,endTime);
List<InspectionInfo> list = orderInfoService.workOrder(partner.getPartnerId(),carNum,goodsTitle, customerSource, payType,startTime,roleId,endTime);
List<List<String>> rows =new ArrayList<>();
Map<String, Object> stringObjectMap = orderInfoService.workOrderData(partner.getPartnerId(), carNum, goodsTitle, customerSource, payType, startTime, roleId, endTime);

View File

@ -56,6 +56,11 @@ public class PartnerOwnController extends BaseController {
return success(partnerList.shopInfo());
}
@GetMapping("/shopInfoByUserId")
public CommonResult shopInfoByUserId() throws Exception {
return success(partnerList.shopInfoByUserId());
}
/**
* 获取上门取车 预约条数
*/
@ -324,8 +329,9 @@ public class PartnerOwnController extends BaseController {
if (!partnersTmp.getUserId().equals(user.getId())){
return null;
}
Page<PartnerWorker> page = new Page<>(pageNum, pageSize);
List<PartnerWorker> workList = partnerList.getWorkList(page,partnerId,postId, workName, phoneNum);
// Page<PartnerWorker> page = new Page<>(pageNum, pageSize);
PageHelper.startPage(pageNum,pageSize);
List<PartnerWorker> workList = partnerList.getWorkList(partnerId,postId, workName, phoneNum);
return getDataTable(workList);
}
@ -485,7 +491,7 @@ public class PartnerOwnController extends BaseController {
//获取客户来源
@GetMapping("/getCustomerSource")
public CommonResult getCustomerSource(String searchValue) throws Exception {
ShopMallPartners partners = partnerList.shopInfo();
ShopMallPartners partners = partnerList.shopInfoByUserId();
String dictStr = "customer_source-"+partners.getPartnerId();
DictTypeDO sysDictType = dictTypeService.getDictType(dictStr);
if (ObjectUtil.isEmpty(sysDictType)){
@ -551,7 +557,7 @@ public class PartnerOwnController extends BaseController {
//获取收款账号
@GetMapping("/getBankAccountList")
public CommonResult getBankAccountList(String searchValue) throws Exception {
ShopMallPartners partners = partnerList.shopInfo();
ShopMallPartners partners = partnerList.shopInfoByUserId();
String dictStr = "partner_bankList-"+partners.getPartnerId();
DictTypeDO sysDictType = dictTypeService.getDictType(dictStr);
if (ObjectUtil.isEmpty(sysDictType)){

View File

@ -22,6 +22,7 @@ import cn.iocoder.yudao.module.partner.entity.PartnerWorker;
import cn.iocoder.yudao.module.payment.entity.OrderInfo;
import cn.iocoder.yudao.module.shop.entity.ShopMallPartners;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.pagehelper.IPage;
import com.github.pagehelper.PageHelper;
import org.apache.commons.lang3.ObjectUtils;
import org.springframework.context.annotation.Lazy;
@ -74,7 +75,7 @@ public class ShopInspectionGoodsController extends BaseController
*/
@GetMapping("/listPartnerGoods")
public TableDataInfo listPartnerGoods(ShopInspectionGoods shopInspectionGoods) throws Exception {
ShopMallPartners one = appInspectionPartnerService.shopInfo();
ShopMallPartners one = appInspectionPartnerService.shopInfoByUserId();
shopInspectionGoods.setPartnerId(one.getPartnerId().intValue());
startPage();
List<ShopInspectionGoods> list = shopInspectionGoodsService.listPartnerGoods(shopInspectionGoods);
@ -206,8 +207,9 @@ public class ShopInspectionGoodsController extends BaseController
shopInspectionOrder.setValidationTime(new Date());
int pageNum = Convert.toInt(ServletUtils.getParameter("pageNum"), 1);
int pageSize = Convert.toInt(ServletUtils.getParameter("pageSize"), 10);
Page<OrderInfo> page = new Page<>(pageNum,pageSize);
List<OrderInfo> list = orderInfoService.orderListSystem(page,shopInspectionOrder);
// Page<OrderInfo> page = new Page<>(pageNum,pageSize);
startPage();
List<OrderInfo> list = orderInfoService.orderListSystem(shopInspectionOrder);
return getDataTable(list);
}

View File

@ -5,8 +5,11 @@ import javax.servlet.http.HttpServletResponse;
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
import cn.iocoder.yudao.framework.tenant.core.aop.TenantIgnore;
import cn.iocoder.yudao.module.inspection.entity.NweUsers;
import cn.iocoder.yudao.util.ExcelUtil;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.beans.BeanUtils;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@ -92,4 +95,30 @@ public class SiteInfoController extends BaseController
{
return toAjax(siteInfoService.deleteSiteInfoByIds(ids));
}
/**
* 迁移数据库查询老表数据并且将数据插入到新表中
*/
@GetMapping("/transferDB")
public CommonResult transferDB(){
int sum = 0;
// 获取老数据表的信息类型为JSONObject
List<JSONObject> jsonObjects = siteInfoService.transferDB();
// 遍历从数据库获取的 JSON 对象列表
for (JSONObject userObject : jsonObjects) {
// JSON 对象转换为 NweUsers 实例
NweUsers user = userObject.toJavaObject(NweUsers.class);
// 使用 BeanUtils JSON 对象的属性复制到 NweUsers 实例中
BeanUtils.copyProperties(userObject,user);
// NweUsers 实例插入到数据库中并获取插入操作的结果
sum += siteInfoService.addNewDB(user);
}
return success(sum);
}
}

View File

@ -0,0 +1,82 @@
package cn.iocoder.yudao.module.inspection.entity;
import lombok.Data;
/**
* 迁移数据使用的新数据库User表
*/
@Data
public class NweUsers {
/** 主键 */
private Long Id;
/** 用户名 */
private String username;
/** 密码 */
private String password;
/** 部门编号 */
private Long deptId;
/** 用户昵称 */
private String nickName;
/** 用户类型数据字典system_user_type */
private String userType;
/** 邮箱 */
private String email;
/** 手机号 */
private String mobile;
/** 性别 */
private Integer sex;
/** 头像地址 */
private String avatar;
/** 帐号状态0正常 1停用 */
private Integer status;
/** 最后登陆ip */
private String loginIp;
/** 最后登录时间 */
private String loginDate;
/** 创建者 */
private String creator;
/** 创建时间 */
private String createTime;
/** 更新者 */
private String updater;
/** 微信open_id */
private String openId;
/** 检测小程序open_id */
private String jcOpenId;
/** 救援小程序open_id */
private String rescueOpenId;
/** 微信union_id */
private String unionId;
/** 身份证 */
private String idCard;
/** 身份证照片 */
private String idCardImage;
/** 用户年龄 */
private Integer userAge;
/** 邀请者ID */
private Integer inviteId;
}

View File

@ -32,7 +32,7 @@ public interface AppInspectionPartnerMapper extends BaseMapper<ShopMallPartners>
List<HotGoodsVo> hotGoodsList(@Param("partnerId") Long partnerId,@Param("dateStr")String dateStr);
List<GoodsVo> manageGoodsList(@Param("partnerId") Long partnerId, @Param("isListing")String isListing,@Param("goodsTitle") String goodsTitle);
List<OrderAppDetail> orderList(@Param("partnerId") Long partnerId, @Param("phoneNum") String phoneNum,@Param("title") String title);
List<PartnerWorker> getWorkList(Page<PartnerWorker> page,@Param("partnerId")Long partnerId, @Param("postId") Long postId, @Param("workName") String workName, @Param("phoneNum")String phoneNum);
List<PartnerWorker> getWorkList(@Param("partnerId")Long partnerId, @Param("postId") Long postId, @Param("workName") String workName, @Param("phoneNum")String phoneNum);
List<InspectionInfo> inspectionList(Page<InspectionInfo> page,@Param("partnerId")Long partnerId, @Param("status") String status, @Param("carNum")String carNum);
List<InspectionInfo> workerInspectionList(@Param("workerId")Long workerId,@Param("status") String status, @Param("searchValue")String searchValue);
List<OrderInfo> validationList(@Param("partnerId") Long partnerId, @Param("searchValue") String searchValue);

View File

@ -66,11 +66,11 @@ public interface InspectionInfoMapper extends BaseMapper<InspectionInfo>
* @return 结果
*/
public int deleteInspectionInfoByIds(Long[] ids);
List<InspectionInfo> workOrder(Page<InspectionInfo> page,@Param("partnerId") Long partnerId, @Param("carNum")String carNum, @Param("goodsTitle")String goodsTitle
List<InspectionInfo> workOrder(@Param("partnerId") Long partnerId, @Param("carNum")String carNum, @Param("goodsTitle")String goodsTitle
, @Param("customerSource")String customerSource, @Param("payType")String payType, @Param("startTime")String startTime
, @Param("roleId") Long roleId, @Param("endTime")String endTime);
List<InspectionInfo> delworkOrder(Page<InspectionInfo> page,@Param("partnerId") Long partnerId, @Param("carNum")String carNum, @Param("goodsTitle")String goodsTitle
List<InspectionInfo> delworkOrder(@Param("partnerId") Long partnerId, @Param("carNum")String carNum, @Param("goodsTitle")String goodsTitle
,@Param("customerSource")String customerSource,@Param("payType")String payType,@Param("startTime")String startTime
,@Param("roleId") Long roleId,@Param("endTime")String endTime);

View File

@ -1,7 +1,10 @@
package cn.iocoder.yudao.module.inspection.mapper;
import java.util.List;
import cn.iocoder.yudao.module.inspection.entity.NweUsers;
import cn.iocoder.yudao.module.inspection.entity.SiteInfo;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@ -62,4 +65,19 @@ public interface SiteInfoMapper
* @return 结果
*/
public int deleteSiteInfoByIds(Long[] ids);
/**
* 迁移数据库查询老表数据
*
* @return JSONObject集合
*/
public List<JSONObject> selectAll();
/**
* 迁移数据库向新表中插入数据
*
* @return 返回影响行数
*/
public int addAll(NweUsers user);
}

View File

@ -23,6 +23,13 @@ public interface AppInspectionPartnerService extends IService<ShopMallPartners>
PartnerListVo shopDetail(PartnerListQuery partnerListQuery);
void addSalesNum(Long partnerId);
ShopMallPartners shopInfo() throws Exception;
/**
* 重写shopInfo()方法
*
*/
ShopMallPartners shopInfoByUserId() throws Exception;
JSONObject getAppointAndPickNum() throws Exception;
void startOrEnd(Long partnerId);
@ -53,7 +60,7 @@ public interface AppInspectionPartnerService extends IService<ShopMallPartners>
Long orderDetailByCode(Long partnerId,String code) throws Exception;
void takeOut(Long partnerId,Long orderId,Long workId,String carNum) throws Exception;
void addWorker(Long partnerId,String realName,String phoneNum,Long postId) throws Exception;
List<PartnerWorker> getWorkList(Page<PartnerWorker> page,Long partnerId, Long postId, String workName, String phoneNum);
List<PartnerWorker> getWorkList(Long partnerId, Long postId, String workName, String phoneNum);
void delWorker(Long partnerId,Long workId);

View File

@ -62,8 +62,8 @@ public interface IInspectionInfoService extends IService<InspectionInfo>
* @return 结果
*/
public int deleteInspectionInfoById(Long id);
List<InspectionInfo> workOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime);
List<InspectionInfo> delworkOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime);
List<InspectionInfo> workOrder(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime);
List<InspectionInfo> delworkOrder(Long partnerId, String carNum, String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime);
Map<String,Object> workOrderData(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime);

View File

@ -1,7 +1,10 @@
package cn.iocoder.yudao.module.inspection.service;
import java.util.List;
import cn.iocoder.yudao.module.inspection.entity.NweUsers;
import cn.iocoder.yudao.module.inspection.entity.SiteInfo;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
/**
@ -59,4 +62,20 @@ public interface ISiteInfoService
* @return 结果
*/
public int deleteSiteInfoById(Long id);
/**
* 迁移数据表查询老表数据
*
* @return JSONObject对象集合
*/
public List<JSONObject> transferDB();
/**
* 迁移数据表向新表中插入数据
*
* @return 影响行数
*/
public int addNewDB(NweUsers user);
}

View File

@ -38,6 +38,7 @@ import cn.iocoder.yudao.util.SendSmsUtil;
import cn.iocoder.yudao.util.VehicleLicenseOCR;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.PageHelper;
@ -186,6 +187,25 @@ public class AppInspectionPartnerServiceImpl extends ServiceImpl<AppInspectionPa
return partner;
}
/**
* 对shopInfo方法的重写只根据user_id进行查询
*
*/
@Override
public ShopMallPartners shopInfoByUserId() throws Exception {
LoginUser user = SecurityFrameworkUtils.getLoginUser();
ShopMallPartners partner = new ShopMallPartners();
LambdaQueryWrapper<ShopMallPartners> queryWrapper = new LambdaQueryWrapper<>();
queryWrapper.eq(ShopMallPartners::getUserId, user.getId());
partner = this.getOne(queryWrapper);
if (ObjectUtil.isEmpty(partner)){
throw new Exception("未查询到信息");
}
return partner;
}
@Override
public JSONObject getAppointAndPickNum() throws Exception {
ShopMallPartners shopMallPartners = this.shopInfo();
@ -1058,8 +1078,8 @@ public class AppInspectionPartnerServiceImpl extends ServiceImpl<AppInspectionPa
}
@Override
public List<PartnerWorker> getWorkList(Page<PartnerWorker> page,Long partnerId,Long postId,String workName,String phoneNum) {
return baseMapper.getWorkList(page,partnerId,postId,workName,phoneNum);
public List<PartnerWorker> getWorkList(Long partnerId,Long postId,String workName,String phoneNum) {
return baseMapper.getWorkList(partnerId,postId,workName,phoneNum);
}
@Override

View File

@ -297,13 +297,13 @@ public class InspectionInfoServiceImpl extends ServiceImpl<InspectionInfoMapper,
return baseMapper.deleteInspectionInfoById(id);
}
@Override
public List<InspectionInfo> workOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime){
return baseMapper.workOrder(page,partnerId,carNum,goodsTitle, customerSource, payType, startTime,roleId,endTime);
public List<InspectionInfo> workOrder(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime){
return baseMapper.workOrder(partnerId,carNum,goodsTitle, customerSource, payType, startTime,roleId,endTime);
}
@Override
public List<InspectionInfo> delworkOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime){
return baseMapper.delworkOrder(page,partnerId,carNum,goodsTitle, customerSource, payType, startTime,roleId,endTime);
public List<InspectionInfo> delworkOrder(Long partnerId, String carNum, String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime){
return baseMapper.delworkOrder(partnerId,carNum,goodsTitle, customerSource, payType, startTime,roleId,endTime);
}
@Override

View File

@ -243,7 +243,7 @@ public class ShopInspectionGoodsServiceImpl extends ServiceImpl<ShopInspectionGo
@Override
public List<ShopInspectionCategory> categoryList() throws Exception {
ShopMallPartners one = appInspectionPartnerService.shopInfo();
ShopMallPartners one = appInspectionPartnerService.shopInfoByUserId();
List<ShopInspectionCategory> shopInspectionCategories = appInspectionPartnerService.categoryList(one.getPartnerId());
for (ShopInspectionCategory shopInspectionCategory : shopInspectionCategories) {
LambdaQueryWrapper<InspectionCategoryTemplate> templateLambdaQueryWrapper =new LambdaQueryWrapper<>();

View File

@ -1,8 +1,10 @@
package cn.iocoder.yudao.module.inspection.service.impl;
import java.util.List;
import cn.iocoder.yudao.module.inspection.entity.NweUsers;
import cn.iocoder.yudao.util.DateUtils;
import cn.iocoder.yudao.util.StringUtils;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@ -101,4 +103,26 @@ public class SiteInfoServiceImpl implements ISiteInfoService
{
return siteInfoMapper.deleteSiteInfoById(id);
}
/**
* 迁移数据表查询老表数据
*
* @return JSONObject对象集合
*/
@Override
public List<JSONObject> transferDB() {
return siteInfoMapper.selectAll();
}
/**
* 迁移数据库向新表中插入数据
*
* @return 影响行数
*/
@Override
public int addNewDB(NweUsers user) {
return siteInfoMapper.addAll(user);
}
}

View File

@ -40,8 +40,9 @@ public class PartnerCustomerInfoController extends BaseController
partnerCustomerInfo.setPartnerId(partners.getPartnerId());
int pageNum = Convert.toInt(ServletUtils.getParameter("pageNum"), 1);
int pageSize = Convert.toInt(ServletUtils.getParameter("pageSize"), 10);
Page<PartnerCustomerInfo> page = new Page<>(pageNum,pageSize);
List<PartnerCustomerInfo> list = partnerCustomerInfoService.selectPartnerCustomerInfoList(page,partnerCustomerInfo);
// Page<PartnerCustomerInfo> page = new Page<>(pageNum,pageSize);
startPage();
List<PartnerCustomerInfo> list = partnerCustomerInfoService.selectPartnerCustomerInfoList(partnerCustomerInfo);
return getDataTable(list);
}
@ -53,7 +54,7 @@ public class PartnerCustomerInfoController extends BaseController
public void export(HttpServletResponse response, PartnerCustomerInfo partnerCustomerInfo)
{
Page<PartnerCustomerInfo> page = new Page<>();
List<PartnerCustomerInfo> list = partnerCustomerInfoService.selectPartnerCustomerInfoList(page,partnerCustomerInfo);
List<PartnerCustomerInfo> list = partnerCustomerInfoService.selectPartnerCustomerInfoList(partnerCustomerInfo);
ExcelUtil<PartnerCustomerInfo> util = new ExcelUtil<PartnerCustomerInfo>(PartnerCustomerInfo.class);
util.exportExcel(response, list, "客户信息数据");
}

View File

@ -24,7 +24,7 @@ public interface PartnerCustomerInfoMapper extends BaseMapper<PartnerCustomerInf
* @param partnerCustomerInfo 客户信息
* @return 客户信息集合
*/
public List<PartnerCustomerInfo> selectPartnerCustomerInfoList(Page<PartnerCustomerInfo> page ,@Param("vo") PartnerCustomerInfo partnerCustomerInfo);
public List<PartnerCustomerInfo> selectPartnerCustomerInfoList(@Param("vo") PartnerCustomerInfo partnerCustomerInfo);
/**
* 查询客户信息

View File

@ -20,7 +20,7 @@ public interface IPartnerCustomerInfoService extends IService<PartnerCustomerInf
* @param partnerCustomerInfo 客户信息
* @return 客户信息集合
*/
public List<PartnerCustomerInfo> selectPartnerCustomerInfoList(Page<PartnerCustomerInfo> page ,PartnerCustomerInfo partnerCustomerInfo);
public List<PartnerCustomerInfo> selectPartnerCustomerInfoList(PartnerCustomerInfo partnerCustomerInfo);
/**
* 查询客户信息

View File

@ -57,9 +57,9 @@ public class PartnerCustomerInfoServiceImpl extends ServiceImpl<PartnerCustomerI
* @return 客户信息
*/
@Override
public List<PartnerCustomerInfo> selectPartnerCustomerInfoList(Page<PartnerCustomerInfo> page ,PartnerCustomerInfo partnerCustomerInfo)
public List<PartnerCustomerInfo> selectPartnerCustomerInfoList(PartnerCustomerInfo partnerCustomerInfo)
{
List<PartnerCustomerInfo> partnerCustomerInfos = baseMapper.selectPartnerCustomerInfoList(page,partnerCustomerInfo);
List<PartnerCustomerInfo> partnerCustomerInfos = baseMapper.selectPartnerCustomerInfoList(partnerCustomerInfo);
for (PartnerCustomerInfo customerInfo : partnerCustomerInfos) {
List<ShopUserCar> list = userCarService.selectUserCarsByUserId(customerInfo.getUserId());
if (CollectionUtil.isNotEmpty(list)){

View File

@ -123,8 +123,8 @@ public class OrderController extends BaseController {
public TableDataInfo orderListSystem(OrderInfo shopInspectionOrder) {
int pageNum = Convert.toInt(ServletUtils.getParameter("pageNum"), 1);
int pageSize = Convert.toInt(ServletUtils.getParameter("pageSize"), 10);
Page<OrderInfo> page = new Page<>(pageNum,pageSize);
List<OrderInfo> list = orderInfoService.orderListSystem(page,shopInspectionOrder);
startPage();
List<OrderInfo> list = orderInfoService.orderListSystem(shopInspectionOrder);
return getDataTable(list);
}

View File

@ -29,7 +29,7 @@ public interface OrderInfoMapper extends BaseMapper<OrderInfo> {
List<InspectionInfo> inspectionList(@Param("status") String status, @Param("userId")Long userId);
List<OrderInfo> orderListSystem(Page<OrderInfo> page,@Param("vo") OrderInfo orderInfo);
List<OrderInfo> orderListSystem(@Param("vo") OrderInfo orderInfo);
List<JSONObject> statisticsZXTMonth(@Param("partnerId") Long partnerId,@Param("startTime")String startTime,@Param("endTime")String endTime);

View File

@ -20,10 +20,10 @@ import java.util.Map;
public interface OrderInfoService extends IService<OrderInfo> {
void reviewOrder(String orderId,Integer starLevel,String reviewStr) throws Exception;
List<OrderInfo> orderListApp(String status, String title, String type);
List<InspectionInfo> workOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime);
List<InspectionInfo> workOrder(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime);
Map<String,Object> workOrderData(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime);
List<InspectionInfo> delworkOrder(Page<InspectionInfo> page,Long partnerId,String carNum,String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime);
List<OrderInfo> orderListSystem(Page<OrderInfo> page,OrderInfo orderInfo);
List<InspectionInfo> delworkOrder(Long partnerId,String carNum,String goodsTitle,String customerSource,String payType,String startTime,Long roleId,String endTime);
List<OrderInfo> orderListSystem(OrderInfo orderInfo);
Long createOrder(OrderInfo orderInfo) throws Exception;
JSONObject pickCarDetail(Long pickCarId);

View File

@ -106,14 +106,14 @@ public class OrderInfoServiceImpl extends ServiceImpl<OrderInfoMapper, OrderInfo
}
@Override
public List<InspectionInfo> workOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime) {
public List<InspectionInfo> workOrder(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime) {
if (StringUtils.isNotEmpty(startTime)){
startTime = startTime+" 00:00:00";
}
if (StringUtils.isNotEmpty(endTime)){
endTime = endTime+" 23:59:59";
}
return iInspectionInfoService.workOrder(page,partnerId,carNum,goodsTitle, customerSource, payType, startTime, roleId,endTime);
return iInspectionInfoService.workOrder(partnerId,carNum,goodsTitle, customerSource, payType, startTime, roleId,endTime);
}
@Override
@ -128,19 +128,19 @@ public class OrderInfoServiceImpl extends ServiceImpl<OrderInfoMapper, OrderInfo
}
@Override
public List<InspectionInfo> delworkOrder(Page<InspectionInfo> page,Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime) {
public List<InspectionInfo> delworkOrder(Long partnerId, String carNum, String goodsTitle, String customerSource, String payType, String startTime, Long roleId, String endTime) {
if (StringUtils.isNotEmpty(startTime)){
startTime = startTime+" 00:00:00";
}
if (StringUtils.isNotEmpty(endTime)){
endTime = endTime+" 23:59:59";
}
return iInspectionInfoService.delworkOrder(page,partnerId,carNum,goodsTitle, customerSource, payType, startTime, roleId,endTime);
return iInspectionInfoService.delworkOrder(partnerId,carNum,goodsTitle, customerSource, payType, startTime, roleId,endTime);
}
@Override
public List<OrderInfo> orderListSystem(Page<OrderInfo> page,OrderInfo orderInfo) {
return baseMapper.orderListSystem(page,orderInfo);
public List<OrderInfo> orderListSystem(OrderInfo orderInfo) {
return baseMapper.orderListSystem(orderInfo);
}
@Override

View File

@ -15,9 +15,9 @@ import lombok.Data;
@Data
public class ShopMallPartners extends TenantBaseDO {
//合作商id
@TableId(type = IdType.AUTO)
private Long partnerId;
//用户id
@TableId(type = IdType.AUTO)
private Long userId;
//类型:检测jc\汽修qx\会员商城sc....如果多种则以逗号分隔
private String type;

View File

@ -128,7 +128,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join order_info oi on oi.id = ins.inspection_order_id
left join system_users su on su.id = ins.user_id
left join system_user_role sur on sur.user_id = su.id
where 1=1 and ins.partner_id = #{partnerId}
where 1=1
<if test="carNum!=null and carNum!=''">
and ins.car_num like concat('%',#{carNum},'%')
</if>
@ -158,7 +158,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join del_order_info oi on oi.id = ins.inspection_order_id
left join system_users su on su.id = ins.user_id
left join system_user_role sur on sur.user_id = su.id
where 1=1 and ins.partner_id = #{partnerId}
where 1=1
<if test="carNum!=null and carNum!=''">
and ins.car_num like concat('%',#{carNum},'%')
</if>
@ -187,7 +187,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join order_info oi on oi.id = ins.inspection_order_id
left join system_users su on su.id = ins.user_id
left join system_user_role sur on sur.user_id = su.id
where 1=1 and ins.partner_id = #{partnerId}
where 1=1
<if test="carNum!=null and carNum!=''">
and ins.car_num like concat('%',#{carNum},'%')
</if>

View File

@ -51,7 +51,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
INNER JOIN shop_mall_partners smp ON smp.partner_id = sig.partner_id AND smp.is_banned = '0'
INNER JOIN shop_inspection_category sic ON sic.id = sig.goods_category_id
<where>
smp.partner_id= #{partnerId}
<if test="id != null "> and sig.id = #{id}</if>
<if test="title != null and title != ''"> and sig.title like concat('%', #{title}, '%')</if>
<if test="goodsCategoryId!= null "> and sig.goods_category_id = #{goodsCategoryId}</if>

View File

@ -105,4 +105,53 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
#{id}
</foreach>
</delete>
<select id="selectAll" resultType="com.alibaba.fastjson.JSONObject" parameterType="int">
select
user_id as id,
user_name as username,
password,
dept_id as deptId,
nick_name as nickName,
user_type as userType,
email,
phonenumber as mobile,
sex,
avatar,
status,
login_ip as loginIp,
login_date as loginDate,
create_by as creator,
create_time as createTime,
update_by as updater,
update_time as updateTime,
open_id as openId,
jc_open_id as jcOpenId,
rescue_open_id as rescueOpenId,
union_id as unionId,
id_card as idCard,
id_card_image as idCardImage,
user_age as userAge,
invite_id as inviteId
FROM sys_user
</select>
<insert id="addAll" parameterType="cn.iocoder.yudao.module.inspection.entity.NweUsers">
INSERT INTO system_users
(id,username,password,dept_id,nickname,
user_type,email,mobile,sex,
avatar,status,login_ip,login_date,
creator,create_time,updater,
open_id,jc_open_id,rescue_open_id,union_id,
id_card,id_card_image,user_age,invite_id)
VALUES(#{id},#{username},#{password},#{deptId},#{nickName},#{userType},
#{email},#{mobile},#{sex},#{avatar},#{status},#{loginIp},#{loginDate},
#{creator},#{createTime},#{updater},#{openId},#{jcOpenId},
#{rescueOpenId},#{unionId},#{idCard},#{idCardImage},#{userAge},#{inviteId})
</insert>
</mapper>

View File

@ -30,7 +30,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
left join system_user_role sur on sur.user_id = su.id
left join system_role sr on sr.id = sur.role_id
<where>
and pci.partner_id = #{vo.partnerId}
<if test="vo.carNum != null and vo.carNum != ''"> and suc.car_no like concat('%', #{vo.carNum}, '%')</if>
<if test="vo.customerName != null and vo.customerName != ''"> and pci.customer_name like concat('%', #{vo.customerName}, '%')</if>
<if test="vo.customerPhone != null and vo.customerPhone != ''"> and pci.customer_phone like concat('%', #{vo.customerPhone}, '%')</if>