ソースを参照

添加上传文件

qiubo 4 年 前
コミット
5f0acf6e6a

+ 150 - 0
forest-admin/admin-server/src/test/java/com/hwrj/cloud/admin/AmapEntity.java

@@ -0,0 +1,150 @@
+package com.hwrj.cloud.admin;
+
+import java.io.Serializable;
+
+public class AmapEntity implements Serializable {
+    private String formattedAddress;
+    private String country;
+    private String province;
+    private String citycode;
+    private String city;
+    private String district;
+    private String township;
+    private String neighborhood;
+    private String building;
+    private String name;
+    private String type;
+    private String adcode;
+    private String street;
+    private String number;
+    private String location;
+    private String level;
+
+    public String getFormattedAddress() {
+        return formattedAddress;
+    }
+
+    public void setFormattedAddress(String formattedAddress) {
+        this.formattedAddress = formattedAddress;
+    }
+
+    public String getCountry() {
+        return country;
+    }
+
+    public void setCountry(String country) {
+        this.country = country;
+    }
+
+    public String getProvince() {
+        return province;
+    }
+
+    public void setProvince(String province) {
+        this.province = province;
+    }
+
+    public String getCitycode() {
+        return citycode;
+    }
+
+    public void setCitycode(String citycode) {
+        this.citycode = citycode;
+    }
+
+    public String getCity() {
+        return city;
+    }
+
+    public void setCity(String city) {
+        this.city = city;
+    }
+
+    public String getDistrict() {
+        return district;
+    }
+
+    public void setDistrict(String district) {
+        this.district = district;
+    }
+
+    public String getTownship() {
+        return township;
+    }
+
+    public void setTownship(String township) {
+        this.township = township;
+    }
+
+    public String getNeighborhood() {
+        return neighborhood;
+    }
+
+    public void setNeighborhood(String neighborhood) {
+        this.neighborhood = neighborhood;
+    }
+
+    public String getBuilding() {
+        return building;
+    }
+
+    public void setBuilding(String building) {
+        this.building = building;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getType() {
+        return type;
+    }
+
+    public void setType(String type) {
+        this.type = type;
+    }
+
+    public String getAdcode() {
+        return adcode;
+    }
+
+    public void setAdcode(String adcode) {
+        this.adcode = adcode;
+    }
+
+    public String getStreet() {
+        return street;
+    }
+
+    public void setStreet(String street) {
+        this.street = street;
+    }
+
+    public String getNumber() {
+        return number;
+    }
+
+    public void setNumber(String number) {
+        this.number = number;
+    }
+
+    public String getLocation() {
+        return location;
+    }
+
+    public void setLocation(String location) {
+        this.location = location;
+    }
+
+    public String getLevel() {
+        return level;
+    }
+
+    public void setLevel(String level) {
+        this.level = level;
+    }
+}

+ 187 - 0
forest-admin/admin-server/src/test/java/com/hwrj/cloud/admin/FastCompanyInfo.java

@@ -0,0 +1,187 @@
+package com.hwrj.cloud.admin;
+
+
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
+import com.hwrj.cloud.admin.dao.PmsProductExcelDao;
+import com.hwrj.cloud.admin.dto.param.PmsProductExcel;
+import com.hwrj.cloud.admin.dto.param.PmsProductParam;
+import com.hwrj.cloud.admin.excelEntity.UmsCompanyInfoExcel;
+import com.hwrj.cloud.admin.excelEntity.UmsMemberOriginExcel;
+import com.hwrj.cloud.admin.listener.ImportExcelEventListener;
+import com.hwrj.cloud.admin.mapper.PmsProductMapper;
+import com.hwrj.cloud.admin.mapper.UmsCompanyFileMapper;
+import com.hwrj.cloud.admin.mapper.UmsCompanyInfoMapper;
+import com.hwrj.cloud.admin.mapper.UmsMemberOriginMapper;
+import com.hwrj.cloud.admin.model.*;
+import com.hwrj.cloud.admin.service.PmsProductService;
+import com.hwrj.cloud.admin.service.UmsCompanyService;
+import com.hwrj.cloud.admin.service.UmsMemberOriginService;
+import com.hwrj.cloud.admin.util.EasyExcelUtil;
+import com.hwrj.cloud.admin.util.OrderNo;
+import com.hwrj.cloud.admin.util.UploadFileUtil;
+import com.hwrj.cloud.common.exception.GlobalException;
+import com.hwrj.cloud.common.util.HttpUtils;
+import lombok.extern.slf4j.Slf4j;
+import net.bytebuddy.asm.Advice;
+import org.apache.http.entity.ContentType;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.boot.test.context.SpringBootTest;
+import org.springframework.mock.web.MockMultipartFile;
+import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
+import org.springframework.util.StringUtils;
+import org.springframework.web.multipart.MultipartFile;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.math.BigDecimal;
+import java.util.*;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+@Slf4j
+@RunWith(SpringJUnit4ClassRunner.class)
+@SpringBootTest(classes = AdminApplication.class)
+public class FastCompanyInfo {
+
+
+
+private int i = 1;
+
+    @Value("${qiniu.path}")
+    private String url;
+
+    @Autowired
+    UmsCompanyInfoMapper umsCompanyInfoMapper;
+    @Autowired
+    UmsMemberOriginMapper umsMemberOriginMapper;
+    @Test
+    public void readFile(){
+       UmsCompanyInfoExample example = new UmsCompanyInfoExample();
+        List<UmsCompanyInfo> companyInfos = umsCompanyInfoMapper.selectByExample(example);
+        for (UmsCompanyInfo ums: companyInfos) {
+            UmsCompanyInfo u = new UmsCompanyInfo();
+            String cityId = ums.getCityId();
+            String countyId = ums.getCountyId();
+            String detailAddress = ums.getDetailAddress();
+            LagLatEntity lagLat = getLagLat(cityId, countyId, detailAddress);
+            if (lagLat == null || lagLat.getLag()==null){
+                System.out.println("获取对应的坐标失败"+cityId+"|"+countyId+"|"+detailAddress);
+            }else {
+                u.setId(ums.getId());
+                u.setLatitude(lagLat.getLat());
+                u.setLongitude(lagLat.getLag());
+                umsCompanyInfoMapper.updateByPrimaryKeySelective(u);
+                System.out.println(JSONObject.toJSONString(u));
+            }
+        }
+    }
+
+
+    public LagLatEntity getLagLat(String cityName,String countyName,String detail){
+        LagLatEntity la = new LagLatEntity();
+        if (StringUtils.isEmpty(countyName)||StringUtils.isEmpty(countyName)){
+            return null;
+        }
+
+        if (StringUtils.isEmpty(detail)){
+
+            AmapEntity county = getAddressDetail(cityName, countyName);
+            if (county != null){
+                String[] split = county.getLocation().split(",");
+                la.setLag(split[0]);
+                la.setLat(split[1]);
+            }else {
+                AmapEntity city = getAddressDetail(cityName, cityName);
+                if (city != null){
+                    String[] split = city.getLocation().split(",");
+                    la.setLag(split[0]);
+                    la.setLat(split[1]);
+                }else {
+                    return null;
+                }
+            }
+
+        }else {
+            AmapEntity addressDetail = getAddressDetail(cityName, detail);
+            if (addressDetail != null){
+                String[] split = addressDetail.getLocation().split(",");
+                la.setLag(split[0]);
+                la.setLat(split[1]);
+            }else {
+                AmapEntity county = getAddressDetail(cityName, countyName);
+                if (county != null){
+                    String[] split = county.getLocation().split(",");
+                    la.setLag(split[0]);
+                    la.setLat(split[1]);
+                }else {
+                    AmapEntity city = getAddressDetail(cityName, cityName);
+                    if (city != null){
+                        String[] split = city.getLocation().split(",");
+                        la.setLag(split[0]);
+                        la.setLat(split[1]);
+                    }else {
+                        return null;
+                    }
+                }
+            }
+        }
+        return la;
+    }
+
+
+    public AmapEntity getAddressDetail(String cityName, String key) {
+        if (StringUtils.isEmpty(cityName)){
+            return null;
+        }
+        if (StringUtils.isEmpty(key)){
+            return null;
+        }
+        String s = sendAddress(cityName, key);
+        log.info("返回地址信息"+s);
+        JSONObject object = JSON.parseObject(s);
+
+        String status = object.getString("status");
+        if ("1".equals(status)){
+            String count = object.getString("count");
+            if (Integer.valueOf(count)<1){
+                return null;
+            }
+            JSONArray weatherArray = JSON.parseArray(object.getString("geocodes"));
+            for (Object json :weatherArray) {
+                AmapEntity amapEntity = JSONObject.parseObject(JSONObject.toJSONString(json), AmapEntity.class);
+                return amapEntity;
+            }
+        }
+
+
+
+        return null;
+    }
+
+    public String sendAddress(String city, String key) {
+        String lbsDevKey = "52277a894c1855d8917634177809169a";
+        String addUrl ="https://restapi.amap.com/v3/geocode/geo";
+        Map<String, String> queryParas = new HashMap<String, String>();
+        queryParas.put("address", key);
+        queryParas.put("key", lbsDevKey);
+        queryParas.put("city", city);
+        String weatherInfo = null;
+        try {
+            weatherInfo = HttpUtils.get(addUrl, queryParas);
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+        return weatherInfo;
+    }
+
+
+
+
+}

+ 22 - 0
forest-admin/admin-server/src/test/java/com/hwrj/cloud/admin/LagLatEntity.java

@@ -0,0 +1,22 @@
+package com.hwrj.cloud.admin;
+
+public class LagLatEntity {
+    private String lag;
+    private String lat;
+
+    public String getLag() {
+        return lag;
+    }
+
+    public void setLag(String lag) {
+        this.lag = lag;
+    }
+
+    public String getLat() {
+        return lat;
+    }
+
+    public void setLat(String lat) {
+        this.lat = lat;
+    }
+}

+ 4 - 0
forest-common/pom.xml

@@ -67,6 +67,10 @@
             <artifactId>fastjson</artifactId>
             <version>1.2.73</version>
         </dependency>
+        <dependency>
+            <groupId>org.apache.tomcat.embed</groupId>
+            <artifactId>tomcat-embed-core</artifactId>
+        </dependency>
 
     </dependencies>
 

+ 265 - 0
forest-common/src/main/java/com/hwrj/cloud/common/util/HttpUtils.java

@@ -0,0 +1,265 @@
+package com.hwrj.cloud.common.util;
+
+import javax.net.ssl.*;
+import javax.servlet.http.HttpServletRequest;
+import java.io.*;
+import java.net.HttpURLConnection;
+import java.net.URL;
+import java.net.URLEncoder;
+import java.security.KeyManagementException;
+import java.security.NoSuchAlgorithmException;
+import java.security.NoSuchProviderException;
+import java.security.cert.CertificateException;
+import java.security.cert.X509Certificate;
+import java.util.Map;
+
+public class HttpUtils {
+    private HttpUtils() {
+    }
+
+
+    /**
+     * https 域名校验
+     */
+    private static class TrustAnyHostnameVerifier implements HostnameVerifier {
+        public boolean verify(String hostname, SSLSession session) {
+            return true;
+        }
+    }
+
+    /**
+     * https 证书管理
+     */
+    private static class TrustAnyTrustManager implements X509TrustManager {
+        public X509Certificate[] getAcceptedIssuers() {
+            return null;
+        }
+
+        public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {
+        }
+
+        public void checkServerTrusted(X509Certificate[] chain, String authType) throws CertificateException {
+        }
+    }
+
+    private static final String GET = "GET";
+    private static final String POST = "POST";
+    private static String CHARSET = "UTF-8";
+
+    private static final SSLSocketFactory sslSocketFactory = initSSLSocketFactory();
+    private static final TrustAnyHostnameVerifier trustAnyHostnameVerifier = new TrustAnyHostnameVerifier();
+
+    private static SSLSocketFactory initSSLSocketFactory() {
+        try {
+            TrustManager[] tm = {new TrustAnyTrustManager()};
+            SSLContext sslContext = SSLContext.getInstance("TLS");    // ("TLS", "SunJSSE");
+            sslContext.init(null, tm, new java.security.SecureRandom());
+            return sslContext.getSocketFactory();
+        } catch (Exception e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public static void setCharSet(String charSet) {
+        if (StrKit.isBlank(charSet)) {
+            throw new IllegalArgumentException("charSet can not be blank.");
+        }
+        HttpUtils.CHARSET = charSet;
+    }
+
+    private static HttpURLConnection getHttpConnection(String url, String method, Map<String, String> headers) throws IOException, NoSuchAlgorithmException, NoSuchProviderException, KeyManagementException {
+        URL _url = new URL(url);
+        HttpURLConnection conn = (HttpURLConnection) _url.openConnection();
+        if (conn instanceof HttpsURLConnection) {
+            ((HttpsURLConnection) conn).setSSLSocketFactory(sslSocketFactory);
+            ((HttpsURLConnection) conn).setHostnameVerifier(trustAnyHostnameVerifier);
+        }
+
+        conn.setRequestMethod(method);
+        conn.setDoOutput(true);
+        conn.setDoInput(true);
+
+        conn.setConnectTimeout(19000);
+        conn.setReadTimeout(19000);
+
+        conn.setRequestProperty("Content-Type", "application/json");
+        conn.setRequestProperty("User-Agent", "Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1750.146 Safari/537.36");
+
+        if (headers != null && !headers.isEmpty()) {
+            for (Map.Entry<String, String> entry : headers.entrySet()) {
+                conn.setRequestProperty(entry.getKey(), entry.getValue());
+            }
+        }
+
+        return conn;
+    }
+
+    /**
+     * Send GET request
+     */
+    public static String get(String url, Map<String, String> queryParas, Map<String, String> headers) {
+        HttpURLConnection conn = null;
+        try {
+            conn = getHttpConnection(buildUrlWithQueryString(url, queryParas), GET, headers);
+            conn.connect();
+            return readResponseString(conn);
+        } catch (Exception e) {
+            throw new RuntimeException(e);
+        } finally {
+            if (conn != null) {
+                conn.disconnect();
+            }
+        }
+    }
+
+    public static String get(String url, Map<String, String> queryParas) {
+        return get(url, queryParas, null);
+    }
+
+    public static String get(String url) {
+        return get(url, null, null);
+    }
+
+    /**
+     * Send POST request
+     */
+    public static String post(String url, Map<String, String> queryParas, String data, Map<String, String> headers) {
+        HttpURLConnection conn = null;
+        try {
+            conn = getHttpConnection(buildUrlWithQueryString(url, queryParas), POST, headers);
+            conn.connect();
+
+            if (data != null) {
+                OutputStream out = conn.getOutputStream();
+                out.write(data.getBytes(CHARSET));
+                out.flush();
+                out.close();
+            }
+
+            return readResponseString(conn);
+        } catch (Exception e) {
+            throw new RuntimeException(e);
+        } finally {
+            if (conn != null) {
+                conn.disconnect();
+            }
+        }
+    }
+
+    public static String post(String url, Map<String, String> queryParas, String data) {
+        return post(url, queryParas, data, null);
+    }
+
+    public static String post(String url, String data, Map<String, String> headers) {
+        return post(url, null, data, headers);
+    }
+
+    public static String post(String url, String data) {
+        return post(url, null, data, null);
+    }
+
+    private static String readResponseString(HttpURLConnection conn) {
+        BufferedReader reader = null;
+        try {
+            StringBuilder ret;
+            reader = new BufferedReader(new InputStreamReader(conn.getInputStream(), CHARSET));
+            String line = reader.readLine();
+            if (line != null) {
+                ret = new StringBuilder();
+                ret.append(line);
+            } else {
+                return "";
+            }
+
+            while ((line = reader.readLine()) != null) {
+                ret.append('\n').append(line);
+            }
+            return ret.toString();
+        } catch (Exception e) {
+            throw new RuntimeException(e);
+        } finally {
+            if (reader != null) {
+                try {
+                    reader.close();
+                } catch (IOException e) {
+                    LogKit.error(e.getMessage(), e);
+                }
+            }
+        }
+    }
+
+    /**
+     * Build queryString of the url
+     */
+    private static String buildUrlWithQueryString(String url, Map<String, String> queryParas) {
+        if (queryParas == null || queryParas.isEmpty()) {
+            return url;
+        }
+
+        StringBuilder sb = new StringBuilder(url);
+        boolean isFirst;
+        if (url.indexOf('?') == -1) {
+            isFirst = true;
+            sb.append('?');
+        } else {
+            isFirst = false;
+        }
+
+        for (Map.Entry<String, String> entry : queryParas.entrySet()) {
+            if (isFirst) {
+                isFirst = false;
+            } else {
+                sb.append('&');
+            }
+
+            String key = entry.getKey();
+            String value = entry.getValue();
+            if (StrKit.notBlank(value)) {
+                try {
+                    value = URLEncoder.encode(value, CHARSET);
+                } catch (UnsupportedEncodingException e) {
+                    throw new RuntimeException(e);
+                }
+            }
+            sb.append(key).append('=').append(value);
+        }
+        return sb.toString();
+    }
+
+    public static String readData(HttpServletRequest request) {
+        BufferedReader br = null;
+        try {
+            StringBuilder ret;
+            br = request.getReader();
+
+            String line = br.readLine();
+            if (line != null) {
+                ret = new StringBuilder();
+                ret.append(line);
+            } else {
+                return "";
+            }
+
+            while ((line = br.readLine()) != null) {
+                ret.append('\n').append(line);
+            }
+
+            return ret.toString();
+        } catch (IOException e) {
+            throw new RuntimeException(e);
+        } finally {
+            if (br != null) {
+                try {
+                    br.close();
+                } catch (IOException e) {
+                    LogKit.error(e.getMessage(), e);
+                }
+            }
+        }
+    }
+
+    @Deprecated
+    public static String readIncommingRequestData(HttpServletRequest request) {
+        return readData(request);
+    }
+}

+ 74 - 0
forest-common/src/main/java/com/hwrj/cloud/common/util/LogKit.java

@@ -0,0 +1,74 @@
+package com.hwrj.cloud.common.util;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class LogKit {
+    private static class Holder {
+        private static Logger log = LoggerFactory.getLogger(LogKit.class);
+    }
+
+    /**
+     * 当通过 Constants.setLogFactory(...) 或者
+     * LogManager.me().setDefaultLogFacotyr(...)
+     * 指定默认日志工厂以后,重置一下内部 Log 对象,以便使内部日志实现与系统保持一致
+     */
+    public static void synchronizeLog() {
+        Holder.log = LoggerFactory.getLogger(LogKit.class);
+    }
+
+    /**
+     * Do nothing.
+     */
+    public static void logNothing(Throwable t) {
+
+    }
+
+    public static void debug(String message) {
+        Holder.log.debug(message);
+    }
+
+    public static void debug(String message, Throwable t) {
+        Holder.log.debug(message, t);
+    }
+
+    public static void info(String message) {
+        Holder.log.info(message);
+    }
+
+    public static void info(String message, Throwable t) {
+        Holder.log.info(message, t);
+    }
+
+    public static void warn(String message) {
+        Holder.log.warn(message);
+    }
+
+    public static void warn(String message, Throwable t) {
+        Holder.log.warn(message, t);
+    }
+
+    public static void error(String message) {
+        Holder.log.error(message);
+    }
+
+    public static void error(String message, Throwable t) {
+        Holder.log.error(message, t);
+    }
+
+    public static boolean isDebugEnabled() {
+        return Holder.log.isDebugEnabled();
+    }
+
+    public static boolean isInfoEnabled() {
+        return Holder.log.isInfoEnabled();
+    }
+
+    public static boolean isWarnEnabled() {
+        return Holder.log.isWarnEnabled();
+    }
+
+    public static boolean isErrorEnabled() {
+        return Holder.log.isErrorEnabled();
+    }
+}

+ 134 - 0
forest-common/src/main/java/com/hwrj/cloud/common/util/StrKit.java

@@ -0,0 +1,134 @@
+package com.hwrj.cloud.common.util;
+
+public class StrKit {
+    /**
+     * 首字母变小写
+     */
+    public static String firstCharToLowerCase(String str) {
+        char firstChar = str.charAt(0);
+        if (firstChar >= 'A' && firstChar <= 'Z') {
+            char[] arr = str.toCharArray();
+            arr[0] += ('a' - 'A');
+            return new String(arr);
+        }
+        return str;
+    }
+
+    /**
+     * 首字母变大写
+     */
+    public static String firstCharToUpperCase(String str) {
+        char firstChar = str.charAt(0);
+        if (firstChar >= 'a' && firstChar <= 'z') {
+            char[] arr = str.toCharArray();
+            arr[0] -= ('a' - 'A');
+            return new String(arr);
+        }
+        return str;
+    }
+
+    /**
+     * 字符串为 null 或者内部字符全部为 ' ' '\t' '\n' '\r' 这四类字符时返回 true
+     */
+    public static boolean isBlank(String str) {
+        if (str == null) {
+            return true;
+        }
+        int len = str.length();
+        if (len == 0) {
+            return true;
+        }
+        for (int i = 0; i < len; i++) {
+            switch (str.charAt(i)) {
+                case ' ':
+                case '\t':
+                case '\n':
+                case '\r':
+                    // case '\b':
+                    // case '\f':
+                    break;
+                default:
+                    return false;
+            }
+        }
+        return true;
+    }
+
+    public static boolean notBlank(String str) {
+        return !isBlank(str);
+    }
+
+    public static boolean notBlank(String... strings) {
+        if (strings == null || strings.length == 0) {
+            return false;
+        }
+        for (String str : strings) {
+            if (isBlank(str)) {
+                return false;
+            }
+        }
+        return true;
+    }
+
+    public static boolean notNull(Object... paras) {
+        if (paras == null) {
+            return false;
+        }
+        for (Object obj : paras) {
+            if (obj == null) {
+                return false;
+            }
+        }
+        return true;
+    }
+
+    public static String toCamelCase(String stringWithUnderline) {
+        if (stringWithUnderline.indexOf('_') == -1) {
+            return stringWithUnderline;
+        }
+
+        stringWithUnderline = stringWithUnderline.toLowerCase();
+        char[] fromArray = stringWithUnderline.toCharArray();
+        char[] toArray = new char[fromArray.length];
+        int j = 0;
+        for (int i = 0; i < fromArray.length; i++) {
+            if (fromArray[i] == '_') {
+                // 当前字符为下划线时,将指针后移一位,将紧随下划线后面一个字符转成大写并存放
+                i++;
+                if (i < fromArray.length) {
+                    toArray[j++] = Character.toUpperCase(fromArray[i]);
+                }
+            } else {
+                toArray[j++] = fromArray[i];
+            }
+        }
+        return new String(toArray, 0, j);
+    }
+
+    public static String join(String[] stringArray) {
+        StringBuilder sb = new StringBuilder();
+        for (String s : stringArray) {
+            sb.append(s);
+        }
+        return sb.toString();
+    }
+
+    public static String join(String[] stringArray, String separator) {
+        StringBuilder sb = new StringBuilder();
+        for (int i = 0; i < stringArray.length; i++) {
+            if (i > 0) {
+                sb.append(separator);
+            }
+            sb.append(stringArray[i]);
+        }
+        return sb.toString();
+    }
+
+    public static boolean equals(String a, String b) {
+        return a == null ? b == null : a.equals(b);
+    }
+
+    public static String getRandomUUID() {
+        return java.util.UUID.randomUUID().toString().replace("-", "");
+    }
+}

+ 1 - 1
nacos/conf/application.properties

@@ -18,7 +18,7 @@
 ### Default web context path:
 server.servlet.contextPath=/nacos
 ### Default web server port:
-server.port=8898
+server.port=8838
 
 #*************** Network Related Configurations ***************#
 ### If prefer hostname over ip for Nacos server addresses in cluster.conf:

+ 1 - 0
nacos/data/config-data/DEFAULT_GROUP/forest-gateway

@@ -25,6 +25,7 @@ secure:
   ignored:
     urls: #安全路径白名单
       - /swagger-ui.html
+      - /*.html
       - /swagger-resources/**
       - /swagger/**
       - /**/v2/api-docs

+ 8 - 5
nacos/data/config-data/DEFAULT_GROUP/forest-portal

@@ -58,6 +58,7 @@ secure:
   ignored:
     urls: #安全路径白名单
       - /swagger-ui.html
+      - /*.html
       - /swagger-resources/**
       - /swagger/**
       - /**/v2/api-docs
@@ -100,17 +101,19 @@ forest:
     password: forest123456
 
 sms:
-  accessKeyId: LTAICB9TH0OAN3yJ
+  accessKeyId: wxde051d502a3d27a5
   accessKeySecret: lCuyL3MUQRLfoVw39W0NqWdVGoLV60
   signName: 慧云网安
 wx:
   mp:
     aesKey: 123
-    appId: wxbe90cc7c5233dd84
-    secret: ec4a18ce1a7bcf17cf592c3d57cec68a
+    # appId: wxbe90cc7c5233dd84
+    appId: wxde051d502a3d27a5
+    # secret: ec4a18ce1a7bcf17cf592c3d57cec68a
+    secret: bdcec99f22bbc1db100d8a7a222c5fa9
     token: 123
-    url: http://tanhui.hongweisoft.com/forest-portal/wechat/h5/userInfo
-    before: http://172.16.90.25:8080
+    url: http://forest.hw.hongweisoft.com/devback/forest-portal/wechat/h5/userInfo
+    before: http://forest.hw.hongweisoft.com
 
 
 

+ 2 - 2
nacos/data/naming/meta.properties

@@ -1,2 +1,2 @@
-#Mon Sep 07 14:54:49 CST 2020
-term=1190
+#Fri Sep 11 19:19:08 CST 2020
+term=20