Merge remote-tracking branch 'origin/cc_partner_init' into cc_partner_init

This commit is contained in:
zhangchenbiao
2024-04-29 17:08:12 +08:00
57 changed files with 2339 additions and 408 deletions

View File

@@ -155,4 +155,6 @@ public class CommonConstants {
public static final String DEAULT_SELECT_SITE_MANAGER = "020125244825417786";
public static final int MAX_LENGTH_ONE_HUNDRED = 100;
public static final String YUN_XUE_TANG_SUC_CODE = "10000";
}

View File

@@ -273,4 +273,8 @@ public class RedisConstant {
*/
public static final String INVESTMENT_MANAGER_CACHE = "investment_manager_cache_";
/**
* 招商经理轮询key
*/
public static final String YUN_XUE_TANG_ACCESS_TOKEN = "yun_xue_tang_access_token_";
}

View File

@@ -8,6 +8,7 @@ public enum AuditTypeEnum {
SYS_BUILD(4, "系统建店"),
SITE_SELECTION(5, "选址"),
UPLOAD_RENT_CONTRACT(6, "上传租赁合同"),
PAY_FRANCHISE_FEE(7,"缴纳加盟费"),
;
private Integer code;

View File

@@ -7,6 +7,7 @@ package com.cool.store.enums;
* @注释:
*/
public enum ConstructionPhaseEnum {
//施工阶段
NOT_SHOWN(-1,"不显示"),
NOT_START(0,"未开工"),
construction_ING(1,"施工中"),

View File

@@ -13,7 +13,7 @@ public enum DesignPhaseEnum {
ACCEPTANCE_NOT_START(1, "未开始"),
ACCEPTANCE_DESIGNING(2, "设计中"),
ACCEPTED_NOT(3, "未验收"),
ACCEPTANCE_FAILEDS(0,"验收未通过"),
AUDIT_WAIT(5,"待审批"),
AUDIT_FAIL(6,"审批驳回"),
AUDIT_ING(7,"审批中"),

View File

@@ -41,6 +41,7 @@ public enum ErrorCodeEnum {
USER_FREEZE(1021019,"账号被冻结,请联系管理员",null),
ENTERPRISE_NOT_EXIST(1021020,"企业不存在",null),
USER_NOT_EXIST(1021021,"用户不存在",null),
JOBNUMBER_NOT_EXIST(1021017,"用户工号不存在",null),
USER_WAIT_AUDIT(1021018,"账号审核中,请联系企业管理员",null),
OPERATION_OVER_TIME(1021019, "您的操作过于频繁,休息一下~", null),
GET_APP_SECRET_ERROR(1021020, "获取secret异常", null),

View File

@@ -0,0 +1,50 @@
package com.cool.store.enums;
/**
* 加盟商类型" +
* "0-新加盟商开单店;1-老加盟商开单店;" +
* "2-新加盟商开新区域单店;" +
* "3-新加盟商开老区域单店;" +
* "4-老加盟商开新区域单店;" +
* "5-老加盟商开老区域单店;" +
* "6-直营门店;" +
* "7-同异业转化;" +
* "8-老加盟商迁址开新店
*/
public enum FranchiseeTypeEnum {
ONE(0,"新加盟商开单店"),
TWO(1,"老加盟商开单店"),
THREE(2,"新加盟商开新区域单店"),
FOUR(4,"新加盟商开老区域单店"),
FIVE(5,"老加盟商开老区域单店"),
SIX(6,"直营门店"),
SEVEN(7,"同异业转化"),
EIGHT(8,"老加盟商迁址开新店"),
;
private Integer code;
private String message;
FranchiseeTypeEnum(Integer code, String message) {
this.code = code;
this.message = message;
}
public Integer getCode() {
return code;
}
public String getMessage() {
return message;
}
public static FranchiseeTypeEnum getByCode(Integer code) {
for (FranchiseeTypeEnum franchiseeTypeEnum : FranchiseeTypeEnum.values()) {
if (franchiseeTypeEnum.getCode().equals(code)) {
return franchiseeTypeEnum;
}
}
return null;
}
}

View File

@@ -24,7 +24,7 @@ public enum WorkflowSubStageStatusEnum {
FIRST_INTERVIEWS_40(40,"一审未通过"),
FIRST_INTERVIEWS_42(42,"一审重新预约"),
//缴纳意向金
//缴纳意向金,装修款
PAY_DEPOSIT_45(45,"待缴费"),
PAY_DEPOSIT_50(50,"已缴费"),
PAY_FAIL_55(55,"缴费失败"),
@@ -51,6 +51,7 @@ public enum WorkflowSubStageStatusEnum {
SECOND_INTERVIEWS_115(115,"二审未通过"),
SECOND_INTERVIEWS_120(120,"二审重新预约"),
SECOND_INTERVIEWS_125(125,"二审通过"),
;
private Integer code;

View File

@@ -0,0 +1,31 @@
package com.cool.store.enums.point;
/**
* @Auther: WangShuo
* @Date: 2024/04/29/上午9:33
* @Version 1.0
* @注释:
*/
public enum PayBusinessTypeEnum {
INTENT_MONEY(0,"缴纳意向金"),
FRANCHISE_FEE(1,"缴纳加盟费"),
DECORATION_MODEL(2,"装修款");
private Integer code;
private String desc;
PayBusinessTypeEnum(Integer code, String desc) {
this.code = code;
this.desc = desc;
}
public Integer getCode() {
return code;
}
public String getDesc() {
return desc;
}
}

View File

@@ -0,0 +1,28 @@
package com.cool.store.enums.point;
/**
* @Auther: WangShuo
* @Date: 2024/04/29/上午9:45
* @Version 1.0
* @注释:
*/
public enum PayTypeEnum {
WX_PAY(1,"微信支付"),
BANK_PAY(2,"银行转账");
private Integer code;
private String desc;
PayTypeEnum(Integer code, String desc) {
this.code = code;
this.desc = desc;
}
public Integer getCode() {
return code;
}
public String getDesc() {
return desc;
}
}

View File

@@ -0,0 +1,19 @@
package com.cool.store.dao;
import com.cool.store.mapper.EmployeeTrainingMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Repository;
import javax.annotation.Resource;
/**
* @author byd
* @date 2024-04-29 16:06
*/
@Slf4j
@Repository
public class EmployeeTrainingDAO {
@Resource
private EmployeeTrainingMapper employeeTrainingMapper;
}

View File

@@ -27,19 +27,26 @@ public class EnterpriseUserDAO {
public EnterpriseUserDO getUserInfoById(String userId){
if(StringUtils.isAnyBlank(userId)){
if(StringUtils.isBlank(userId)){
return null;
}
return enterpriseUserMapper.getUserInfoById( userId);
}
public EnterpriseUserDO getUserInfoByJobnumber(String jobnumber){
if(StringUtils.isAnyBlank(jobnumber)){
if(StringUtils.isBlank(jobnumber)){
return null;
}
return enterpriseUserMapper.getUserInfoByJobnumber(jobnumber);
}
public EnterpriseUserDO getUserInfoByThirdOaUniqueFlag(String thirdOaUniqueFlag){
if(StringUtils.isBlank(thirdOaUniqueFlag)){
return null;
}
return enterpriseUserMapper.getUserInfoByThirdOaUniqueFlag(thirdOaUniqueFlag);
}
public List<EnterpriseUserDO> getUserInfoByUserIds(List<String> userIdList){
if(CollectionUtils.isEmpty(userIdList)){
return Lists.newArrayList();

View File

@@ -148,17 +148,17 @@ public class ShopInfoDAO {
/**
* @Auther: wangshuo
* @Date: 2024/4/25
* @description: 根据idlist 获取shopcode
* @description: 根据idlist 获取storeNum
*/
public List<OpenPlanShopInfoDTO> queryShopCodeListByid(@Param("shopIdList") List<Long> shopIdList){
return shopInfoMapper.queryShopCodeListByid(shopIdList);
public List<OpenPlanShopInfoDTO> queryStoreNumeListByid(List<Long> shopIdList){
return shopInfoMapper.queryStoreNumeListByid(shopIdList);
}
public List<PreparationDTO> ListByCondition(PreparationRequest request){
return shopInfoMapper.ListByCondition(request);
}
public Long getRegionIdByShopCode(String shopCode){
return shopInfoMapper.getRegionIdByShopCode(shopCode);
public Long getRegionIdByid(Long shopId){
return shopInfoMapper.getRegionIdByid(shopId);
}
}

View File

@@ -0,0 +1,17 @@
package com.cool.store.dao;
import com.cool.store.mapper.TempUserDetailMapper;
import org.springframework.stereotype.Repository;
import javax.annotation.Resource;
/**
* @author byd
* @date 2024-04-29 16:06
*/
@Repository
public class TempUserDetailDAO {
@Resource
private TempUserDetailMapper tempUserDetailMapper;
}

View File

@@ -5,6 +5,7 @@ import com.cool.store.entity.BankdocDO;
import com.cool.store.request.BranchBankPageRequest;
import com.cool.store.request.LineInterviewPageRequest;
import com.github.pagehelper.Page;
import org.apache.ibatis.annotations.Param;
import java.util.List;
@@ -23,4 +24,5 @@ public interface BankdocMapper {
Page<BankdocDO> listBranchBank(BranchBankPageRequest request);
}

View File

@@ -0,0 +1,7 @@
package com.cool.store.mapper;
import com.cool.store.entity.EmployeeTrainingDO;
import tk.mybatis.mapper.common.Mapper;
public interface EmployeeTrainingMapper extends Mapper<EmployeeTrainingDO> {
}

View File

@@ -22,6 +22,7 @@ public interface EnterpriseUserMapper {
EnterpriseUserDO getUserInfoByJobnumber(@Param("jobnumber") String jobnumber);
EnterpriseUserDO getUserInfoByThirdOaUniqueFlag(@Param("thirdOaUniqueFlag") String thirdOaUniqueFlag);
/**
* 批量获取用户信息

View File

@@ -20,6 +20,4 @@ public interface ShopAuditInfoMapper extends Mapper<ShopAuditInfoDO> {
* @description:根据店铺id查询审批结果
*/
Long selectAuditIdByShopId(@Param("shopId") Long shopId);
}

View File

@@ -76,14 +76,14 @@ public interface ShopInfoMapper extends Mapper<ShopInfoDO> {
/**
* @Auther: wangshuo
* @Date: 2024/4/25
* @description: 根据idlist 获取shopcode
* @description: 根据idlist 获取storenum
*/
List<OpenPlanShopInfoDTO> queryShopCodeListByid(@Param("shopIdList") List<Long> shopIdList);
List<OpenPlanShopInfoDTO> queryStoreNumeListByid(@Param("shopIdList") List<Long> shopIdList);
List<LineCountDTO> getSelectedShopNum(@Param("lineIds") List<Long> lineIds);
List<PreparationDTO> ListByCondition(@Param("request") PreparationRequest request);
Long getRegionIdByShopCode(@Param("shopCode") String shopCode);
Long getRegionIdByid(@Param("shopId") Long shopId);
}

View File

@@ -1,8 +1,10 @@
package com.cool.store.mapper;
import com.cool.store.entity.SignFranchiseDO;
import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;
public interface SignFranchiseMapper extends Mapper<SignFranchiseDO> {
SignFranchiseDO selectByShopId(@Param("shopId") Long shopId);
}

View File

@@ -0,0 +1,7 @@
package com.cool.store.mapper;
import com.cool.store.entity.TempUserDetailDO;
import tk.mybatis.mapper.common.Mapper;
public interface TempUserDetailMapper extends Mapper<TempUserDetailDO> {
}

View File

@@ -99,8 +99,8 @@
<where>
<if test="keyWord != null and keyWord != ''">
AND (
l.username = #{keyWord}
OR l.mobile = #{keyWord}
l.username like CONCAT('%',#{keyWord},'%')
OR l.mobile like CONCAT('%',#{keyWord},'%')
)
</if>
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''">

View File

@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.cool.store.mapper.EmployeeTrainingMapper">
<resultMap id="BaseResultMap" type="com.cool.store.entity.EmployeeTrainingDO">
<!--
WARNING - @mbg.generated
-->
<id column="id" jdbcType="BIGINT" property="id" />
<result column="shop_id" jdbcType="BIGINT" property="shopId" />
<result column="region_id" jdbcType="BIGINT" property="regionId" />
<result column="xfsg_user_detail_id" jdbcType="BIGINT" property="xfsgUserDetailId" />
<result column="assign_flag" jdbcType="TINYINT" property="assignFlag" />
<result column="training_start_time" jdbcType="TIMESTAMP" property="trainingStartTime" />
<result column="training_end_time" jdbcType="TIMESTAMP" property="trainingEndTime" />
<result column="training_store_id" jdbcType="VARCHAR" property="trainingStoreId" />
<result column="training_teacher_user_id" jdbcType="VARCHAR" property="trainingTeacherUserId" />
<result column="practical_assessment_user_id" jdbcType="VARCHAR" property="practicalAssessmentUserId" />
<result column="estimated_assessment_time" jdbcType="TIMESTAMP" property="estimatedAssessmentTime" />
<result column="actual_assessment_time" jdbcType="TIMESTAMP" property="actualAssessmentTime" />
<result column="assessment_num" jdbcType="INTEGER" property="assessmentNum" />
<result column="assessment_total_num" jdbcType="INTEGER" property="assessmentTotalNum" />
<result column="theoretical_exam_status" jdbcType="TINYINT" property="theoreticalExamStatus" />
<result column="theoretical_exam_score" jdbcType="INTEGER" property="theoreticalExamScore" />
<result column="practical_exam_status" jdbcType="TINYINT" property="practicalExamStatus" />
<result column="practical_exam_score" jdbcType="INTEGER" property="practicalExamScore" />
<result column="assessment_status" jdbcType="TINYINT" property="assessmentStatus" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="deleted" jdbcType="BIT" property="deleted" />
</resultMap>
</mapper>

View File

@@ -19,13 +19,15 @@
<result column="face_url" jdbcType="VARCHAR" property="faceUrl"/>
<result column="user_status" jdbcType="TINYINT" property="userStatus"/>
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
<result column="third_oa_unique_flag" jdbcType="VARCHAR" property="thirdOaUniqueFlag"/>
</resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.cool.store.entity.EnterpriseUserDO">
<result column="user_region_ids" jdbcType="LONGVARCHAR" property="userRegionIds"/>
</resultMap>
<sql id="Base_Column_List">
id, user_id, name, remark, mobile, email, org_email, main_admin, is_admin, unionid,
avatar, jobnumber, is_leader, is_leader_in_depts, face_url, user_status, create_time
avatar, jobnumber, is_leader, is_leader_in_depts, face_url, user_status, create_time,
third_oa_unique_flag
</sql>
<sql id="Blob_Column_List">
user_region_ids
@@ -51,6 +53,15 @@
jobnumber = #{jobnumber}
</select>
<select id="getUserInfoByThirdOaUniqueFlag" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>,
<include refid="Blob_Column_List"/>
from
enterprise_user_${enterpriseId}
where
third_oa_unique_flag = #{thirdOaUniqueFlag}
</select>
<select id="getUserInfoByUserIds" resultMap="BaseResultMap">
select

View File

@@ -1,310 +1,318 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.cool.store.mapper.LinePayMapper">
<resultMap id="BaseResultMap" type="com.cool.store.entity.LinePayDO">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="partner_id" jdbcType="VARCHAR" property="partnerId" />
<result column="line_id" jdbcType="BIGINT" property="lineId" />
<result column="pay_status" jdbcType="TINYINT" property="payStatus" />
<result column="pay_type" jdbcType="TINYINT" property="payType" />
<result column="pay_user_name" jdbcType="VARCHAR" property="payUserName" />
<result column="pay_account" jdbcType="VARCHAR" property="payAccount" />
<result column="bank_code" jdbcType="VARCHAR" property="bankCode" />
<result column="bank_name" jdbcType="VARCHAR" property="bankName" />
<result column="branch_bank_code" jdbcType="VARCHAR" property="branchBankCode" />
<result column="branch_bank_name" jdbcType="VARCHAR" property="branchBankName" />
<result column="pay_time" jdbcType="TIMESTAMP" property="payTime" />
<result column="pay_pic" jdbcType="VARCHAR" property="payPic" />
<result column="promise_pic" jdbcType="VARCHAR" property="promisePic" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="create_user_id" jdbcType="VARCHAR" property="createUserId" />
<result column="update_user_id" jdbcType="VARCHAR" property="updateUserId" />
<result column="deleted" jdbcType="BIT" property="deleted" />
<result column="pay_business_type" jdbcType="TINYINT" property="payBusinessType" />
</resultMap>
<sql id="Base_Column_List">
id, partner_id, line_id, pay_status, pay_type, pay_user_name, pay_account, bank_code,
<resultMap id="BaseResultMap" type="com.cool.store.entity.LinePayDO">
<id column="id" jdbcType="BIGINT" property="id"/>
<result column="partner_id" jdbcType="VARCHAR" property="partnerId"/>
<result column="line_id" jdbcType="BIGINT" property="lineId"/>
<result column="pay_status" jdbcType="TINYINT" property="payStatus"/>
<result column="pay_type" jdbcType="TINYINT" property="payType"/>
<result column="pay_user_name" jdbcType="VARCHAR" property="payUserName"/>
<result column="pay_account" jdbcType="VARCHAR" property="payAccount"/>
<result column="bank_code" jdbcType="VARCHAR" property="bankCode"/>
<result column="bank_name" jdbcType="VARCHAR" property="bankName"/>
<result column="branch_bank_code" jdbcType="VARCHAR" property="branchBankCode"/>
<result column="branch_bank_name" jdbcType="VARCHAR" property="branchBankName"/>
<result column="pay_time" jdbcType="TIMESTAMP" property="payTime"/>
<result column="pay_pic" jdbcType="VARCHAR" property="payPic"/>
<result column="promise_pic" jdbcType="VARCHAR" property="promisePic"/>
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
<result column="create_user_id" jdbcType="VARCHAR" property="createUserId"/>
<result column="update_user_id" jdbcType="VARCHAR" property="updateUserId"/>
<result column="deleted" jdbcType="BIT" property="deleted"/>
<result column="pay_business_type" jdbcType="TINYINT" property="payBusinessType"/>
</resultMap>
<sql id="Base_Column_List">
id
, partner_id, line_id, pay_status, pay_type, pay_user_name, pay_account, bank_code,
bank_name, branch_bank_code, branch_bank_name, pay_time, pay_pic, promise_pic, create_time,
update_time, create_user_id, update_user_id, deleted,pay_business_type
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from xfsg_line_pay
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from xfsg_line_pay
where id = #{id,jdbcType=BIGINT}
</delete>
<insert id="insertSelective" parameterType="com.cool.store.entity.LinePayDO">
<selectKey keyProperty="id" order="AFTER" resultType="java.lang.Long">
SELECT LAST_INSERT_ID()
</selectKey>
insert into xfsg_line_pay
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="partnerId != null">
partner_id,
</if>
<if test="lineId != null">
line_id,
</if>
<if test="payStatus != null">
pay_status,
</if>
<if test="payType != null">
pay_type,
</if>
<if test="payUserName != null">
pay_user_name,
</if>
<if test="payAccount != null">
pay_account,
</if>
<if test="bankCode != null">
bank_code,
</if>
<if test="bankName != null">
bank_name,
</if>
<if test="branchBankCode != null">
branch_bank_code,
</if>
<if test="branchBankName != null">
branch_bank_name,
</if>
<if test="payTime != null">
pay_time,
</if>
<if test="payPic != null">
pay_pic,
</if>
<if test="promisePic != null">
promise_pic,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="createUserId != null">
create_user_id,
</if>
<if test="updateUserId != null">
update_user_id,
</if>
<if test="deleted != null">
deleted,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="partnerId != null">
#{partnerId,jdbcType=VARCHAR},
</if>
<if test="lineId != null">
#{lineId,jdbcType=BIGINT},
</if>
<if test="payStatus != null">
#{payStatus,jdbcType=TINYINT},
</if>
<if test="payType != null">
#{payType,jdbcType=TINYINT},
</if>
<if test="payUserName != null">
#{payUserName,jdbcType=VARCHAR},
</if>
<if test="payAccount != null">
#{payAccount,jdbcType=VARCHAR},
</if>
<if test="bankCode != null">
#{bankCode,jdbcType=VARCHAR},
</if>
<if test="bankName != null">
#{bankName,jdbcType=VARCHAR},
</if>
<if test="branchBankCode != null">
#{branchBankCode,jdbcType=VARCHAR},
</if>
<if test="branchBankName != null">
#{branchBankName,jdbcType=VARCHAR},
</if>
<if test="payTime != null">
#{payTime,jdbcType=TIMESTAMP},
</if>
<if test="payPic != null">
#{payPic,jdbcType=VARCHAR},
</if>
<if test="promisePic != null">
#{promisePic,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createUserId != null">
#{createUserId,jdbcType=VARCHAR},
</if>
<if test="updateUserId != null">
#{updateUserId,jdbcType=VARCHAR},
</if>
<if test="deleted != null">
#{deleted,jdbcType=BIT},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.cool.store.entity.LinePayDO">
update xfsg_line_pay
<set>
<if test="partnerId != null">
partner_id = #{partnerId,jdbcType=VARCHAR},
</if>
<if test="lineId != null">
line_id = #{lineId,jdbcType=BIGINT},
</if>
<if test="payStatus != null">
pay_status = #{payStatus,jdbcType=TINYINT},
</if>
<if test="payType != null">
pay_type = #{payType,jdbcType=TINYINT},
</if>
<if test="payUserName != null">
pay_user_name = #{payUserName,jdbcType=VARCHAR},
</if>
<if test="payAccount != null">
pay_account = #{payAccount,jdbcType=VARCHAR},
</if>
<if test="bankCode != null">
bank_code = #{bankCode,jdbcType=VARCHAR},
</if>
<if test="bankName != null">
bank_name = #{bankName,jdbcType=VARCHAR},
</if>
<if test="branchBankCode != null">
branch_bank_code = #{branchBankCode,jdbcType=VARCHAR},
</if>
<if test="branchBankName != null">
branch_bank_name = #{branchBankName,jdbcType=VARCHAR},
</if>
<if test="payTime != null">
pay_time = #{payTime,jdbcType=TIMESTAMP},
</if>
<if test="payPic != null">
pay_pic = #{payPic,jdbcType=VARCHAR},
</if>
<if test="promisePic != null">
promise_pic = #{promisePic,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createUserId != null">
create_user_id = #{createUserId,jdbcType=VARCHAR},
</if>
<if test="updateUserId != null">
update_user_id = #{updateUserId,jdbcType=VARCHAR},
</if>
<if test="deleted != null">
deleted = #{deleted,jdbcType=BIT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPidAndLid">
update xfsg_line_pay
set audit_id = #{auditId}
where line_id = #{lineId}
and partner_id = #{partnerId}
</update>
<sql id="dynamicQuery">
<trim prefix="WHERE" prefixOverrides="AND | OR">
<if test="null != id">
and t.id = #{id,jdbcType=BIGINT}
</if>
<if test="null != partnerId">
and t.partner_id = #{partnerId,jdbcType=VARCHAR}
</if>
<if test="null != lineId">
and t.line_id = #{lineId,jdbcType=BIGINT}
</if>
<if test="null != payStatus">
and t.pay_status = #{payStatus,jdbcType=TINYINT}
</if>
<if test="null != payType">
and t.pay_type = #{payType,jdbcType=TINYINT}
</if>
<if test="null != payUserName">
and t.pay_user_name = #{payUserName,jdbcType=VARCHAR}
</if>
<if test="null != payAccount">
and t.pay_account = #{payAccount,jdbcType=VARCHAR}
</if>
<if test="null != bankCode">
and t.bank_code = #{bankCode,jdbcType=VARCHAR}
</if>
<if test="null != bankName">
and t.bank_name = #{bankName,jdbcType=VARCHAR}
</if>
<if test="null != branchBankCode">
and t.branch_bank_code = #{branchBankCode,jdbcType=VARCHAR}
</if>
<if test="null != branchBankName">
and t.branch_bank_name = #{branchBankName,jdbcType=VARCHAR}
</if>
<if test="null != payTime">
and t.pay_time = #{payTime,jdbcType=TIMESTAMP}
</if>
<if test="null != payPic">
and t.pay_pic = #{payPic,jdbcType=VARCHAR}
</if>
<if test="null != promisePic">
and t.promise_pic = #{promisePic,jdbcType=VARCHAR}
</if>
<if test="null != createTime">
and t.create_time = #{createTime,jdbcType=TIMESTAMP}
</if>
<if test="null != updateTime">
and t.update_time = #{updateTime,jdbcType=TIMESTAMP}
</if>
<if test="null != createUserId">
and t.create_user_id = #{createUserId,jdbcType=VARCHAR}
</if>
<if test="null != updateUserId">
and t.update_user_id = #{updateUserId,jdbcType=VARCHAR}
</if>
<if test="null != deleted">
and t.deleted = #{deleted,jdbcType=BIT}
</if>
</trim>
</sql>
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from xfsg_line_pay
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete
from xfsg_line_pay
where id = #{id,jdbcType=BIGINT}
</delete>
<insert id="insertSelective" parameterType="com.cool.store.entity.LinePayDO">
<selectKey keyProperty="id" order="AFTER" resultType="java.lang.Long">
SELECT LAST_INSERT_ID()
</selectKey>
insert into xfsg_line_pay
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="partnerId != null">
partner_id,
</if>
<if test="lineId != null">
line_id,
</if>
<if test="payStatus != null">
pay_status,
</if>
<if test="payType != null">
pay_type,
</if>
<if test="payUserName != null">
pay_user_name,
</if>
<if test="payAccount != null">
pay_account,
</if>
<if test="bankCode != null">
bank_code,
</if>
<if test="bankName != null">
bank_name,
</if>
<if test="branchBankCode != null">
branch_bank_code,
</if>
<if test="branchBankName != null">
branch_bank_name,
</if>
<if test="payTime != null">
pay_time,
</if>
<if test="payPic != null">
pay_pic,
</if>
<if test="promisePic != null">
promise_pic,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="createUserId != null">
create_user_id,
</if>
<if test="updateUserId != null">
update_user_id,
</if>
<if test="deleted != null">
deleted,
</if>
<if test="payBusinessType !=null">
pay_business_type
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="partnerId != null">
#{partnerId,jdbcType=VARCHAR},
</if>
<if test="lineId != null">
#{lineId,jdbcType=BIGINT},
</if>
<if test="payStatus != null">
#{payStatus,jdbcType=TINYINT},
</if>
<if test="payType != null">
#{payType,jdbcType=TINYINT},
</if>
<if test="payUserName != null">
#{payUserName,jdbcType=VARCHAR},
</if>
<if test="payAccount != null">
#{payAccount,jdbcType=VARCHAR},
</if>
<if test="bankCode != null">
#{bankCode,jdbcType=VARCHAR},
</if>
<if test="bankName != null">
#{bankName,jdbcType=VARCHAR},
</if>
<if test="branchBankCode != null">
#{branchBankCode,jdbcType=VARCHAR},
</if>
<if test="branchBankName != null">
#{branchBankName,jdbcType=VARCHAR},
</if>
<if test="payTime != null">
#{payTime,jdbcType=TIMESTAMP},
</if>
<if test="payPic != null">
#{payPic,jdbcType=VARCHAR},
</if>
<if test="promisePic != null">
#{promisePic,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createUserId != null">
#{createUserId,jdbcType=VARCHAR},
</if>
<if test="updateUserId != null">
#{updateUserId,jdbcType=VARCHAR},
</if>
<if test="deleted != null">
#{deleted,jdbcType=BIT},
</if>
<if test="payBusinessType !=null">
#{payBusinessType,jdbcType=TINYINT}
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.cool.store.entity.LinePayDO">
update xfsg_line_pay
<set>
<if test="partnerId != null">
partner_id = #{partnerId,jdbcType=VARCHAR},
</if>
<if test="lineId != null">
line_id = #{lineId,jdbcType=BIGINT},
</if>
<if test="payStatus != null">
pay_status = #{payStatus,jdbcType=TINYINT},
</if>
<if test="payType != null">
pay_type = #{payType,jdbcType=TINYINT},
</if>
<if test="payUserName != null">
pay_user_name = #{payUserName,jdbcType=VARCHAR},
</if>
<if test="payAccount != null">
pay_account = #{payAccount,jdbcType=VARCHAR},
</if>
<if test="bankCode != null">
bank_code = #{bankCode,jdbcType=VARCHAR},
</if>
<if test="bankName != null">
bank_name = #{bankName,jdbcType=VARCHAR},
</if>
<if test="branchBankCode != null">
branch_bank_code = #{branchBankCode,jdbcType=VARCHAR},
</if>
<if test="branchBankName != null">
branch_bank_name = #{branchBankName,jdbcType=VARCHAR},
</if>
<if test="payTime != null">
pay_time = #{payTime,jdbcType=TIMESTAMP},
</if>
<if test="payPic != null">
pay_pic = #{payPic,jdbcType=VARCHAR},
</if>
<if test="promisePic != null">
promise_pic = #{promisePic,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="createUserId != null">
create_user_id = #{createUserId,jdbcType=VARCHAR},
</if>
<if test="updateUserId != null">
update_user_id = #{updateUserId,jdbcType=VARCHAR},
</if>
<if test="deleted != null">
deleted = #{deleted,jdbcType=BIT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPidAndLid">
update xfsg_line_pay
set audit_id = #{auditId}
where line_id = #{lineId}
and partner_id = #{partnerId}
</update>
<sql id="dynamicQuery">
<trim prefix="WHERE" prefixOverrides="AND | OR">
<if test="null != id">
and t.id = #{id,jdbcType=BIGINT}
</if>
<if test="null != partnerId">
and t.partner_id = #{partnerId,jdbcType=VARCHAR}
</if>
<if test="null != lineId">
and t.line_id = #{lineId,jdbcType=BIGINT}
</if>
<if test="null != payStatus">
and t.pay_status = #{payStatus,jdbcType=TINYINT}
</if>
<if test="null != payType">
and t.pay_type = #{payType,jdbcType=TINYINT}
</if>
<if test="null != payUserName">
and t.pay_user_name = #{payUserName,jdbcType=VARCHAR}
</if>
<if test="null != payAccount">
and t.pay_account = #{payAccount,jdbcType=VARCHAR}
</if>
<if test="null != bankCode">
and t.bank_code = #{bankCode,jdbcType=VARCHAR}
</if>
<if test="null != bankName">
and t.bank_name = #{bankName,jdbcType=VARCHAR}
</if>
<if test="null != branchBankCode">
and t.branch_bank_code = #{branchBankCode,jdbcType=VARCHAR}
</if>
<if test="null != branchBankName">
and t.branch_bank_name = #{branchBankName,jdbcType=VARCHAR}
</if>
<if test="null != payTime">
and t.pay_time = #{payTime,jdbcType=TIMESTAMP}
</if>
<if test="null != payPic">
and t.pay_pic = #{payPic,jdbcType=VARCHAR}
</if>
<if test="null != promisePic">
and t.promise_pic = #{promisePic,jdbcType=VARCHAR}
</if>
<if test="null != createTime">
and t.create_time = #{createTime,jdbcType=TIMESTAMP}
</if>
<if test="null != updateTime">
and t.update_time = #{updateTime,jdbcType=TIMESTAMP}
</if>
<if test="null != createUserId">
and t.create_user_id = #{createUserId,jdbcType=VARCHAR}
</if>
<if test="null != updateUserId">
and t.update_user_id = #{updateUserId,jdbcType=VARCHAR}
</if>
<if test="null != deleted">
and t.deleted = #{deleted,jdbcType=BIT}
</if>
</trim>
</sql>
<select id="getLinePayByLineId" resultMap="BaseResultMap">
select *
from xfsg_line_pay
where line_id = #{lineId}
and deleted = '0'
</select>
<select id="getLinePayByLineId" resultMap="BaseResultMap">
select *
from xfsg_line_pay
where line_id = #{lineId}
and deleted = '0'
</select>
<select id="getLinePayByLineIdAndPayType" resultMap="BaseResultMap">
select *
from xfsg_line_pay
where line_id = #{lineId}
and deleted = '0'
and pay_business_type = #{payBusinessType}
</select>
<select id="getLinePayByLineIdAndPayType" resultMap="BaseResultMap">
select *
from xfsg_line_pay
where line_id = #{lineId}
and deleted = '0'
and pay_business_type = #{payBusinessType}
</select>
<select id="getLinePayByLineIds" resultMap="BaseResultMap">
select * from xfsg_line_pay where deleted = 0
<if test="lineIds !=null and lineIds.size>0">
<foreach collection="lineIds" item="lineId" open="and line_id in (" close=")" separator=",">
#{lineId}
</foreach>
</if>
</select>
<select id="getLinePayByLineIds" resultMap="BaseResultMap">
select * from xfsg_line_pay where deleted = 0
<if test="lineIds !=null and lineIds.size>0">
<foreach collection="lineIds" item="lineId" open="and line_id in (" close=")" separator=",">
#{lineId}
</foreach>
</if>
</select>
</mapper>

View File

@@ -47,7 +47,7 @@
<select id="getOpenPlanShopListByCondition"
resultType="com.cool.store.dto.openPreparation.OpenPlanShopInfoDTO">
select si.id as shopId, si.region_id AS regionId,si.line_id as lineId, si.shop_name as shopName,
si.shop_code as shopCode, si.shop_manager_user_id as shopManagerUserId,li.investment_manager AS investmentManagerId,
si.store_num as storeNum, si.shop_manager_user_id as shopManagerUserId,li.investment_manager AS investmentManagerId,
li.username as partnerName, li.mobile as mobile ,
op.submission_time AS submissionTime , op.result_type AS resultType
from xfsg_opening_operation_plan op

View File

@@ -79,13 +79,13 @@
where shop_stage = 2
and deleted = 0
</select>
<select id="queryShopCodeListByid" resultType="com.cool.store.dto.openPreparation.OpenPlanShopInfoDTO">
select id as shopId,shop_code as shopCode
<select id="queryStoreNumeListByid" resultType="com.cool.store.dto.openPreparation.OpenPlanShopInfoDTO">
select id as shopId,store_num as storeNum
from xfsg_shop_info
where 1=1
<if test="shopIdList != null and shopIdList.size >0">
and id in
<foreach collection="shopIdList" separator="," open="" close="" item="shopId">
<foreach collection="shopIdList" separator="," open="(" close=")" item="shopId">
#{shopId}
</foreach>
</if>
@@ -149,11 +149,11 @@
</foreach>
</if>
</select>
<select id="getRegionIdByShopCode" resultType="java.lang.Long">
<select id="getRegionIdByid" resultType="java.lang.Long">
select r.parent_id
from xfsg_shop_info xsi
join region_${enterpriseId} r on r.id = xsi.region_id
where xsi.shop_code = #{shopCode}
where xsi.id = #{shopId}
</select>

View File

@@ -1,4 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.cool.store.mapper.SignFranchiseMapper">
<select id="selectByShopId" resultType="com.cool.store.entity.SignFranchiseDO">
select *
from xfsg_sign_franchise
where shop_id = #{shopId}
</select>
</mapper>

View File

@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.cool.store.mapper.TempUserDetailMapper">
<resultMap id="BaseResultMap" type="com.cool.store.entity.TempUserDetailDO">
<!--
WARNING - @mbg.generated
-->
<id column="id" jdbcType="BIGINT" property="id" />
<result column="line_id" jdbcType="BIGINT" property="lineId" />
<result column="shop_id" jdbcType="BIGINT" property="shopId" />
<result column="region_id" jdbcType="BIGINT" property="regionId" />
<result column="mobile" jdbcType="VARCHAR" property="mobile" />
<result column="username" jdbcType="VARCHAR" property="username" />
<result column="sex" jdbcType="VARCHAR" property="sex" />
<result column="age" jdbcType="INTEGER" property="age" />
<result column="id_card" jdbcType="VARCHAR" property="idCard" />
<result column="educational" jdbcType="TINYINT" property="educational" />
<result column="role_id" jdbcType="BIGINT" property="roleId" />
<result column="id_card_positive_url" jdbcType="VARCHAR" property="idCardPositiveUrl" />
<result column="id_card_negative_url" jdbcType="VARCHAR" property="idCardNegativeUrl" />
<result column="health_certificate_url" jdbcType="VARCHAR" property="healthCertificateUrl" />
<result column="register_time" jdbcType="TIMESTAMP" property="registerTime" />
<result column="source" jdbcType="VARCHAR" property="source" />
<result column="submit_time" jdbcType="TIMESTAMP" property="submitTime" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="deleted" jdbcType="BIT" property="deleted" />
</resultMap>
</mapper>

View File

@@ -26,8 +26,8 @@ public class OpenPlanShopInfoDTO {
@ApiModelProperty("门店名字")
private String shopName;
@ApiModelProperty("门店")
private String shopCode;
@ApiModelProperty("门店")
private String storeNum;
@ApiModelProperty("开店负责人id")
private String shopManagerUserId;

View File

@@ -0,0 +1,31 @@
package com.cool.store.dto.yun;
import lombok.Data;
/**
* @Author suzhuhong
* @Date 2024/3/25 17:03
* @Version 1.0
*/
@Data
public class StudentResultDTO {
private String userId;
/**
* 用户考试状态 0未开始1考试中2已提交3批阅中4已完成
*/
private Integer userExamStatus;
/**
* 最新分
*/
private Float newScore;
/**
* 是否通过0不是1
*/
private Integer passed;
}

View File

@@ -0,0 +1,528 @@
package com.cool.store.entity;
import java.util.Date;
import javax.persistence.*;
@Table(name = "xfsg_employee_training")
public class EmployeeTrainingDO {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
/**
* shop_info.id
*/
@Column(name = "shop_id")
private Long shopId;
/**
* 区域ID
*/
@Column(name = "region_id")
private Long regionId;
/**
* xfsg_temp_user_detail.id
*/
@Column(name = "xfsg_user_detail_id")
private Long xfsgUserDetailId;
/**
* 是否分配 0-待分配 1-已分配
*/
@Column(name = "assign_flag")
private Byte assignFlag;
/**
* 实训开始时间
*/
@Column(name = "training_start_time")
private Date trainingStartTime;
/**
* 实训结束时间
*/
@Column(name = "training_end_time")
private Date trainingEndTime;
/**
* 实训门店ID
*/
@Column(name = "training_store_id")
private String trainingStoreId;
/**
* 带教老师ID
*/
@Column(name = "training_teacher_user_id")
private String trainingTeacherUserId;
/**
* 实操考核人员ID
*/
@Column(name = "practical_assessment_user_id")
private String practicalAssessmentUserId;
/**
* 预计考核时间
*/
@Column(name = "estimated_assessment_time")
private Date estimatedAssessmentTime;
/**
* 实际考核时间
*/
@Column(name = "actual_assessment_time")
private Date actualAssessmentTime;
/**
* 考核项数
*/
@Column(name = "assessment_num")
private Integer assessmentNum;
/**
* 考核总项数
*/
@Column(name = "assessment_total_num")
private Integer assessmentTotalNum;
/**
* 理论考试状态 0-未开始 1-合格 2-不合格
*/
@Column(name = "theoretical_exam_status")
private Byte theoreticalExamStatus;
/**
* 理论考试分值
*/
@Column(name = "theoretical_exam_score")
private Integer theoreticalExamScore;
/**
* 实操考试状态 0-未开始 1-合格 2-不合格
*/
@Column(name = "practical_exam_status")
private Byte practicalExamStatus;
/**
* 实操考试分值
*/
@Column(name = "practical_exam_score")
private Integer practicalExamScore;
/**
* 考核状态 0-培训中 1-带考核 2-考核通过 3-考核不通过
*/
@Column(name = "assessment_status")
private Byte assessmentStatus;
/**
* 创建时间
*/
@Column(name = "create_time")
private Date createTime;
/**
* 更新时间
*/
@Column(name = "update_time")
private Date updateTime;
/**
* 是否删除0.否 1.是
*/
private Boolean deleted;
/**
* @return id
*/
public Long getId() {
return id;
}
/**
* @param id
*/
public void setId(Long id) {
this.id = id;
}
/**
* 获取shop_info.id
*
* @return shop_id - shop_info.id
*/
public Long getShopId() {
return shopId;
}
/**
* 设置shop_info.id
*
* @param shopId shop_info.id
*/
public void setShopId(Long shopId) {
this.shopId = shopId;
}
/**
* 获取区域ID
*
* @return region_id - 区域ID
*/
public Long getRegionId() {
return regionId;
}
/**
* 设置区域ID
*
* @param regionId 区域ID
*/
public void setRegionId(Long regionId) {
this.regionId = regionId;
}
/**
* 获取xfsg_temp_user_detail.id
*
* @return xfsg_user_detail_id - xfsg_temp_user_detail.id
*/
public Long getXfsgUserDetailId() {
return xfsgUserDetailId;
}
/**
* 设置xfsg_temp_user_detail.id
*
* @param xfsgUserDetailId xfsg_temp_user_detail.id
*/
public void setXfsgUserDetailId(Long xfsgUserDetailId) {
this.xfsgUserDetailId = xfsgUserDetailId;
}
/**
* 获取是否分配 0-待分配 1-已分配
*
* @return assign_flag - 是否分配 0-待分配 1-已分配
*/
public Byte getAssignFlag() {
return assignFlag;
}
/**
* 设置是否分配 0-待分配 1-已分配
*
* @param assignFlag 是否分配 0-待分配 1-已分配
*/
public void setAssignFlag(Byte assignFlag) {
this.assignFlag = assignFlag;
}
/**
* 获取实训开始时间
*
* @return training_start_time - 实训开始时间
*/
public Date getTrainingStartTime() {
return trainingStartTime;
}
/**
* 设置实训开始时间
*
* @param trainingStartTime 实训开始时间
*/
public void setTrainingStartTime(Date trainingStartTime) {
this.trainingStartTime = trainingStartTime;
}
/**
* 获取实训结束时间
*
* @return training_end_time - 实训结束时间
*/
public Date getTrainingEndTime() {
return trainingEndTime;
}
/**
* 设置实训结束时间
*
* @param trainingEndTime 实训结束时间
*/
public void setTrainingEndTime(Date trainingEndTime) {
this.trainingEndTime = trainingEndTime;
}
/**
* 获取实训门店ID
*
* @return training_store_id - 实训门店ID
*/
public String getTrainingStoreId() {
return trainingStoreId;
}
/**
* 设置实训门店ID
*
* @param trainingStoreId 实训门店ID
*/
public void setTrainingStoreId(String trainingStoreId) {
this.trainingStoreId = trainingStoreId;
}
/**
* 获取带教老师ID
*
* @return training_teacher_user_id - 带教老师ID
*/
public String getTrainingTeacherUserId() {
return trainingTeacherUserId;
}
/**
* 设置带教老师ID
*
* @param trainingTeacherUserId 带教老师ID
*/
public void setTrainingTeacherUserId(String trainingTeacherUserId) {
this.trainingTeacherUserId = trainingTeacherUserId;
}
/**
* 获取实操考核人员ID
*
* @return practical_assessment_user_id - 实操考核人员ID
*/
public String getPracticalAssessmentUserId() {
return practicalAssessmentUserId;
}
/**
* 设置实操考核人员ID
*
* @param practicalAssessmentUserId 实操考核人员ID
*/
public void setPracticalAssessmentUserId(String practicalAssessmentUserId) {
this.practicalAssessmentUserId = practicalAssessmentUserId;
}
/**
* 获取预计考核时间
*
* @return estimated_assessment_time - 预计考核时间
*/
public Date getEstimatedAssessmentTime() {
return estimatedAssessmentTime;
}
/**
* 设置预计考核时间
*
* @param estimatedAssessmentTime 预计考核时间
*/
public void setEstimatedAssessmentTime(Date estimatedAssessmentTime) {
this.estimatedAssessmentTime = estimatedAssessmentTime;
}
/**
* 获取实际考核时间
*
* @return actual_assessment_time - 实际考核时间
*/
public Date getActualAssessmentTime() {
return actualAssessmentTime;
}
/**
* 设置实际考核时间
*
* @param actualAssessmentTime 实际考核时间
*/
public void setActualAssessmentTime(Date actualAssessmentTime) {
this.actualAssessmentTime = actualAssessmentTime;
}
/**
* 获取考核项数
*
* @return assessment_num - 考核项数
*/
public Integer getAssessmentNum() {
return assessmentNum;
}
/**
* 设置考核项数
*
* @param assessmentNum 考核项数
*/
public void setAssessmentNum(Integer assessmentNum) {
this.assessmentNum = assessmentNum;
}
/**
* 获取考核总项数
*
* @return assessment_total_num - 考核总项数
*/
public Integer getAssessmentTotalNum() {
return assessmentTotalNum;
}
/**
* 设置考核总项数
*
* @param assessmentTotalNum 考核总项数
*/
public void setAssessmentTotalNum(Integer assessmentTotalNum) {
this.assessmentTotalNum = assessmentTotalNum;
}
/**
* 获取理论考试状态 0-未开始 1-合格 2-不合格
*
* @return theoretical_exam_status - 理论考试状态 0-未开始 1-合格 2-不合格
*/
public Byte getTheoreticalExamStatus() {
return theoreticalExamStatus;
}
/**
* 设置理论考试状态 0-未开始 1-合格 2-不合格
*
* @param theoreticalExamStatus 理论考试状态 0-未开始 1-合格 2-不合格
*/
public void setTheoreticalExamStatus(Byte theoreticalExamStatus) {
this.theoreticalExamStatus = theoreticalExamStatus;
}
/**
* 获取理论考试分值
*
* @return theoretical_exam_score - 理论考试分值
*/
public Integer getTheoreticalExamScore() {
return theoreticalExamScore;
}
/**
* 设置理论考试分值
*
* @param theoreticalExamScore 理论考试分值
*/
public void setTheoreticalExamScore(Integer theoreticalExamScore) {
this.theoreticalExamScore = theoreticalExamScore;
}
/**
* 获取实操考试状态 0-未开始 1-合格 2-不合格
*
* @return practical_exam_status - 实操考试状态 0-未开始 1-合格 2-不合格
*/
public Byte getPracticalExamStatus() {
return practicalExamStatus;
}
/**
* 设置实操考试状态 0-未开始 1-合格 2-不合格
*
* @param practicalExamStatus 实操考试状态 0-未开始 1-合格 2-不合格
*/
public void setPracticalExamStatus(Byte practicalExamStatus) {
this.practicalExamStatus = practicalExamStatus;
}
/**
* 获取实操考试分值
*
* @return practical_exam_score - 实操考试分值
*/
public Integer getPracticalExamScore() {
return practicalExamScore;
}
/**
* 设置实操考试分值
*
* @param practicalExamScore 实操考试分值
*/
public void setPracticalExamScore(Integer practicalExamScore) {
this.practicalExamScore = practicalExamScore;
}
/**
* 获取考核状态 0-培训中 1-带考核 2-考核通过 3-考核不通过
*
* @return assessment_status - 考核状态 0-培训中 1-带考核 2-考核通过 3-考核不通过
*/
public Byte getAssessmentStatus() {
return assessmentStatus;
}
/**
* 设置考核状态 0-培训中 1-带考核 2-考核通过 3-考核不通过
*
* @param assessmentStatus 考核状态 0-培训中 1-带考核 2-考核通过 3-考核不通过
*/
public void setAssessmentStatus(Byte assessmentStatus) {
this.assessmentStatus = assessmentStatus;
}
/**
* 获取创建时间
*
* @return create_time - 创建时间
*/
public Date getCreateTime() {
return createTime;
}
/**
* 设置创建时间
*
* @param createTime 创建时间
*/
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
/**
* 获取更新时间
*
* @return update_time - 更新时间
*/
public Date getUpdateTime() {
return updateTime;
}
/**
* 设置更新时间
*
* @param updateTime 更新时间
*/
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
/**
* 获取是否删除0.否 1.是
*
* @return deleted - 是否删除0.否 1.是
*/
public Boolean getDeleted() {
return deleted;
}
/**
* 设置是否删除0.否 1.是
*
* @param deleted 是否删除0.否 1.是
*/
public void setDeleted(Boolean deleted) {
this.deleted = deleted;
}
}

View File

@@ -70,4 +70,9 @@ public class EnterpriseUserDO implements Serializable {
@ApiModelProperty("部门集合region_ids")
private String userRegionIds;
/**
* 第三方OA系统唯一标识
*/
private String thirdOaUniqueFlag;
}

View File

@@ -21,6 +21,8 @@ public class FranchiseFeeDO {
private Long shopId;
@Column(name = "pay_id")
private Long payId;
@Column(name = "audit_id")
private Long auditId;
@Column(name = "year_franchise_fee")
private String yearFranchiseFee;
@Column(name = "loan_margin")

View File

@@ -0,0 +1,474 @@
package com.cool.store.entity;
import java.util.Date;
import javax.persistence.*;
@Table(name = "xfsg_temp_user_detail")
public class TempUserDetailDO {
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
private Long id;
/**
* line_info.id
*/
@Column(name = "line_id")
private Long lineId;
/**
* shop_info.id
*/
@Column(name = "shop_id")
private Long shopId;
/**
* 区域ID
*/
@Column(name = "region_id")
private Long regionId;
/**
* 手机号
*/
private String mobile;
/**
* 申请人姓名
*/
private String username;
/**
* 性别0未选,1男,2女
*/
private String sex;
/**
* 年龄
*/
private Integer age;
/**
* 身份证号码
*/
@Column(name = "id_card")
private String idCard;
/**
* 学历 0-小学 1-初中 2-高中 3-中专 4-大专 5-本科 6-硕士 7-硕士以上
*/
private Byte educational;
/**
* 角色id 170000000-店长 180000000-店员
*/
@Column(name = "role_id")
private Long roleId;
/**
* 身份证正面url
*/
@Column(name = "id_card_positive_url")
private String idCardPositiveUrl;
/**
* 身份证反面url
*/
@Column(name = "id_card_negative_url")
private String idCardNegativeUrl;
/**
* 健康证url
*/
@Column(name = "health_certificate_url")
private String healthCertificateUrl;
/**
* 登记时间
*/
@Column(name = "register_time")
private Date registerTime;
/**
* 来源create-创建 sync-钉钉同步
*/
private String source;
/**
* 提交时间
*/
@Column(name = "submit_time")
private Date submitTime;
/**
* 创建时间
*/
@Column(name = "create_time")
private Date createTime;
/**
* 更新时间
*/
@Column(name = "update_time")
private Date updateTime;
/**
* 是否删除0.否 1.是
*/
private Boolean deleted;
/**
* @return id
*/
public Long getId() {
return id;
}
/**
* @param id
*/
public void setId(Long id) {
this.id = id;
}
/**
* 获取line_info.id
*
* @return line_id - line_info.id
*/
public Long getLineId() {
return lineId;
}
/**
* 设置line_info.id
*
* @param lineId line_info.id
*/
public void setLineId(Long lineId) {
this.lineId = lineId;
}
/**
* 获取shop_info.id
*
* @return shop_id - shop_info.id
*/
public Long getShopId() {
return shopId;
}
/**
* 设置shop_info.id
*
* @param shopId shop_info.id
*/
public void setShopId(Long shopId) {
this.shopId = shopId;
}
/**
* 获取区域ID
*
* @return region_id - 区域ID
*/
public Long getRegionId() {
return regionId;
}
/**
* 设置区域ID
*
* @param regionId 区域ID
*/
public void setRegionId(Long regionId) {
this.regionId = regionId;
}
/**
* 获取手机号
*
* @return mobile - 手机号
*/
public String getMobile() {
return mobile;
}
/**
* 设置手机号
*
* @param mobile 手机号
*/
public void setMobile(String mobile) {
this.mobile = mobile;
}
/**
* 获取申请人姓名
*
* @return username - 申请人姓名
*/
public String getUsername() {
return username;
}
/**
* 设置申请人姓名
*
* @param username 申请人姓名
*/
public void setUsername(String username) {
this.username = username;
}
/**
* 获取性别0未选,1男,2女
*
* @return sex - 性别0未选,1男,2女
*/
public String getSex() {
return sex;
}
/**
* 设置性别0未选,1男,2女
*
* @param sex 性别0未选,1男,2女
*/
public void setSex(String sex) {
this.sex = sex;
}
/**
* 获取年龄
*
* @return age - 年龄
*/
public Integer getAge() {
return age;
}
/**
* 设置年龄
*
* @param age 年龄
*/
public void setAge(Integer age) {
this.age = age;
}
/**
* 获取身份证号码
*
* @return id_card - 身份证号码
*/
public String getIdCard() {
return idCard;
}
/**
* 设置身份证号码
*
* @param idCard 身份证号码
*/
public void setIdCard(String idCard) {
this.idCard = idCard;
}
/**
* 获取学历 0-小学 1-初中 2-高中 3-中专 4-大专 5-本科 6-硕士 7-硕士以上
*
* @return educational - 学历 0-小学 1-初中 2-高中 3-中专 4-大专 5-本科 6-硕士 7-硕士以上
*/
public Byte getEducational() {
return educational;
}
/**
* 设置学历 0-小学 1-初中 2-高中 3-中专 4-大专 5-本科 6-硕士 7-硕士以上
*
* @param educational 学历 0-小学 1-初中 2-高中 3-中专 4-大专 5-本科 6-硕士 7-硕士以上
*/
public void setEducational(Byte educational) {
this.educational = educational;
}
/**
* 获取角色id 170000000-店长 180000000-店员
*
* @return role_id - 角色id 170000000-店长 180000000-店员
*/
public Long getRoleId() {
return roleId;
}
/**
* 设置角色id 170000000-店长 180000000-店员
*
* @param roleId 角色id 170000000-店长 180000000-店员
*/
public void setRoleId(Long roleId) {
this.roleId = roleId;
}
/**
* 获取身份证正面url
*
* @return id_card_positive_url - 身份证正面url
*/
public String getIdCardPositiveUrl() {
return idCardPositiveUrl;
}
/**
* 设置身份证正面url
*
* @param idCardPositiveUrl 身份证正面url
*/
public void setIdCardPositiveUrl(String idCardPositiveUrl) {
this.idCardPositiveUrl = idCardPositiveUrl;
}
/**
* 获取身份证反面url
*
* @return id_card_negative_url - 身份证反面url
*/
public String getIdCardNegativeUrl() {
return idCardNegativeUrl;
}
/**
* 设置身份证反面url
*
* @param idCardNegativeUrl 身份证反面url
*/
public void setIdCardNegativeUrl(String idCardNegativeUrl) {
this.idCardNegativeUrl = idCardNegativeUrl;
}
/**
* 获取健康证url
*
* @return health_certificate_url - 健康证url
*/
public String getHealthCertificateUrl() {
return healthCertificateUrl;
}
/**
* 设置健康证url
*
* @param healthCertificateUrl 健康证url
*/
public void setHealthCertificateUrl(String healthCertificateUrl) {
this.healthCertificateUrl = healthCertificateUrl;
}
/**
* 获取登记时间
*
* @return register_time - 登记时间
*/
public Date getRegisterTime() {
return registerTime;
}
/**
* 设置登记时间
*
* @param registerTime 登记时间
*/
public void setRegisterTime(Date registerTime) {
this.registerTime = registerTime;
}
/**
* 获取来源create-创建 sync-钉钉同步
*
* @return source - 来源create-创建 sync-钉钉同步
*/
public String getSource() {
return source;
}
/**
* 设置来源create-创建 sync-钉钉同步
*
* @param source 来源create-创建 sync-钉钉同步
*/
public void setSource(String source) {
this.source = source;
}
/**
* 获取提交时间
*
* @return submit_time - 提交时间
*/
public Date getSubmitTime() {
return submitTime;
}
/**
* 设置提交时间
*
* @param submitTime 提交时间
*/
public void setSubmitTime(Date submitTime) {
this.submitTime = submitTime;
}
/**
* 获取创建时间
*
* @return create_time - 创建时间
*/
public Date getCreateTime() {
return createTime;
}
/**
* 设置创建时间
*
* @param createTime 创建时间
*/
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
/**
* 获取更新时间
*
* @return update_time - 更新时间
*/
public Date getUpdateTime() {
return updateTime;
}
/**
* 设置更新时间
*
* @param updateTime 更新时间
*/
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
/**
* 获取是否删除0.否 1.是
*
* @return deleted - 是否删除0.否 1.是
*/
public Boolean getDeleted() {
return deleted;
}
/**
* 设置是否删除0.否 1.是
*
* @param deleted 是否删除0.否 1.是
*/
public void setDeleted(Boolean deleted) {
this.deleted = deleted;
}
}

View File

@@ -13,4 +13,7 @@ public class AuditFranchiseFeeRequest {
@ApiModelProperty("shopId")
private Long shopId;
@ApiModelProperty("主键id")
private Long id;
}

View File

@@ -1,8 +1,10 @@
package com.cool.store.request;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotNull;
import java.util.Date;
/**
@@ -13,20 +15,30 @@ import java.util.Date;
*/
@Data
public class DecorationPayRequest {
@ApiModelProperty("xfsg_user_info.partner_id")
private String partnerId;
@ApiModelProperty("line_info.id")
@NotNull(message = "线索id不能为空")
private Long lineId;
@ApiModelProperty("店铺编码")
private String shopCode;
@ApiModelProperty("店铺shopId")
private String shopId;
@ApiModelProperty("加盟商姓名")
private String name;
@ApiModelProperty("支付账户")
private String payAccount;
@ApiModelProperty("开户行code")
private String bankCode;
@ApiModelProperty("开户行名称")
private String bankName;
@ApiModelProperty("支行code")
private String branchBankCode;
@ApiModelProperty("支行名称")
private String branchBankName;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty("缴纳时间")
private Date payTime;
@ApiModelProperty("付款截图")
private String payPic;
@ApiModelProperty("支付类型 2-装修款")
private Integer payBusinessType;
}

View File

@@ -0,0 +1,147 @@
package com.cool.store.response;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.Date;
@Data
@ApiModel("提交加盟合同签约请求体")
public class AddSignFranchiseResponse {
@ApiModelProperty("主键,更新时才存在")
private Long id;
private Long shopId;
/**
* SignTypeEnum
*/
@ApiModelProperty("签约类型,0.转让 1.新签 2.续签 3.迁址 5.新签同异业转化")
private Integer signType;
@ApiModelProperty("品牌使用费比例")
private String brandFee;
@ApiModelProperty("是否有营业执照 0-是 1-否")
private Integer isBusinessLicense;
@ApiModelProperty("是否有食营 0-是 1-否")
private Integer isFoodLicense;
@ApiModelProperty("合同开始日期")
private Date contractStartTime;
@ApiModelProperty("合同结束日期")
private Date contractStartEndTime;
@ApiModelProperty("用印次数")
private String impressionNum;
@ApiModelProperty("营业开始时间(日期不重要传分秒即可)")
private Date businessStartHours;
@ApiModelProperty("营业结束时间(日期不重要传分秒即可)")
private Date businessEndHours;
@ApiModelProperty("非常规营业时间原因")
private String irregularReason;
@ApiModelProperty("备注")
private String remark;
@ApiModelProperty("是否补签")
private Integer resign;
@ApiModelProperty("加盟商联系方式")
private String mobile;
@ApiModelProperty("门店名称")
private String storeName;
@ApiModelProperty("门店地址")
private String storeAddress;
@ApiModelProperty("所属大区")
private String bigRegion;
@ApiModelProperty("大区分总")
private String bigRegionManager;
@ApiModelProperty("加盟商类型")
private String franchiseeType;
@ApiModelProperty("交款人")
private String payName;
@ApiModelProperty("营业执照名称")
private String licenseName;
@ApiModelProperty("经营者")
private String operator;
@ApiModelProperty("类型")
private String type;
@ApiModelProperty("社会信用代码")
private String licenseCode;
@ApiModelProperty("经营场所")
private String opeAddress;
@ApiModelProperty("加盟商姓名")
private String partnerName;
@ApiModelProperty("加盟商身份证号")
private String idCardNo;
@ApiModelProperty("加盟商结算账户")
private String bankCardNo;
@ApiModelProperty("开户行")
private String bank;
@ApiModelProperty("支行")
private String subBank;
@ApiModelProperty("身份证地址")
private String idCardAddress;
@ApiModelProperty("交款日期")
private Date payDate;
@ApiModelProperty("每年加盟费")
private String yearFranchiseFee;
@ApiModelProperty("每年加盟费大写")
private String bigYearFranchiseFee;
@ApiModelProperty("贷款保证金")
private String loanMargin;
@ApiModelProperty("贷款保证金大写")
private String bigLoanMargin;
@ApiModelProperty("1开")
private Date firstYearStartTime;
@ApiModelProperty("1结")
private Date firstYearEndTime;
@ApiModelProperty("1费")
private String firstYearFee;
@ApiModelProperty("2开")
private Date secondYearStartTime;
@ApiModelProperty("2结")
private Date secondYearEndTime;
@ApiModelProperty("2费")
private String secondYearFee;
@ApiModelProperty("3开")
private Date thirdYearStartTime;
@ApiModelProperty("3结")
private Date thirdYearEndTime;
@ApiModelProperty("3费")
private String thirdYearFee;
@ApiModelProperty("履约保证金")
private String performanceBond;
@ApiModelProperty("履约保证金大写")
private String bigPerformanceBond;
@ApiModelProperty("享受加盟费和保证金优惠原因")
private String reasons;
}

View File

@@ -42,7 +42,110 @@ public class FranchiseFeeResponse {
private Date createTime;
private Date updateTime;
private LinePayDO linePayDO;
private LinePay linePayDO;
@Data
public static class LinePay{
@ApiModelProperty("")
private Long id;
@ApiModelProperty("xfsg_user_info.partner_id")
private String partnerId;
@ApiModelProperty("line_info.id")
private Long lineId;
@ApiModelProperty("支付状态 45:待缴费 50:已缴费 55缴费失败")
private Integer payStatus;
@ApiModelProperty("支付方式 1微信 2银行转账")
private Integer payType;
@ApiModelProperty("付款人姓名")
private String payUserName;
@ApiModelProperty("付款账号")
private String payAccount;
@ApiModelProperty("开户行code")
private String bankCode;
@ApiModelProperty("开户行名称")
private String bankName;
@ApiModelProperty("支行code")
private String branchBankCode;
@ApiModelProperty("支行名称")
private String branchBankName;
@ApiModelProperty("缴纳时间")
private Date payTime;
@ApiModelProperty("付款截图")
private String payPic;
@ApiModelProperty("承诺书图片")
private String promisePic;
@ApiModelProperty("创建时间")
private Date createTime;
@ApiModelProperty("更新时间")
private Date updateTime;
@ApiModelProperty("创建人")
private String createUserId;
@ApiModelProperty("更新人")
private String updateUserId;
@ApiModelProperty("是否删除0.否 1.是")
private Boolean deleted;
@ApiModelProperty("支付类型 0-缴纳意向金 1-缴纳加盟费 2-装修款")
private Integer payBusinessType;
@ApiModelProperty("缴费金额")
private String amount;
@ApiModelProperty("加盟商姓名")
private String partnerName;
@ApiModelProperty("审核原因")
private String result;
@ApiModelProperty("审核状态")
private Integer status;
public static LinePay from(LinePayDO linePayDO) {
if (linePayDO == null) {
return null;
}
LinePay linePayDO1 = new LinePay();
linePayDO1.setId(linePayDO.getId());
linePayDO1.setPartnerId(linePayDO.getPartnerId());
linePayDO1.setLineId(linePayDO.getLineId());
linePayDO1.setPayStatus(linePayDO.getPayStatus());
linePayDO1.setPayType(linePayDO.getPayType());
linePayDO1.setPayUserName(linePayDO.getPayUserName());
linePayDO1.setPayAccount(linePayDO.getPayAccount());
linePayDO1.setBankCode(linePayDO.getBankCode());
linePayDO1.setBankName(linePayDO.getBankName());
linePayDO1.setBranchBankCode(linePayDO.getBranchBankCode());
linePayDO1.setBranchBankName(linePayDO.getBranchBankName());
linePayDO1.setPayTime(linePayDO.getPayTime());
linePayDO1.setPayPic(linePayDO.getPayPic());
linePayDO1.setPromisePic(linePayDO.getPromisePic());
linePayDO1.setCreateTime(linePayDO.getCreateTime());
linePayDO1.setUpdateTime(linePayDO.getUpdateTime());
linePayDO1.setCreateUserId(linePayDO.getCreateUserId());
linePayDO1.setUpdateUserId(linePayDO.getUpdateUserId());
linePayDO1.setDeleted(linePayDO.getDeleted());
linePayDO1.setPayBusinessType(linePayDO.getPayBusinessType());
return linePayDO1;
}
}

View File

@@ -22,7 +22,7 @@ public class OpeningOperationPlanListVO {
private String shopName;
@ApiModelProperty("门店代码")
private String shopCode;
private String storeNum;
@ApiModelProperty("开店负责人")
private String shopManagerName;

View File

@@ -3,6 +3,7 @@ package com.cool.store.service;
import com.cool.store.dto.decoration.ConstructionScheduleDTO;
import com.cool.store.dto.decoration.DecorationModelDTO;
import com.cool.store.request.DecorationPayRequest;
import com.cool.store.request.LinePaySubmitRequest;
import com.cool.store.vo.DesignInfoVo;
import com.cool.store.vo.PartnerUserInfoVO;
@@ -26,23 +27,23 @@ public interface DecorationService {
* @Date: 2024/4/28
* @description:设计阶段信息
*/
DesignInfoVo DesignInfo(String shopCode);
DesignInfoVo DesignInfo(Long shopId);
/**
* @Auther: wangshuo
* @Date: 2024/4/28
* @description:获取装修款和支付二维码
*/
DecorationModelDTO DecorationModel(String shopCode);
DecorationModelDTO DecorationModel(Long shopId);
/**
* @Auther: wangshuo
* @Date: 2024/4/28
* @description:提交装修款付款凭证
*/
String submitDecorationModel(DecorationPayRequest decorationPayRequest, PartnerUserInfoVO partnerUserInfoVO);
String submitDecorationModel(LinePaySubmitRequest LinePaySubmitRequest, PartnerUserInfoVO partnerUserInfoVO);
/**
* @Auther: wangshuo
* @Date: 2024/4/28
* @description:施工阶段
*/
List<ConstructionScheduleDTO> getConstruction(String shopCode);
List<ConstructionScheduleDTO> getConstruction(Long shopId);
}

View File

@@ -1,13 +1,19 @@
package com.cool.store.service;
import com.cool.store.request.AddSignFranchiseRequest;
import com.cool.store.response.AddSignFranchiseResponse;
import com.cool.store.response.ResponseResult;
public interface SignFranchiseService {
/**
* 提交加盟合同签约
*
* @param request
* @return
*/
ResponseResult submitSignFranchise(AddSignFranchiseRequest request);
AddSignFranchiseResponse getSignFranchise(Long shopId);
}

View File

@@ -14,7 +14,6 @@ public interface XfsgEhrService {
* @return
*/
StaffBaseInfoDTO getUserInfoByCode(String staffNumber);
/**
* 根据加盟商编码查询加盟商
* @param frId
@@ -22,5 +21,8 @@ public interface XfsgEhrService {
*/
FranchiseeInfoDTO getFranchiseeInfoByFrId(String frId);
StaffBaseInfoDTO getUserInfoByIdCard(String idCard);
}

View File

@@ -0,0 +1,18 @@
package com.cool.store.service;
import com.cool.store.dto.yun.StudentResultDTO;
import java.util.List;
import java.util.Map;
/**
* @author byd
* @date 2024-04-29 9:55
*/
public interface YunXueTangApiService {
String getAccessToken();
Map<String, StudentResultDTO> studentResultUserList(List<String> userIdList);
}

View File

@@ -3,17 +3,26 @@ package com.cool.store.service.impl;
import cn.hutool.core.bean.BeanUtil;
import com.alibaba.fastjson.JSONObject;
import com.cool.store.context.PartnerUserHolder;
import com.cool.store.dao.LineInfoDAO;
import com.cool.store.dao.LinePayDAO;
import com.cool.store.dao.RegionQrcodeConfigDao;
import com.cool.store.dao.ShopInfoDAO;
import com.cool.store.dto.decoration.*;
import com.cool.store.dto.openPreparation.OpenPlanShopInfoDTO;
import com.cool.store.entity.LineInfoDO;
import com.cool.store.entity.LinePayDO;
import com.cool.store.enums.ErrorCodeEnum;
import com.cool.store.enums.WorkflowSubStageStatusEnum;
import com.cool.store.enums.point.PayBusinessTypeEnum;
import com.cool.store.enums.point.PayTypeEnum;
import com.cool.store.exception.ServiceException;
import com.cool.store.request.DecorationPayRequest;
import com.cool.store.request.LinePaySubmitRequest;
import com.cool.store.service.DecorationService;
import com.cool.store.service.LinePayService;
import com.cool.store.service.YlfService;
import com.cool.store.utils.poi.StringUtils;
import com.cool.store.utils.poi.constant.Constants;
import com.cool.store.vo.DesignInfoVo;
import com.cool.store.vo.PartnerUserInfoVO;
import com.cool.store.vo.log.DesignLogVo;
@@ -21,6 +30,7 @@ import org.apache.poi.ss.formula.functions.T;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.*;
@@ -44,7 +54,10 @@ public class DecorationServiceImpl implements DecorationService {
@Resource
private ShopInfoDAO shopInfoDAO;
@Resource
private LinePayDAO linePayDAO;
private LineInfoDAO lineInfoDAO;
@Resource
private LinePayService linePayService;
private static String MEASURING_THE_ROOM = "量房";
private static String CONSTRUCTION_DRAWING = "施工图+预算";
@Override
@@ -53,10 +66,8 @@ public class DecorationServiceImpl implements DecorationService {
}
@Override
public DesignInfoVo DesignInfo(String shopCode) {
ProjectDTO projectList = ylfService.getProjectList(shopCode);
String projectId = projectList.getProjectId();
DecorationDTO decoration = ylfService.getDecoration(Long.parseLong(projectId));
public DesignInfoVo DesignInfo(Long shopId) {
DecorationDTO decoration = getDecorationDTO(shopId);
List<DesignSchemeDTO> designScheme = decoration.getDesignScheme();
List<ConstructionScheduleDTO> constructionSchedule = decoration.getConstructionSchedule();
@@ -78,54 +89,61 @@ public class DecorationServiceImpl implements DecorationService {
return designInfoVo;
}
@Override
public DecorationModelDTO DecorationModel(String shopCode) {
if (StringUtils.isEmpty(shopCode)){
public DecorationModelDTO DecorationModel(Long shopId) {
if (shopId == null){
log.error("DecorationModel shopCode is null");
throw new ServiceException(ErrorCodeEnum.PARAMS_VALIDATE_ERROR);
}
ProjectDTO projectList = ylfService.getProjectList(shopCode);
String projectId = projectList.getProjectId();
DecorationDTO decoration = ylfService.getDecoration(Long.parseLong(projectId));
DecorationDTO decoration = getDecorationDTO(shopId);
//TODO 验证
//预算
List<BudgetDTO> proposedBookBudget = decoration.getProposedBookBudget();
Collections.sort(decoration.getProposedBookBudget(),(x1,x2)->x2.getId().compareTo(x1.getId()));
String totalAmount = proposedBookBudget.get(0).getTotalAmount();
//支付二维码url
Long regionId = shopInfoDAO.getRegionIdByShopCode(shopCode);
Long regionId = shopInfoDAO.getRegionIdByid(shopId);
String payPic = regionQrcodeConfigDao.getPayPicByRegionId(regionId);
DecorationModelDTO decorationModelDTO = new DecorationModelDTO();
decorationModelDTO.setPayUrl(payPic);
decorationModelDTO.setTotalAmount(totalAmount);
return decorationModelDTO;
}
@Transactional(rollbackFor = Exception.class)
@Override
public String submitDecorationModel(DecorationPayRequest decorationPayRequest, PartnerUserInfoVO partnerUserInfoVO) {
LinePayDO linePayDO =new LinePayDO();
BeanUtil.copyProperties(decorationPayRequest, linePayDO);
linePayDO.setCreateTime(new Date());
linePayDO.setUpdateTime(new Date());
linePayDO.setLineId(partnerUserInfoVO.getLineId());
linePayDO.setCreateUserId(partnerUserInfoVO.getUsername());
linePayDO.setUpdateUserId(partnerUserInfoVO.getUsername());
linePayDO.setPayBusinessType(2);
linePayDO.setPayType(2);
return "";
public String submitDecorationModel(LinePaySubmitRequest request, PartnerUserInfoVO partnerUserInfoVO) {
DecorationDTO decoration = getDecorationDTO(request.getShopId());
if ( decoration.getPayment() != null && decoration.getPayment().size()>0){
request.setPayStatus(WorkflowSubStageStatusEnum.PAY_DEPOSIT_50.getCode());
}else {
request.setPayStatus(WorkflowSubStageStatusEnum.PAY_DEPOSIT_45.getCode());
}
Long payId = linePayService.submitPayInfo(request, partnerUserInfoVO);
return payId.toString();
}
@Override
public List<ConstructionScheduleDTO> getConstruction(String shopCode) {
ProjectDTO projectList = ylfService.getProjectList(shopCode);
String projectId = projectList.getProjectId();
DecorationDTO decoration = ylfService.getDecoration(Long.parseLong(projectId));
public List<ConstructionScheduleDTO> getConstruction(Long shopId) {
DecorationDTO decoration = getDecorationDTO(shopId);
List<ConstructionScheduleDTO> constructionSchedule = decoration.getConstructionSchedule();
Map<String, ConstructionScheduleDTO> constructionScheduleMap = constructionSchedule.stream().collect(Collectors.toMap(ConstructionScheduleDTO::getName,
dto -> dto));
constructionScheduleMap.remove(MEASURING_THE_ROOM);
constructionScheduleMap.remove(CONSTRUCTION_DRAWING);
List<ConstructionScheduleDTO> collect = constructionScheduleMap.values().stream().collect(Collectors.toList());
collect.sort(Comparator.comparing(ConstructionScheduleDTO::getId));
return collect;
}
private DecorationDTO getDecorationDTO(Long shopId) {
List<Long> shopIds =new ArrayList<>();
shopIds.add(shopId);
List<OpenPlanShopInfoDTO> openPlanShopInfoDTOS = shopInfoDAO.queryStoreNumeListByid(shopIds);
String storeNum = openPlanShopInfoDTOS.get(0).getStoreNum();
ProjectDTO projectList = ylfService.getProjectList(storeNum);
String projectId = projectList.getProjectId();
DecorationDTO decoration = ylfService.getDecoration(Long.parseLong(projectId));
return decoration;
}
}

View File

@@ -5,11 +5,13 @@ import com.cool.store.context.CurrentUserHolder;
import com.cool.store.context.LoginUserInfo;
import com.cool.store.dao.ShopStageInfoDAO;
import com.cool.store.entity.FranchiseFeeDO;
import com.cool.store.entity.LineInfoDO;
import com.cool.store.entity.LinePayDO;
import com.cool.store.entity.ShopAuditInfoDO;
import com.cool.store.enums.AuditTypeEnum;
import com.cool.store.enums.point.ShopSubStageStatusEnum;
import com.cool.store.mapper.FranchiseFeeMapper;
import com.cool.store.mapper.LineInfoMapper;
import com.cool.store.mapper.LinePayMapper;
import com.cool.store.mapper.ShopAuditInfoMapper;
import com.cool.store.request.AuditFranchiseFeeRequest;
@@ -22,6 +24,8 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.math.BigInteger;
import java.util.Objects;
@Service
@Slf4j
@@ -39,6 +43,9 @@ public class FranchiseFeeServiceImpl implements FranchiseFeeService {
@Resource
ShopStageInfoDAO shopStageInfoDAO;
@Resource
LineInfoMapper lineInfoMapper;
@Override
@Transactional(rollbackFor = Exception.class)
public Boolean submitLicense(FranchiseFeeRequest request) {
@@ -54,8 +61,17 @@ public class FranchiseFeeServiceImpl implements FranchiseFeeService {
franchiseFeeDO.setShopId(shopId);
FranchiseFeeDO result = franchiseFeeMapper.selectOneByExample(franchiseFeeDO);
LinePayDO linePayDO = linePayMapper.selectByPrimaryKey(result.getPayId());
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(linePayDO.getLineId());
FranchiseFeeResponse resp = FranchiseFeeResponse.from(result);
resp.setLinePayDO(linePayDO);
FranchiseFeeResponse.LinePay linePayResult = FranchiseFeeResponse.LinePay.from(linePayDO);
linePayResult.setAmount(new BigInteger(result.getPerformanceBond()).add(new BigInteger(result.getFirstYearFee())).toString());
linePayResult.setPartnerName(lineInfoDO.getUsername());
if (Objects.nonNull(result.getAuditId())){
ShopAuditInfoDO shopAuditInfoDO = shopAuditInfoMapper.selectByPrimaryKey(result.getAuditId());
linePayResult.setStatus(shopAuditInfoDO.getResultType());
linePayResult.setResult(shopAuditInfoDO.getResultType() == 0 ? shopAuditInfoDO.getPassReason() : shopAuditInfoDO.getRejectReason());
}
resp.setLinePayDO(linePayResult);
return resp;
}
@@ -64,7 +80,7 @@ public class FranchiseFeeServiceImpl implements FranchiseFeeService {
ShopAuditInfoDO shopAuditInfoDO = new ShopAuditInfoDO();
shopAuditInfoDO.setShopId(request.getShopId());
ShopSubStageStatusEnum shopSubStageStatusEnum = null;
shopAuditInfoDO.setAuditType(AuditTypeEnum.LICENSE_APPROVAL.getCode());
shopAuditInfoDO.setAuditType(AuditTypeEnum.PAY_FRANCHISE_FEE.getCode());
LoginUserInfo user = CurrentUserHolder.getUser();
shopAuditInfoDO.setSubmittedUserId(user.getUserId());
shopAuditInfoDO.setSubmittedUserName(user.getName());
@@ -77,7 +93,14 @@ public class FranchiseFeeServiceImpl implements FranchiseFeeService {
shopAuditInfoDO.setRejectReason(request.getResult());
shopSubStageStatusEnum = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_74;
}
//更新阶段信息
shopStageInfoDAO.updateShopStageInfo(request.getShopId(),shopSubStageStatusEnum);
return shopAuditInfoMapper.insertSelective(shopAuditInfoDO) == 1 ? true : false;
//插入audit
shopAuditInfoMapper.insertSelective(shopAuditInfoDO);
//更新auditId
FranchiseFeeDO franchiseFeeDO = franchiseFeeMapper.selectByPrimaryKey(request.getId());
franchiseFeeDO.setAuditId(shopAuditInfoDO.getId());
franchiseFeeMapper.updateByPrimaryKeySelective(franchiseFeeDO);
return true;
}
}

View File

@@ -11,6 +11,8 @@ import com.cool.store.entity.LinePayDO;
import com.cool.store.enums.ErrorCodeEnum;
import com.cool.store.enums.WorkflowSubStageEnum;
import com.cool.store.enums.WorkflowSubStageStatusEnum;
import com.cool.store.enums.point.PayBusinessTypeEnum;
import com.cool.store.enums.point.PayTypeEnum;
import com.cool.store.exception.ServiceException;
import com.cool.store.mapper.FranchiseFeeMapper;
import com.cool.store.mapper.LineInfoMapper;
@@ -82,7 +84,10 @@ public class LinePayServiceImpl implements LinePayService {
fillLinePay(false, linePayDO, request, partnerUser);
linePayDAO.updateLinePay(linePayDO);
}
}else {
}
if(request.getPayBusinessType() != null
&& request.getPayBusinessType() == 0
&& request.getShopId() != null) {
LinePayDO linePayDO = linePayDAO.getLinePayByLineIdAndPayType(request.getLineId(),0);
if(linePayDO == null){
linePayDO = new LinePayDO();
@@ -98,6 +103,20 @@ public class LinePayServiceImpl implements LinePayService {
lineInfoDAO.insertOrUpdate(lineInfo);
return linePayDO.getId();
}
if (request.getPayBusinessType() != null
&& request.getPayBusinessType() == PayBusinessTypeEnum.DECORATION_MODEL.getCode()
&& request.getShopId() != null){
LinePayDO linePayDO = linePayDAO.getLinePayByLineIdAndPayType(request.getLineId(),PayBusinessTypeEnum.DECORATION_MODEL.getCode());
if(linePayDO == null){
linePayDO = new LinePayDO();
fillLinePay(true, linePayDO, request, partnerUser);
linePayDAO.addLinePay(linePayDO);
}else {
fillLinePay(false, linePayDO, request, partnerUser);
linePayDAO.updateLinePay(linePayDO);
}
return linePayDO.getId();
}
return null;
}

View File

@@ -164,7 +164,7 @@ public class OpeningOperationPlanImpl implements OpeningOperationPlanService {
OpeningOperationPlanListVO openingOperationPlanListVO = new OpeningOperationPlanListVO();
openingOperationPlanListVO.setShopId(x.getShopId());
openingOperationPlanListVO.setShopName(x.getShopName());
openingOperationPlanListVO.setShopCode(x.getShopCode());
openingOperationPlanListVO.setStoreNum(x.getStoreNum());
openingOperationPlanListVO.setPartnerName(x.getPartnerName());
openingOperationPlanListVO.setMobile(x.getMobile());
String[] split = regionNameMap.getOrDefault(x.getRegionId(), "").split("-");

View File

@@ -2,7 +2,6 @@ package com.cool.store.service.impl;
import cn.hutool.core.convert.Convert;
import cn.hutool.core.date.DateTime;
import cn.hutool.core.date.DateUtil;
import com.alibaba.fastjson.JSONObject;
import com.cool.store.context.CurrentUserHolder;
import com.cool.store.context.LoginUserInfo;
@@ -10,6 +9,7 @@ import com.cool.store.dao.ShopStageInfoDAO;
import com.cool.store.entity.*;
import com.cool.store.enums.AuditEnum;
import com.cool.store.enums.ErrorCodeEnum;
import com.cool.store.enums.FranchiseeTypeEnum;
import com.cool.store.enums.SignTypeEnum;
import com.cool.store.enums.point.ShopSubStageStatusEnum;
import com.cool.store.exception.ServiceException;
@@ -17,11 +17,12 @@ import com.cool.store.mapper.*;
import com.cool.store.request.AddSignFranchiseRequest;
import com.cool.store.request.AuditResultRequest;
import com.cool.store.request.FranchiseAgreementRequest;
import com.cool.store.response.AddSignFranchiseResponse;
import com.cool.store.response.ResponseResult;
import com.cool.store.service.CoolStoreStartFlowService;
import com.cool.store.service.SignFranchiseService;
import com.cool.store.service.SysStoreAppService;
import com.cool.store.utils.poi.DateUtils;
import io.swagger.models.auth.In;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
@@ -34,7 +35,7 @@ import java.util.Objects;
@Service
@Slf4j
public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResultService{
public class SignFranchiseServiceImpl implements SignFranchiseService, AuditResultService {
@Resource
SignFranchiseMapper signFranchiseMapper;
@@ -76,15 +77,15 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
@Override
public Boolean auditResult(AuditResultRequest request) {
log.info("SignFranchiseServiceImpl auditResult request{}",JSONObject.toJSONString(request));
log.info("SignFranchiseServiceImpl auditResult request{}", JSONObject.toJSONString(request));
Long shopId = getShopId(request.getKdzBusinessId());
ShopSubStageStatusEnum shopSubStageStatusEnum = null;
if (request.getAuditResult() == 1){
if (request.getAuditResult() == 1) {
shopSubStageStatusEnum = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_84;
}else if (request.getAuditResult() == 0){
} else if (request.getAuditResult() == 0) {
shopSubStageStatusEnum = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_85;
}
shopStageInfoDAO.updateShopStageInfo(shopId,shopSubStageStatusEnum);
shopStageInfoDAO.updateShopStageInfo(shopId, shopSubStageStatusEnum);
return null;
}
@@ -111,7 +112,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
}
//店铺信息
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(request.getShopId());
FranchiseAgreementRequest franchiseAgreementRequest = convertFranchiseAgreement(request,shopInfoDO);
FranchiseAgreementRequest franchiseAgreementRequest = convertFranchiseAgreement(request, shopInfoDO);
MemberQuestionDO memberQuestionDO = joinIntentionMapper.getByLineId(shopInfoDO.getLineId());
ResponseResult responseResult = coolStoreStartFlowService.franchiseAgreement(franchiseAgreementRequest, memberQuestionDO.getJoinType());
shopStageInfoDAO.updateShopStageInfo(request.getShopId(), ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_83);
@@ -120,7 +121,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
public FranchiseAgreementRequest convertFranchiseAgreement(AddSignFranchiseRequest request,
ShopInfoDO shopInfoDO){
ShopInfoDO shopInfoDO) {
LoginUserInfo user = CurrentUserHolder.getUser();
//shopId
@@ -142,9 +143,10 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
//证照办理
LicenseTransactDO licenseTransactDO = applyLicenseMapper.selectOne(LicenseTransactDO.builder().shopId(shopId).build());
//三方部门表
ThirdDepartmentDO thirdDepartmentDO= thirdDepartmentMapper.getByName(systemBuildingShopDO.getBigName());
ThirdDepartmentDO thirdDepartmentDO = thirdDepartmentMapper.getByName(systemBuildingShopDO.getBigName());
//找不到的url统一用这个
List<String> temp = new ArrayList<>();temp.add("object");
List<String> temp = new ArrayList<>();
temp.add("object");
Convert.digitToChinese(123);
FranchiseAgreementRequest buildResult = FranchiseAgreementRequest.builder()
.apply_user(user.getJobNumber())
@@ -214,7 +216,7 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
.jmsxm1(lineInfoDO.getUsername())
.jsrq(DateUtils.dateTime(request.getContractStartEndTime()))
.jszhhz(linePayDO.getPayAccount())
.kdzBusinessId(AuditEnum.SIGN_FRANCHISE+"_"+shopId+"_"+lineId)
.kdzBusinessId(AuditEnum.SIGN_FRANCHISE + "_" + shopId + "_" + lineId)
.khhjzh(linePayDO.getBankName())
.lvbzj(Integer.valueOf(franchiseFeeDO.getPerformanceBond()))
.lybzjdx(Integer.valueOf(franchiseFeeDO.getPerformanceBond()))
@@ -237,13 +239,13 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
.remark(request.getRemark())
.remark2(systemBuildingShopDO.getReasons())
.sfbq__add(request.getResign())
.sj1(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_END,request.getBusinessStartHours()))
.sj2(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_END,request.getBusinessEndHours()))
.sj1(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_END, request.getBusinessStartHours()))
.sj2(DateUtils.parseDateToStr(DateUtils.SPECIAL_DATE_END, request.getBusinessEndHours()))
.social_credit_code(licenseTransactDO.getCreditCode())
.spltxkz(temp)
.sqr_name(user.getName())
.sqrq(DateUtils.getDate())
.title("特许经营合同审批申请2023-"+ lineInfoDO.getUsername() +"-" + DateUtils.getDate())
.title("特许经营合同审批申请2023-" + lineInfoDO.getUsername() + "-" + DateUtils.getDate())
.wlyzbm("201905081151092R")
.yycs(Integer.valueOf(request.getImpressionNum()))
.yyzzblsqs(temp)
@@ -254,4 +256,100 @@ public class SignFranchiseServiceImpl implements SignFranchiseService ,AuditResu
return buildResult;
}
@Override
public AddSignFranchiseResponse getSignFranchise(Long shopId) {
SignFranchiseDO signFranchiseDO = signFranchiseMapper.selectByShopId(shopId);
AddSignFranchiseResponse response = from(signFranchiseDO, shopId);
return response;
}
public AddSignFranchiseResponse from(SignFranchiseDO signFranchiseDO,
Long shopId) {
AddSignFranchiseResponse addSignFranchiseResponse = new AddSignFranchiseResponse();
//店铺信息
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
//线索信息
LineInfoDO lineInfoDO = lineInfoMapper.getByLineId(shopInfoDO.getLineId());
//缴费信息
FranchiseFeeDO franchiseFeeDO = franchiseFeeMapper.selectOne(FranchiseFeeDO.builder().shopId(shopId).build());
//线索id
Long lineId = shopInfoDO.getLineId();
//签约信息
SigningBaseInfoDO signingBaseInfoDO = intentAgreementMapper.selectByPartnerIdOrLineId(null, lineId);
//缴款信息
LinePayDO linePayDO = linePayMapper.getLinePayByLineIdAndPayType(lineId, 1);
//铺位信息
PointInfoDO pointInfoDO = pointInfoMapper.getDataByShopIdAndLineId(lineId, shopId);
//建店数据
SystemBuildingShopDO systemBuildingShopDO = systemBuildingShopMapper.selectOne(SystemBuildingShopDO.builder().shopId(shopId).lineId(lineId).build());
//证照办理
LicenseTransactDO licenseTransactDO = applyLicenseMapper.selectOne(LicenseTransactDO.builder().shopId(shopId).build());
if (Objects.nonNull(signFranchiseDO)) {
addSignFranchiseResponse.setId(signFranchiseDO.getId());
addSignFranchiseResponse.setShopId(signFranchiseDO.getShopId());
addSignFranchiseResponse.setSignType(signFranchiseDO.getSignType());
addSignFranchiseResponse.setBrandFee(signFranchiseDO.getBrandFee());
addSignFranchiseResponse.setIsBusinessLicense(signFranchiseDO.getIsBusinessLicense());
addSignFranchiseResponse.setIsFoodLicense(signFranchiseDO.getIsFoodLicense());
addSignFranchiseResponse.setContractStartTime(signFranchiseDO.getContractStartTime());
addSignFranchiseResponse.setContractStartEndTime(signFranchiseDO.getContractStartEndTime());
addSignFranchiseResponse.setImpressionNum(signFranchiseDO.getImpressionNum());
addSignFranchiseResponse.setBusinessStartHours(signFranchiseDO.getBusinessStartHours());
addSignFranchiseResponse.setBusinessEndHours(signFranchiseDO.getBusinessEndHours());
addSignFranchiseResponse.setIrregularReason(signFranchiseDO.getIrregularReason());
addSignFranchiseResponse.setRemark(signFranchiseDO.getRemark());
addSignFranchiseResponse.setResign(signFranchiseDO.getResign());
addSignFranchiseResponse.setMobile(signFranchiseDO.getMobile());
} else {
addSignFranchiseResponse.setMobile(lineInfoDO.getMobile());
}
if(Objects.nonNull(systemBuildingShopDO)){
addSignFranchiseResponse.setStoreName(systemBuildingShopDO.getStoreName());
addSignFranchiseResponse.setBigRegion(systemBuildingShopDO.getBigName());
addSignFranchiseResponse.setBigRegionManager(systemBuildingShopDO.getRegioGeneral());
addSignFranchiseResponse.setFranchiseeType(FranchiseeTypeEnum.getByCode(systemBuildingShopDO.getFranchiseeType()).getMessage());
addSignFranchiseResponse.setReasons(systemBuildingShopDO.getReasons());
}
if (Objects.nonNull(pointInfoDO)){
addSignFranchiseResponse.setStoreAddress(pointInfoDO.getAddress());
}
if (Objects.nonNull(linePayDO)){
addSignFranchiseResponse.setPayName(linePayDO.getPayUserName());
addSignFranchiseResponse.setBankCardNo(linePayDO.getPayAccount());
addSignFranchiseResponse.setBank(linePayDO.getBankName());
addSignFranchiseResponse.setSubBank(linePayDO.getBranchBankName());
addSignFranchiseResponse.setPayDate(linePayDO.getPayTime());
}
if (Objects.nonNull(licenseTransactDO)){
addSignFranchiseResponse.setLicenseName(licenseTransactDO.getBusinessLicense());
addSignFranchiseResponse.setOpeAddress(licenseTransactDO.getLicenseAddress());
addSignFranchiseResponse.setOperator(licenseTransactDO.getOperator());
}
if (Objects.nonNull(lineInfoDO)){
addSignFranchiseResponse.setPartnerName(lineInfoDO.getUsername());
}
if (Objects.nonNull(signingBaseInfoDO)){
addSignFranchiseResponse.setIdCardNo(signingBaseInfoDO.getIdCardNo());
addSignFranchiseResponse.setIdCardAddress(signingBaseInfoDO.getIdCardAddress());
}
if (Objects.nonNull(franchiseFeeDO)){
addSignFranchiseResponse.setYearFranchiseFee(franchiseFeeDO.getYearFranchiseFee());
addSignFranchiseResponse.setBigYearFranchiseFee(Convert.digitToChinese(Integer.valueOf(franchiseFeeDO.getYearFranchiseFee())));
addSignFranchiseResponse.setLoanMargin(franchiseFeeDO.getLoanMargin());
addSignFranchiseResponse.setBigLoanMargin(Convert.digitToChinese(Integer.valueOf(franchiseFeeDO.getLoanMargin())));
addSignFranchiseResponse.setFirstYearStartTime(franchiseFeeDO.getFirstYearStartTime());
addSignFranchiseResponse.setFirstYearEndTime(franchiseFeeDO.getFirstYearEndTime());
addSignFranchiseResponse.setFirstYearFee(franchiseFeeDO.getFirstYearFee());
addSignFranchiseResponse.setSecondYearStartTime(franchiseFeeDO.getSecondYearStartTime());
addSignFranchiseResponse.setSecondYearEndTime(franchiseFeeDO.getSecondYearEndTime());
addSignFranchiseResponse.setSecondYearFee(franchiseFeeDO.getSecondYearFee());
addSignFranchiseResponse.setThirdYearStartTime(franchiseFeeDO.getThirdYearStartTime());
addSignFranchiseResponse.setThirdYearEndTime(franchiseFeeDO.getThirdYearEndTime());
addSignFranchiseResponse.setThirdYearFee(franchiseFeeDO.getThirdYearFee());
addSignFranchiseResponse.setPerformanceBond(franchiseFeeDO.getPerformanceBond());
addSignFranchiseResponse.setBigPerformanceBond(Convert.digitToChinese(Integer.valueOf(franchiseFeeDO.getPerformanceBond())));
}
return addSignFranchiseResponse;
}
}

View File

@@ -2,11 +2,16 @@ package com.cool.store.service.impl;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.cool.store.dao.EnterpriseUserDAO;
import com.cool.store.dto.ehr.FranchiseeInfoDTO;
import com.cool.store.dto.ehr.StaffBaseInfoDTO;
import com.cool.store.entity.EnterpriseUserDO;
import com.cool.store.enums.ErrorCodeEnum;
import com.cool.store.exception.ServiceException;
import com.cool.store.mq.util.HttpRestTemplateService;
import com.cool.store.service.XfsgEhrService;
import com.cool.store.utils.SecureUtil;
import com.cool.store.utils.StringUtil;
import com.cool.store.utils.poi.constant.Constants;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
@@ -15,6 +20,7 @@ import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;
/**
* describe: 鲜丰水果api
@@ -31,6 +37,10 @@ public class XfsgEhrServiceImpl implements XfsgEhrService {
@Resource
private HttpRestTemplateService httpRestTemplateService;
@Resource
private EnterpriseUserDAO enterpriseUserDAO;
@Override
public StaffBaseInfoDTO getUserInfoByCode(String staffNumber) {
Map<String, Object> requestMap = new HashMap<>();
@@ -73,6 +83,21 @@ public class XfsgEhrServiceImpl implements XfsgEhrService {
return franchiseeInfoDTO;
}
@Override
public StaffBaseInfoDTO getUserInfoByIdCard(String idCard) {
if (StringUtil.isBlank(idCard)) {
throw new ServiceException(ErrorCodeEnum.PARAMS_VALIDATE_ERROR);
}
EnterpriseUserDO enterpriseUserDO = enterpriseUserDAO.getUserInfoByThirdOaUniqueFlag(idCard);
if(Objects.isNull(enterpriseUserDO)){
throw new ServiceException(ErrorCodeEnum.USER_NOT_EXIST);
}
if (StringUtil.isBlank(enterpriseUserDO.getJobnumber())) {
throw new ServiceException(ErrorCodeEnum.JOBNUMBER_NOT_EXIST);
}
return this.getUserInfoByCode(enterpriseUserDO.getJobnumber());
}
private void fillSignatureInfo(Map<String, Object> requestMap) {
long timestamp = System.currentTimeMillis();
String signature = SecureUtil.getSignature(timestamp);

View File

@@ -0,0 +1,108 @@
package com.cool.store.service.impl;
import cn.hutool.http.HttpUtil;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.cool.store.constants.CommonConstants;
import com.cool.store.constants.RedisConstant;
import com.cool.store.dto.yun.StudentResultDTO;
import com.cool.store.mq.util.HttpRestTemplateService;
import com.cool.store.service.YunXueTangApiService;
import com.cool.store.utils.RedisUtilPool;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.function.Function;
import java.util.stream.Collectors;
/**
* @author byd
* @date 2024-04-29 9:55
*/
@Service
public class YunXueTangApiServiceImpl implements YunXueTangApiService {
private final static String REQUEST_URL = "https://openapi.yunxuetang.cn/";
private final static String APP_ID = "1782195114";
private final static String APP_SECRET = "W2Py1G4XYvBFGkXVgdbrZsm4C9zStM5QvBG8WS-0YYw4lPTcoKaFB9S6F5spshCJ";
private final static String ARRANGE_ID = "d011f26d-cd82-4a58-b705-529c63295198";
@Resource
private RedisUtilPool redisUtilPool;
@Resource
private HttpRestTemplateService httpRestTemplateService;
@Override
public String getAccessToken() {
//若果在缓存中存在,从缓存中去取
String accessToken = redisUtilPool.getString(RedisConstant.YUN_XUE_TANG_ACCESS_TOKEN);
if (StringUtils.isNotBlank(accessToken)) {
return accessToken;
}
Map<String, Object> body = new HashMap<>();
// 请求接口地址
String url = "token";
// url拼接所需参数
String pathUrl = REQUEST_URL + url + "?" + "appId=" + APP_ID + "&appSecret=" + APP_SECRET;
// 以post方式调用第三方接口,获取响应结果
String result = HttpUtil.post(pathUrl, body);
// 返回accessToken
JSONObject jsonObject = JSONObject.parseObject(result, JSONObject.class);
accessToken = jsonObject.getString("accessToken");
if (StringUtils.isNotBlank(accessToken)) {
Integer expiresIn = jsonObject.getInteger("expiresIn");
redisUtilPool.setString(RedisConstant.YUN_XUE_TANG_ACCESS_TOKEN, accessToken, expiresIn - 5 * 60);
}
return accessToken;
}
@Override
public Map<String, StudentResultDTO> studentResultUserList(List<String> userIdList) {
Map<String, Object> body = new HashMap<>();
body.put("arrangeId", ARRANGE_ID);
body.put("thirdUserIds", userIdList);
body.put("limit", userIdList.size());
String pathUrl = "v1/rpt2open/public/ote/student/result/user/list";
// 以post方式调用第三方接口,获取响应结果
Map<String, String> headMap = new HashMap<>();
headMap.put("Authorization", this.getAccessToken());
String result = httpRestTemplateService.postForObject(REQUEST_URL + pathUrl, body, String.class, headMap);
List<StudentResultDTO> resultDTOList = new ArrayList<>();
// 返回accessToken
JSONObject jsonObject = JSONObject.parseObject(result, JSONObject.class);
String code = jsonObject.getString("code");
if (CommonConstants.YUN_XUE_TANG_SUC_CODE.equals(code)) {
JSONObject data = jsonObject.getJSONObject("data");
JSONArray jsonArray = jsonObject.getJSONArray("datas");
if (CollectionUtils.isNotEmpty(jsonArray)) {
jsonArray.forEach(item -> {
JSONObject itemObj = (JSONObject) item;
StudentResultDTO resultDTO = new StudentResultDTO();
resultDTO.setUserId(itemObj.getString("thirdUserId"));
resultDTO.setPassed(itemObj.getInteger("passed"));
resultDTO.setNewScore(itemObj.getFloat("newScore"));
resultDTO.setUserExamStatus(itemObj.getInteger("userExamStatus"));
resultDTOList.add(resultDTO);
});
}
}
return resultDTOList.stream().collect(
Collectors.toMap(StudentResultDTO::getUserId, Function.identity()));
}
}

View File

@@ -36,7 +36,7 @@ import java.util.List;
* @注释:
*/
@RestController
@RequestMapping("/pc/OpenPreparation")
@RequestMapping("/pc/openPreparation")
@Api(tags = "pc开业筹备")
@Slf4j
public class OpenPreparationController {
@@ -71,7 +71,7 @@ public class OpenPreparationController {
return ResponseResult.success(auditOpeningOperationPlanService.auditPlan(request));
}
@GetMapping("/openingOperationPlan/planList")
@PostMapping("/openingOperationPlan/planList")
@ApiOperation("查询运营方案列表")
public ResponseResult<PageInfo<OpeningOperationPlanListVO>> planList(@RequestBody PlanListRequest request) {
return ResponseResult.success(openingOperationPlanService.getPlanListPage(request));

View File

@@ -6,6 +6,7 @@ import com.cool.store.dto.decoration.ConstructionScheduleDTO;
import com.cool.store.dto.decoration.DecorationDTO;
import com.cool.store.dto.decoration.DecorationModelDTO;
import com.cool.store.request.DecorationPayRequest;
import com.cool.store.request.LinePaySubmitRequest;
import com.cool.store.response.ResponseResult;
import com.cool.store.service.CoolStoreStartFlowService;
import com.cool.store.service.DecorationService;
@@ -13,6 +14,7 @@ import com.cool.store.service.YlfService;
import com.cool.store.vo.DesignInfoVo;
import com.cool.store.vo.PartnerUserInfoVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;
@@ -32,22 +34,15 @@ import java.util.List;
public class PCDecorationController {
@Resource
private DecorationService decorationService;
@ApiModelProperty("获取设计阶段信息")
@GetMapping("/design")
public ResponseResult<DesignInfoVo> get(@RequestParam String shopCode){
return ResponseResult.success( decorationService.DesignInfo(shopCode)) ;
}
@GetMapping("/getDecorationModel")
public ResponseResult<DecorationModelDTO> getDecorationModel(@RequestParam String shopCode){
return ResponseResult.success(decorationService.DecorationModel(shopCode)) ;
}
@PostMapping("/submitDecorationModel")
public ResponseResult submitDecorationModel(@RequestBody DecorationPayRequest DecorationPayRequest){
PartnerUserInfoVO user = PartnerUserHolder.getUser();
decorationService.submitDecorationModel(DecorationPayRequest, user);
return ResponseResult.success();
public ResponseResult<DesignInfoVo> get(@RequestParam Long shopId){
return ResponseResult.success( decorationService.DesignInfo(shopId)) ;
}
@ApiModelProperty("获取施工阶段信息")
@GetMapping("/getConstruction")
public ResponseResult<List<ConstructionScheduleDTO>> getConstruction(@RequestParam String shopCode){
return ResponseResult.success(decorationService.getConstruction(shopCode)) ;
public ResponseResult<List<ConstructionScheduleDTO>> getConstruction(@RequestParam Long shopId){
return ResponseResult.success(decorationService.getConstruction(shopId)) ;
}
}

View File

@@ -2,16 +2,12 @@ package com.cool.store.controller.webb;
import com.cool.store.request.AddSignFranchiseRequest;
import com.cool.store.request.DeleteShopRequest;
import com.cool.store.response.AddSignFranchiseResponse;
import com.cool.store.response.ResponseResult;
import com.cool.store.service.SignFranchiseService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
@@ -27,4 +23,11 @@ public class PCSignFranchiseController {
public ResponseResult<Boolean> submitSignFranchise(@RequestBody AddSignFranchiseRequest request) {
return signFranchiseService.submitSignFranchise(request);
}
@ApiOperation("获取默认值")
@GetMapping("/default/get")
public ResponseResult<AddSignFranchiseResponse> getSignFranchise(@RequestParam("shopId") Long shopId) {
return ResponseResult.success(signFranchiseService.getSignFranchise(shopId));
}
}

View File

@@ -0,0 +1,41 @@
package com.cool.store.controller.webc;
import com.cool.store.context.PartnerUserHolder;
import com.cool.store.dto.decoration.DecorationModelDTO;
import com.cool.store.request.LinePaySubmitRequest;
import com.cool.store.response.ResponseResult;
import com.cool.store.service.DecorationService;
import com.cool.store.vo.PartnerUserInfoVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
/**
* @Auther: WangShuo
* @Date: 2024/04/29/下午2:46
* @Version 1.0
* @注释:
*/
@RestController
@RequestMapping("/mini/decoration")
@Api(tags = "mini装修阶段")
@Slf4j
public class MiniDecorationController {
@Resource
private DecorationService decorationService;
@PostMapping("/submitDecorationModel")
public ResponseResult submitDecorationModel(@RequestBody LinePaySubmitRequest linePaySubmitRequest){
PartnerUserInfoVO user = PartnerUserHolder.getUser();
user.setPartnerId("61bf57dc65334885802a278835f499d0");
decorationService.submitDecorationModel(linePaySubmitRequest, user);
return ResponseResult.success();
}
@ApiModelProperty("获取装修款信息,和二维码")
@GetMapping("/getDecorationModel")
public ResponseResult<DecorationModelDTO> getDecorationModel(@RequestParam Long shopId){
return ResponseResult.success(decorationService.DecorationModel(shopId)) ;
}
}

View File

@@ -26,12 +26,18 @@ public class TrainingRegistController {
@Resource
XfsgEhrService xfsgEhrService;
@ApiOperation("根据工号获取员工详细信息")
@ApiOperation("根据工号获取人员主数据")
@GetMapping("/getUserInfoByCode")
public ResponseResult<StaffBaseInfoDTO> getUserInfoByCode(@RequestParam("staffNumber") String staffNumber) {
return ResponseResult.success(xfsgEhrService.getUserInfoByCode(staffNumber));
}
@ApiOperation("根据身份证号获取人员主数据")
@GetMapping("/getUserInfoByIdCard")
public ResponseResult<StaffBaseInfoDTO> getUserInfoByIdCard(@RequestParam("idCard") String idCard) {
return ResponseResult.success(xfsgEhrService.getUserInfoByIdCard(idCard));
}
@ApiOperation("根据加盟商编码查询加盟商信息")
@GetMapping("/getFranchiseeInfoByFrId")
public ResponseResult<FranchiseeInfoDTO> getFranchiseeInfoByFrId(@RequestParam("frId") String frId) {

View File

@@ -108,9 +108,9 @@ public class XxlJobHandler {
log.info("------今日没有待更新数据------");
return;
}
List<OpenPlanShopInfoDTO> openPlanShopInfoDTOS = shopInfoDAO.queryShopCodeListByid(shopIdListByStageStatus);
List<OpenPlanShopInfoDTO> openPlanShopInfoDTOS = shopInfoDAO.queryStoreNumeListByid(shopIdListByStageStatus);
Map<Long, String> map = openPlanShopInfoDTOS.stream().
collect(Collectors.toMap(OpenPlanShopInfoDTO::getShopId, OpenPlanShopInfoDTO::getShopCode));
collect(Collectors.toMap(OpenPlanShopInfoDTO::getShopId, OpenPlanShopInfoDTO::getStoreNum));
for (Long shopId : map.keySet()){
String shopCode = map.get(shopId);
try {