| | |
| | | <project version="4"> |
| | | <component name="CompilerConfiguration"> |
| | | <annotationProcessing> |
| | | <profile default="true" name="Default" enabled="true" /> |
| | | <profile name="Maven default annotation processors profile" enabled="true"> |
| | | <sourceOutputDir name="target/generated-sources/annotations" /> |
| | | <sourceTestOutputDir name="target/generated-test-sources/test-annotations" /> |
| | |
| | | # å¼åç¯å¢é
ç½® |
| | | NODE_ENV = 'development' |
| | | #VUE_APP_API_URL = 'http://192.168.1.54:10010' |
| | | VUE_APP_API_URL = 'https://jinkuai.832smartfarm.com/jinkuai_admin' |
| | | VUE_APP_API_URL = 'http://localhost:10010' |
| | |
| | | "integrity": "sha1-/q7SVZc9LndVW4PbwIhRpsY1IPo=", |
| | | "dev": true |
| | | }, |
| | | "ansi-styles": { |
| | | "version": "4.3.0", |
| | | "resolved": "https://registry.npmmirror.com/ansi-styles/-/ansi-styles-4.3.0.tgz", |
| | | "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "color-convert": "^2.0.1" |
| | | } |
| | | }, |
| | | "chalk": { |
| | | "version": "4.1.2", |
| | | "resolved": "https://registry.npmmirror.com/chalk/-/chalk-4.1.2.tgz", |
| | | "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "ansi-styles": "^4.1.0", |
| | | "supports-color": "^7.1.0" |
| | | } |
| | | }, |
| | | "color-convert": { |
| | | "version": "2.0.1", |
| | | "resolved": "https://registry.npmmirror.com/color-convert/-/color-convert-2.0.1.tgz", |
| | | "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "color-name": "~1.1.4" |
| | | } |
| | | }, |
| | | "color-name": { |
| | | "version": "1.1.4", |
| | | "resolved": "https://registry.npmmirror.com/color-name/-/color-name-1.1.4.tgz", |
| | | "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", |
| | | "dev": true, |
| | | "optional": true |
| | | }, |
| | | "has-flag": { |
| | | "version": "4.0.0", |
| | | "resolved": "https://registry.npmmirror.com/has-flag/-/has-flag-4.0.0.tgz", |
| | | "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", |
| | | "dev": true, |
| | | "optional": true |
| | | }, |
| | | "loader-utils": { |
| | | "version": "2.0.4", |
| | | "resolved": "https://registry.npmmirror.com/loader-utils/-/loader-utils-2.0.4.tgz", |
| | | "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "big.js": "^5.2.2", |
| | | "emojis-list": "^3.0.0", |
| | | "json5": "^2.1.2" |
| | | } |
| | | }, |
| | | "ssri": { |
| | | "version": "8.0.1", |
| | | "resolved": "https://registry.npm.taobao.org/ssri/download/ssri-8.0.1.tgz?cache=0&sync_timestamp=1617826515595&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fssri%2Fdownload%2Fssri-8.0.1.tgz", |
| | |
| | | "dev": true, |
| | | "requires": { |
| | | "minipass": "^3.1.1" |
| | | } |
| | | }, |
| | | "supports-color": { |
| | | "version": "7.2.0", |
| | | "resolved": "https://registry.npmmirror.com/supports-color/-/supports-color-7.2.0.tgz", |
| | | "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "has-flag": "^4.0.0" |
| | | } |
| | | }, |
| | | "vue-loader-v16": { |
| | | "version": "npm:vue-loader@16.8.3", |
| | | "resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-16.8.3.tgz", |
| | | "integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "chalk": "^4.1.0", |
| | | "hash-sum": "^2.0.0", |
| | | "loader-utils": "^2.0.0" |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | } |
| | | }, |
| | | "vue-loader-v16": { |
| | | "version": "npm:vue-loader@16.8.3", |
| | | "resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-16.8.3.tgz", |
| | | "integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "chalk": "^4.1.0", |
| | | "hash-sum": "^2.0.0", |
| | | "loader-utils": "^2.0.0" |
| | | }, |
| | | "dependencies": { |
| | | "ansi-styles": { |
| | | "version": "4.3.0", |
| | | "resolved": "https://registry.npmmirror.com/ansi-styles/-/ansi-styles-4.3.0.tgz", |
| | | "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "color-convert": "^2.0.1" |
| | | } |
| | | }, |
| | | "chalk": { |
| | | "version": "4.1.2", |
| | | "resolved": "https://registry.npmmirror.com/chalk/-/chalk-4.1.2.tgz", |
| | | "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "ansi-styles": "^4.1.0", |
| | | "supports-color": "^7.1.0" |
| | | } |
| | | }, |
| | | "color-convert": { |
| | | "version": "2.0.1", |
| | | "resolved": "https://registry.npmmirror.com/color-convert/-/color-convert-2.0.1.tgz", |
| | | "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "color-name": "~1.1.4" |
| | | } |
| | | }, |
| | | "color-name": { |
| | | "version": "1.1.4", |
| | | "resolved": "https://registry.npmmirror.com/color-name/-/color-name-1.1.4.tgz", |
| | | "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", |
| | | "dev": true, |
| | | "optional": true |
| | | }, |
| | | "has-flag": { |
| | | "version": "4.0.0", |
| | | "resolved": "https://registry.npmmirror.com/has-flag/-/has-flag-4.0.0.tgz", |
| | | "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", |
| | | "dev": true, |
| | | "optional": true |
| | | }, |
| | | "loader-utils": { |
| | | "version": "2.0.4", |
| | | "resolved": "https://registry.npmmirror.com/loader-utils/-/loader-utils-2.0.4.tgz", |
| | | "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "big.js": "^5.2.2", |
| | | "emojis-list": "^3.0.0", |
| | | "json5": "^2.1.2" |
| | | } |
| | | }, |
| | | "supports-color": { |
| | | "version": "7.2.0", |
| | | "resolved": "https://registry.npmmirror.com/supports-color/-/supports-color-7.2.0.tgz", |
| | | "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", |
| | | "dev": true, |
| | | "optional": true, |
| | | "requires": { |
| | | "has-flag": "^4.0.0" |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | "vue-router": { |
| | | "version": "3.5.1", |
| | | "resolved": "https://registry.nlark.com/vue-router/download/vue-router-3.5.1.tgz?cache=0&sync_timestamp=1620899536020&other_urls=https%3A%2F%2Fregistry.nlark.com%2Fvue-router%2Fdownload%2Fvue-router-3.5.1.tgz", |
| | |
| | | public static final String AUTO_DISPATCH_DISTANCE ="AUTO_DISPATCH_DISTANCE" ; |
| | | public static final String AUTO_CONFIRM ="AUTO_CONFIRM" ; |
| | | public static final String AUTO_CANCEL_WAIT_PAY ="AUTO_CANCEL_WAIT_PAY" ; |
| | | |
| | | public static final String UTF = "UTF-8"; |
| | | public static final String QYWX = "QYWX"; |
| | | public static final Integer ONE = 1; |
| | | public static final Integer TWO = 2; |
| | |
| | | public static final String MEMBER_FILES = "MEMBER_FILES"; |
| | | public static final String CATEGORY_FILES = "CATEGORY_FILES"; |
| | | public static final String ORDERS_FILES = "ORDERS_FILES"; |
| | | public static final String ZBOM_PARAM ="ZBOM_PARAM" ; |
| | | public static final String ZBOM_UK_ERROR_URL ="ZBOM_UK_ERROR_URL" ; |
| | | public static final String ZBOM_TICKET_LOGIN_URL ="ZBOM_TICKET_LOGIN_URL" ; |
| | | public static boolean WORKORDER_SHE_EMAIL_SENDING = false; |
| | | public static boolean DEALING_COMPANY_SYNC = false ; |
| | | public static boolean DEALING_MEMBER_SYNC = false ; |
| | |
| | | public static final String FAIL = "FAIL"; |
| | | public static final String CANCELLED = "CANCELLED"; |
| | | |
| | | public interface ZbomConst{ |
| | | String TICKET_LOGIN = "https://sso.zbom.com/esc-idm/api/v1/getUserInfo"; |
| | | String TICKET_LOGIN_TEST = "http://testsso.zhibang.com:8080/esc-idm/api/v1/getUserInfo"; |
| | | } |
| | | |
| | | |
| | | public interface uploadType{ |
| | | String blob = "blob"; |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.dao.business.dto; |
| | | |
| | | |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | public class LoginRequestNewParam { |
| | | private String appid;// 1 O ææºå·ç |
| | | private String user_name;// 1 M ç¨æ·åId |
| | | private String rediUrl;// 1 M ç»å½è´¦æ·ï¼ |
| | | private String account_no ;//String è´¦å· |
| | | private String scode;//String ç¨æ·å¯¹åºå çåScode |
| | | private List<RoleRequestParam> roles;// 1 M ç»å½å¯ç |
| | | |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.dao.business.dto; |
| | | |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | public class RoleRequestParam { |
| | | private String code;//è§è²ç¼ç |
| | | private String name;// è§è²åç§° |
| | | private String id;//ç¼ç ï¼ |
| | | |
| | | } |
| | |
| | | spring: |
| | | # æ°æ®æºé
ç½® |
| | | datasource: |
| | | url: jdbc:mysql://b66cc1a382964a6a9d46a522f2dfe672in01.internal.cn-south-1.mysql.rds.myhuaweicloud.com:3306/jinkuai?useUnicode=true&characterEncoding=utf8&serverTimezone=Asia/Shanghai |
| | | url: jdbc:mysql://192.168.0.211:3306/zbom_dianjiang?useUnicode=true&characterEncoding=utf8&serverTimezone=Asia/Shanghai |
| | | username: root |
| | | password: Jinkuai!@#$%^ |
| | | password: Doumee@168 |
| | | driver-class-name: com.mysql.cj.jdbc.Driver |
| | | type: com.alibaba.druid.pool.DruidDataSource |
| | | redis: |
| | |
| | | ApplicationContext context = SpringApplication.run(DJWebApplication.class); |
| | | context.getEnvironment(); |
| | | } |
| | | |
| | | // @Override |
| | | // protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) { |
| | | // return builder.sources(JKWebApplication.class) ; |
| | | // } |
| | | } |
| ¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.doumee.api.web; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.doumee.api.BaseController; |
| | | import com.doumee.biz.system.SystemDictDataBiz; |
| | | import com.doumee.core.annotation.excel.ExcelExporter; |
| | | import com.doumee.core.annotation.pr.PreventRepeat; |
| | | import com.doumee.core.constants.Constants; |
| | | import com.doumee.core.model.ApiResponse; |
| | | import com.doumee.core.model.LoginUserInfo; |
| | | import com.doumee.core.model.PageData; |
| | | import com.doumee.core.model.PageWrap; |
| | | import com.doumee.core.utils.HttpsUtil; |
| | | import com.doumee.dao.business.dto.LoginRequestNewParam; |
| | | import com.doumee.dao.business.model.Category; |
| | | import com.doumee.dao.system.model.SystemJob; |
| | | import com.doumee.service.business.CategoryService; |
| | | import com.sun.deploy.net.HttpUtils; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.apache.shiro.authz.annotation.RequiresPermissions; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.servlet.ModelAndView; |
| | | |
| | | import javax.servlet.http.HttpServletRequest; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLEncoder; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.UUID; |
| | | |
| | | /** |
| | | * @author æ±è¹è¹ |
| | | * @date 2025/07/09 12:00 |
| | | */ |
| | | @Api(tags = "webç»å½ç¸å
³æ¥å£") |
| | | @RestController |
| | | @RequestMapping("/web") |
| | | @Slf4j |
| | | public class LoginController extends BaseController { |
| | | |
| | | @Autowired |
| | | private CategoryService categoryService; |
| | | @Autowired |
| | | private SystemDictDataBiz systemDictDataBiz; |
| | | |
| | | @ApiOperation("UKåç¹ç»å½") |
| | | @RequestMapping("/ukLogin") |
| | | public void ukLogin(String tick, Object obj, HttpServletRequest request, HttpServletResponse response) throws Exception { |
| | | LoginRequestNewParam requestParam = new LoginRequestNewParam(); |
| | | // UK_ERROR_URL = "http://u.zhibang.com/sso/web/token/error"; |
| | | String errorUrl =systemDictDataBiz.queryByCode(Constants.ZBOM_PARAM,Constants.ZBOM_UK_ERROR_URL).getCode(); |
| | | try { |
| | | log.error("请æ±åæ°TICKæåå§===========ï¼" + tick); |
| | | JSONObject urlParams = new JSONObject(); |
| | | log.info("请æ±åæ°ï¼" + JSON.toJSONString(urlParams)); |
| | | //TICKET_LOGIN_TEST = "http://testsso.zhibang.com:8080/esc-idm/api/v1/getUserInfo"; |
| | | //TICKET_LOGIN = "https://sso.zbom.com/esc-idm/api/v1/getUserInfo"; |
| | | String url = systemDictDataBiz.queryByCode(Constants.ZBOM_PARAM,Constants.ZBOM_TICKET_LOGIN_URL).getCode() + "?tick=" + URLEncoder.encode(tick,Constants.UTF); |
| | | String post = HttpsUtil.get(url,true); |
| | | log.info("è¿ååæ°ï¼" + post); |
| | | JSONObject json = JSONObject.parseObject(post); |
| | | if (StringUtils.equals(json.getString("code"), "0")) { |
| | | JSONObject userInfo = json.getJSONObject("data"); |
| | | requestParam = JSONObject.toJavaObject(userInfo, LoginRequestNewParam.class); |
| | | } else { |
| | | log.error("æ¡ä¾åºç³»ç»åç¹ç»å½å¤±è´¥ é误åå è·åtick失败" + json.getString("message")); |
| | | response.sendRedirect(errorUrl + "?title=" + enCode("ç»éé误") + "&msg="+ enCode(json.getString("message"))); |
| | | return; |
| | | } |
| | | } catch (Exception e) { |
| | | log.error("ticketæ¥å£è¯·æ±é误ï¼" + e.getMessage()); |
| | | response.sendRedirect(errorUrl + "?title=" + enCode("ç»éé误") + "&msg=" + enCode("ç³»ç»ç¹å¿ï¼è¯·ç¨åéè¯~")); |
| | | return; |
| | | } |
| | | requestParam.setRediUrl("http://localhost:10087/#/login"); |
| | | String token = UUID.randomUUID().toString()+"_doumee"; |
| | | response.sendRedirect(requestParam.getRediUrl()+"?token="+token); |
| | | } |
| | | private String enCode(String string) { |
| | | // TODO Auto-generated method stub |
| | | String str = ""; |
| | | try { |
| | | str = java.net.URLEncoder.encode(string, "utf-8"); |
| | | } catch (UnsupportedEncodingException e) { |
| | | // TODO Auto-generated catch block |
| | | e.printStackTrace(); |
| | | } |
| | | return str; |
| | | } |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | spring: |
| | | profiles: |
| | | active: pro |
| | | active: dev |
| | | # JSONè¿åé
ç½® |
| | | jackson: |
| | | # é»è®¤æ¶åº |