Merge remote-tracking branch 'origin/cc_partner_init' into cc_partner_init
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
package com.cool.store.enums;
|
||||
|
||||
public enum AuditEnum {
|
||||
|
||||
CONTRACT_INTENTION("intention", "意向加盟合同API","intentAgreementServiceImpl"),
|
||||
SYS_BUILD("sysBuild", "系统建店API","sysStoreAppServiceImpl"),
|
||||
|
||||
;
|
||||
|
||||
private String code;
|
||||
|
||||
private String message;
|
||||
|
||||
private String clazz;
|
||||
|
||||
AuditEnum(String code, String message, String clazz) {
|
||||
this.code = code;
|
||||
this.message = message;
|
||||
this.clazz = clazz;
|
||||
}
|
||||
|
||||
public String getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
public String getClazz() {
|
||||
return clazz;
|
||||
}
|
||||
|
||||
public static AuditEnum getWorkflowSubStageEnum(String flag) {
|
||||
for (AuditEnum auditEnum : AuditEnum.values()) {
|
||||
if (auditEnum.getCode().equals(flag)) {
|
||||
return auditEnum;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
package com.cool.store.enums;
|
||||
|
||||
public enum AuditTypeEnum {
|
||||
VISUAL_ACCEPTANCE(0, "视觉验收"),
|
||||
TRAINING_REGISTRATION_APPROVAL(1, "培训登记审批"),
|
||||
OPENING_OPERATION_PLAN(2, "开业运营方案"),
|
||||
LICENSE_APPROVAL(3, "证照审批"),
|
||||
SYS_BUILD(4, "系统建店"),
|
||||
|
||||
;
|
||||
|
||||
private Integer code;
|
||||
|
||||
private String name;
|
||||
|
||||
private AuditTypeEnum(Integer code, String name) {
|
||||
this.code = code;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
}
|
||||
@@ -1,14 +1,20 @@
|
||||
package com.cool.store.enums;
|
||||
|
||||
/**
|
||||
* @author zhangchenbiao
|
||||
* @FileName: SmsCodeTypeEnum
|
||||
* @Description: 短信验证码类型
|
||||
* @date 2021-07-20 9:47
|
||||
*/
|
||||
|
||||
public enum SmsCodeTypeEnum {
|
||||
|
||||
LOGIN("SMS_220325070","验证码登录", 10 * 60),
|
||||
FORGOT_PWD("SMS_220325070","忘记密码", 10 * 60),
|
||||
MODIFY_PWD("SMS_220325070","修改密码", 10 * 60),
|
||||
IMPROVE_INFO("SMS_220325070","完善用户信息", 10 * 60),
|
||||
USER_REGISTER("SMS_220325070","用户注册", 10 * 60),
|
||||
ENTERPRISE_REGISTER("SMS_220325070","企业注册", 10 * 60),
|
||||
LOGIN2("SMS_232163403","验证码登录", 10 * 60),
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
;
|
||||
|
||||
private String templateCode;
|
||||
|
||||
@@ -10,11 +10,11 @@ public enum WorkflowSubStageEnum{
|
||||
/**
|
||||
* 流程子阶段枚举
|
||||
*/
|
||||
INTEND(1, "加盟意向申请", WorkflowSubStageStatusEnum.INTENT_0,"joinIntentionServiceImpl",1),
|
||||
INTEND(1, "加盟意向申请", WorkflowSubStageStatusEnum.INTENT_0,"joinIntentionServiceImpl",0),
|
||||
INVITING_INTERVIEWS(5, "邀约面谈", WorkflowSubStageStatusEnum.INVITING_INTERVIEWS_10, "lineInterviewServiceImpl",2),
|
||||
FIRST_INTERVIEWS(10, "一审面试", WorkflowSubStageStatusEnum.FIRST_INTERVIEWS_25, "lineInterviewServiceImpl",4),
|
||||
PAY_DEPOSIT(15, "缴纳意向金", WorkflowSubStageStatusEnum.PAY_DEPOSIT_45, "bankServiceImpl",5),
|
||||
SIGN_INTENT_AGREEMENT(20, "签署意向协议", WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_60, "intentAgreementServiceImpl",7),
|
||||
PAY_DEPOSIT(15, "缴纳意向金", WorkflowSubStageStatusEnum.PAY_DEPOSIT_45, "bankServiceImpl",4),
|
||||
SIGN_INTENT_AGREEMENT(20, "签署意向协议", WorkflowSubStageStatusEnum.SIGN_INTENT_AGREEMENT_60, "intentAgreementServiceImpl",6),
|
||||
STORE_EXPERIENCE(25, "门店体验", WorkflowSubStageStatusEnum.STORE_EXPERIENCE_85, "trainingExperienceServiceImpl",9),
|
||||
SECOND_INTERVIEWS(30, "二审面试", WorkflowSubStageStatusEnum.SECOND_INTERVIEWS_100, "lineInterviewServiceImpl",10);
|
||||
|
||||
|
||||
@@ -13,21 +13,21 @@ import java.util.Objects;
|
||||
*/
|
||||
public enum ShopSubStageEnum {
|
||||
|
||||
SHOP_STAGE_1(ShopStageEnum.SHOP_STAGE_1, 10, "选址", 3),
|
||||
SHOP_STAGE_2(ShopStageEnum.SHOP_STAGE_1, 20, "上传租赁合同", 2),
|
||||
SHOP_STAGE_3(ShopStageEnum.SHOP_STAGE_2, 30, "系统建店", 2),
|
||||
SHOP_STAGE_4(ShopStageEnum.SHOP_STAGE_2, 40, "证照办理", 2),
|
||||
SHOP_STAGE_5(ShopStageEnum.SHOP_STAGE_2, 50, "员工招聘", 2),
|
||||
SHOP_STAGE_6(ShopStageEnum.SHOP_STAGE_2, 60, "加盟商/员工培训", 2),
|
||||
SHOP_STAGE_7(ShopStageEnum.SHOP_STAGE_2, 70, "缴纳加盟费/保证金", 2),
|
||||
SHOP_STAGE_8(ShopStageEnum.SHOP_STAGE_2, 80, "加盟合同签约", 2),
|
||||
SHOP_STAGE_9(ShopStageEnum.SHOP_STAGE_2, 90, "设计阶段", 2),
|
||||
SHOP_STAGE_10(ShopStageEnum.SHOP_STAGE_2, 100, "装修款", 2),
|
||||
SHOP_STAGE_11(ShopStageEnum.SHOP_STAGE_2, 110, "施工阶段", 2),
|
||||
SHOP_STAGE_12(ShopStageEnum.SHOP_STAGE_2, 120, "三方验收", 2),
|
||||
SHOP_STAGE_13(ShopStageEnum.SHOP_STAGE_2, 130, "视觉验收", 2),
|
||||
SHOP_STAGE_14(ShopStageEnum.SHOP_STAGE_2, 140, "开业运营方案", 2),
|
||||
SHOP_STAGE_15(ShopStageEnum.SHOP_STAGE_2, 150, "首批订货清单", 2),
|
||||
SHOP_STAGE_1(ShopStageEnum.SHOP_STAGE_1, 10, "选址", 12),
|
||||
SHOP_STAGE_2(ShopStageEnum.SHOP_STAGE_1, 20, "上传租赁合同", 14),
|
||||
SHOP_STAGE_3(ShopStageEnum.SHOP_STAGE_2, 30, "系统建店", 19),
|
||||
SHOP_STAGE_4(ShopStageEnum.SHOP_STAGE_2, 40, "证照办理", 24),
|
||||
SHOP_STAGE_5(ShopStageEnum.SHOP_STAGE_2, 50, "员工招聘", 23),
|
||||
SHOP_STAGE_6(ShopStageEnum.SHOP_STAGE_2, 60, "加盟商/员工培训", 30),
|
||||
SHOP_STAGE_7(ShopStageEnum.SHOP_STAGE_2, 70, "缴纳加盟费/保证金", 1),
|
||||
SHOP_STAGE_8(ShopStageEnum.SHOP_STAGE_2, 80, "加盟合同签约", 4),
|
||||
SHOP_STAGE_9(ShopStageEnum.SHOP_STAGE_2, 90, "设计阶段", 24),
|
||||
SHOP_STAGE_10(ShopStageEnum.SHOP_STAGE_2, 100, "装修款", 25),
|
||||
SHOP_STAGE_11(ShopStageEnum.SHOP_STAGE_2, 110, "施工阶段", 29),
|
||||
SHOP_STAGE_12(ShopStageEnum.SHOP_STAGE_2, 120, "三方验收", 26),
|
||||
SHOP_STAGE_13(ShopStageEnum.SHOP_STAGE_2, 130, "视觉验收", 26),
|
||||
SHOP_STAGE_14(ShopStageEnum.SHOP_STAGE_2, 140, "开业运营方案", 23),
|
||||
SHOP_STAGE_15(ShopStageEnum.SHOP_STAGE_2, 150, "首批订货清单", 20),
|
||||
;
|
||||
|
||||
//阶段
|
||||
|
||||
@@ -0,0 +1,55 @@
|
||||
package com.cool.store.enums.prepare.newStore;
|
||||
|
||||
import com.cool.store.enums.ThirdRegionTypeEnum;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 社区类型
|
||||
*/
|
||||
public enum BusinessDistrictEnum {
|
||||
|
||||
COMMUNITY(10,"社区型"),
|
||||
COMMERCIAL_STREET(20,"商业街边型"),
|
||||
SCHOOL(30,"学校型"),
|
||||
CBD_OFFICE(40,"CBD/办公型"),
|
||||
HOSPITAL(60,"医院型"),
|
||||
VEGETABLE_MARKET(70,"-菜场型"),
|
||||
|
||||
|
||||
;
|
||||
|
||||
private Integer code;
|
||||
private String desc;
|
||||
|
||||
BusinessDistrictEnum(Integer code, String desc) {
|
||||
this.code = code;
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getDesc() {
|
||||
return desc;
|
||||
}
|
||||
|
||||
public void setDesc(String desc) {
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public static final Map<Integer, BusinessDistrictEnum> map
|
||||
= Arrays.stream(values()).collect(Collectors.toMap(BusinessDistrictEnum::getCode, Function.identity()));
|
||||
|
||||
public static BusinessDistrictEnum getByCode(Integer code) {
|
||||
return map.get(code);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
package com.cool.store.enums.prepare.newStore;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 线下竞争对手
|
||||
*/
|
||||
public enum OfflineCompetitorEnum {
|
||||
BRAND_FRUIT(10,"品牌水果店"),
|
||||
COUPLES_FRUIT(20,"夫妻水果店"),
|
||||
VEGETABLE_MARKET(30,"菜场店"),
|
||||
BIG_BUSINESS(40,"大商超"),
|
||||
FRESH_FOOD(50,"生鲜店"),
|
||||
NONE(60,"无"),
|
||||
|
||||
|
||||
;
|
||||
|
||||
private Integer code;
|
||||
private String desc;
|
||||
|
||||
OfflineCompetitorEnum(Integer code, String desc) {
|
||||
this.code = code;
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getDesc() {
|
||||
return desc;
|
||||
}
|
||||
|
||||
public void setDesc(String desc) {
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public static final Map<Integer, OfflineCompetitorEnum> map
|
||||
= Arrays.stream(values()).collect(Collectors.toMap(OfflineCompetitorEnum::getCode, Function.identity()));
|
||||
|
||||
public static OfflineCompetitorEnum getByCode(Integer code) {
|
||||
return map.get(code);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
package com.cool.store.enums.prepare.newStore;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
public enum PassengerFlowEnum {
|
||||
BELOW_1000(0,"1000以下"),
|
||||
TO_1000_10000(1,"1000-1万"),
|
||||
MORE_THAN_10000(2,"1万以上"),
|
||||
|
||||
|
||||
|
||||
;
|
||||
|
||||
private Integer code;
|
||||
private String desc;
|
||||
|
||||
PassengerFlowEnum(Integer code, String desc) {
|
||||
this.code = code;
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getDesc() {
|
||||
return desc;
|
||||
}
|
||||
|
||||
public void setDesc(String desc) {
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public static final Map<Integer, PassengerFlowEnum> map
|
||||
= Arrays.stream(values()).collect(Collectors.toMap(PassengerFlowEnum::getCode, Function.identity()));
|
||||
|
||||
public static PassengerFlowEnum getByCode(Integer code) {
|
||||
return map.get(code);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
package com.cool.store.enums.prepare.newStore;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Map;
|
||||
import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
public enum StoreOperatorEnum {
|
||||
FRANCHISEE(10,"加盟商"),
|
||||
STORE_MANAGER(20,"店长"),
|
||||
|
||||
|
||||
|
||||
;
|
||||
|
||||
private Integer code;
|
||||
private String desc;
|
||||
|
||||
StoreOperatorEnum(Integer code, String desc) {
|
||||
this.code = code;
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getDesc() {
|
||||
return desc;
|
||||
}
|
||||
|
||||
public void setDesc(String desc) {
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public static final Map<Integer, StoreOperatorEnum> map
|
||||
= Arrays.stream(values()).collect(Collectors.toMap(StoreOperatorEnum::getCode, Function.identity()));
|
||||
|
||||
public static StoreOperatorEnum getByCode(Integer code) {
|
||||
return map.get(code);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,93 @@
|
||||
package com.cool.store.utils;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStreamReader;
|
||||
import java.net.HttpURLConnection;
|
||||
import java.net.URL;
|
||||
|
||||
/**
|
||||
* @author zhangchenbiao
|
||||
* @FileName: GeoMapUtil
|
||||
* @Description:
|
||||
* @date 2024-04-23 11:26
|
||||
*/
|
||||
public class GeoMapUtil {
|
||||
|
||||
private static final String AMAP_API_URL = "https://restapi.amap.com/v3/geocode/regeo";
|
||||
private static final String API_KEY = "bdf789122b56e8fd3d4a4410800382a6"; // 替换为你的高德地图API密钥
|
||||
|
||||
public static void main(String[] args) {
|
||||
AddressInfo addressInfo = reverseGeoCoding("30.41875", "120.2985");
|
||||
System.out.println(JSONObject.toJSONString(addressInfo));
|
||||
System.out.println(JSONObject.toJSONString(reverseGeoCoding("30.41", "120.29")));
|
||||
System.out.println(JSONObject.toJSONString(reverseGeoCoding("30.42", "120.30")));
|
||||
System.out.println(JSONObject.toJSONString(reverseGeoCoding("30.4", "120.2")));
|
||||
System.out.println(JSONObject.toJSONString(reverseGeoCoding("30.5", "120.3")));
|
||||
System.out.println(JSONObject.toJSONString(reverseGeoCoding("30.419", "120.299")));
|
||||
}
|
||||
|
||||
public static AddressInfo reverseGeoCoding(String latitude, String longitude) {
|
||||
BufferedReader in = null;
|
||||
try {
|
||||
URL url = new URL(AMAP_API_URL + "?location=" + longitude + "," + latitude + "&output=json&key=" + API_KEY);
|
||||
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
|
||||
connection.setRequestMethod("GET");
|
||||
connection.connect();
|
||||
if(connection.getResponseCode() == HttpURLConnection.HTTP_OK){
|
||||
in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
|
||||
String inputLine;
|
||||
StringBuilder content = new StringBuilder();
|
||||
while ((inputLine = in.readLine()) != null) {
|
||||
content.append(inputLine);
|
||||
}
|
||||
JSONObject jsonObject = JSONObject.parseObject(content.toString());
|
||||
// 提取并构建AddressInfo对象
|
||||
AddressInfo addressInfo = extractAddressInfo(jsonObject.getJSONObject("regeocode"));
|
||||
return addressInfo;
|
||||
}
|
||||
} catch (IOException e) {
|
||||
System.out.println("Error occurred while making the request: " + e.getMessage());
|
||||
}finally {
|
||||
if (in != null) {
|
||||
try {
|
||||
in.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private static AddressInfo extractAddressInfo(JSONObject geoJson) {
|
||||
JSONObject addressComponent = geoJson.getJSONObject("addressComponent");
|
||||
// 根据实际响应结构解析省市区街道信息,此处仅为示例
|
||||
String province = (String) addressComponent.get("province");
|
||||
String city = (String) addressComponent.get("city");
|
||||
String district = (String) addressComponent.get("district");
|
||||
String township = (String) addressComponent.get("township");
|
||||
String address = geoJson.getString("formatted_address");
|
||||
return new AddressInfo(province, city, district, township, address);
|
||||
}
|
||||
|
||||
@Data
|
||||
public static class AddressInfo {
|
||||
private String province;
|
||||
private String city;
|
||||
private String district;
|
||||
private String township;
|
||||
private String address;
|
||||
|
||||
public AddressInfo(String province, String city, String district, String township, String address) {
|
||||
this.province = province;
|
||||
this.city = city;
|
||||
this.district = district;
|
||||
this.township = township;
|
||||
this.address = address;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user