Browse Source

代码更新

huyuguo 5 years ago
parent
commit
305724f316

+ 5 - 5
app/build.gradle

102
    }
102
    }
103
103
104
    productFlavors {
104
    productFlavors {
105
//        yingyongbao {}
106
//        c360 {}
107
//        xiaomi {}
108
//        huawei {}
109
//        oppo {}
105
        yingyongbao {}
106
        c360 {}
107
        xiaomi {}
108
        huawei {}
109
        oppo {}
110
        cdz {}
110
        cdz {}
111
111
112
112

+ 4 - 3
app/src/main/java/com/electric/chargingpile/activity/RecommendChargingStationActivity.java

28
import com.amap.api.maps.AMapUtils;
28
import com.amap.api.maps.AMapUtils;
29
import com.amap.api.maps.model.LatLng;
29
import com.amap.api.maps.model.LatLng;
30
import com.blankj.utilcode.util.LogUtils;
30
import com.blankj.utilcode.util.LogUtils;
31
import com.electric.chargingpile.BuildConfig;
31
import com.electric.chargingpile.R;
32
import com.electric.chargingpile.R;
32
import com.electric.chargingpile.application.MainApplication;
33
import com.electric.chargingpile.application.MainApplication;
33
import com.electric.chargingpile.data.RecommendZhan;
34
import com.electric.chargingpile.data.RecommendZhan;
343
        loadingDialog.show();
344
        loadingDialog.show();
344
        no_result.setVisibility(View.GONE);
345
        no_result.setVisibility(View.GONE);
345
346
346
        String url = MainApplication.url + "/zhannew/basic/web/index.php/zhanlist/recommend?longitude=" + center_jing + "&latitude=" + center_wei;
347
        String url = MainApplication.url + "/zhannew/basic/web/index.php/zhanlist/recommend?longitude=" + center_jing + "&latitude=" + center_wei + "&version_name=" + BuildConfig.VERSION_NAME + "&version_code=" + BuildConfig.VERSION_CODE + "&pg=30";
347
348
348
        OkHttpUtils.get().url(url).build().readTimeOut(10000).connTimeOut(10000).execute(new StringCallback() {
349
        OkHttpUtils.get().url(url).build().readTimeOut(10000).connTimeOut(10000).execute(new StringCallback() {
349
350
1084
            public void run() {
1085
            public void run() {
1085
                try {
1086
                try {
1086
                    // 创建Socket
1087
                    // 创建Socket
1087
                    socket = new Socket("59.110.68.162", 9503); // IP:59.110.68.162,端口54321 cdz.evcharge.cc  TODO
1088
                    socket = new Socket("cdz.evcharge.cc", 9503); // IP:59.110.68.162,端口54321 cdz.evcharge.cc
1088
                    // 向服务器发送消息
1089
                    // 向服务器发送消息
1089
                    PrintWriter out = new PrintWriter(new BufferedWriter(
1090
                    PrintWriter out = new PrintWriter(new BufferedWriter(
1090
                            new OutputStreamWriter(socket.getOutputStream())), true);
1091
                            new OutputStreamWriter(socket.getOutputStream())), true);
1127
            @Override
1128
            @Override
1128
            public void run() {
1129
            public void run() {
1129
                try {
1130
                try {
1130
                    socket = new Socket("59.110.68.162", 9503); // IP:59.110.68.162,端口54321 cdz.evcharge.cc TODO
1131
                    socket = new Socket("cdz.evcharge.cc", 9503); // IP:59.110.68.162,端口54321 cdz.evcharge.cc
1131
                    socket.setReceiveBufferSize(99999);  //  接收缓冲大小
1132
                    socket.setReceiveBufferSize(99999);  //  接收缓冲大小
1132
                    socket.setSendBufferSize(99999);
1133
                    socket.setSendBufferSize(99999);
1133
                    // 向服务器发送消息
1134
                    // 向服务器发送消息

+ 3 - 2
app/src/main/java/com/electric/chargingpile/activity/RecommendZhanActivity.java

42
import com.amap.api.maps.model.MyLocationStyle;
42
import com.amap.api.maps.model.MyLocationStyle;
43
import com.blankj.utilcode.util.EmptyUtils;
43
import com.blankj.utilcode.util.EmptyUtils;
44
import com.blankj.utilcode.util.LogUtils;
44
import com.blankj.utilcode.util.LogUtils;
45
import com.electric.chargingpile.BuildConfig;
45
import com.electric.chargingpile.R;
46
import com.electric.chargingpile.R;
46
import com.electric.chargingpile.application.MainApplication;
47
import com.electric.chargingpile.application.MainApplication;
47
import com.electric.chargingpile.data.RecommendZhan;
48
import com.electric.chargingpile.data.RecommendZhan;
532
        if (total == 0) {
533
        if (total == 0) {
533
            url = MainApplication.url + "/zhannew/basic/web/index.php/zhanlist/recommend?longitude=" + jing + "&latitude=" + wei
534
            url = MainApplication.url + "/zhannew/basic/web/index.php/zhanlist/recommend?longitude=" + jing + "&latitude=" + wei
534
                    + "&suit_car=" + MainApplication.userTpye + "&belong_attribute=" + MainApplication.shuxing + "&eletype=" + eletype
535
                    + "&suit_car=" + MainApplication.userTpye + "&belong_attribute=" + MainApplication.shuxing + "&eletype=" + eletype
535
                    + "&payway=" + payway + "&supplier=" + MainApplication.costWay + "&stop_cost=" + stop_cost;
536
                    + "&payway=" + payway + "&supplier=" + MainApplication.costWay + "&stop_cost=" + stop_cost + "&version_name=" + BuildConfig.VERSION_NAME + "&version_code=" + BuildConfig.VERSION_CODE;
536
        } else {
537
        } else {
537
            url = MainApplication.url + "/zhannew/basic/web/index.php/zhanlist/recommend?longitude=" + jing + "&latitude=" + wei
538
            url = MainApplication.url + "/zhannew/basic/web/index.php/zhanlist/recommend?longitude=" + jing + "&latitude=" + wei
538
                    + "&suit_car=" + MainApplication.userTpye + "&belong_attribute=" + MainApplication.shuxing + "&eletype=" + eletype
539
                    + "&suit_car=" + MainApplication.userTpye + "&belong_attribute=" + MainApplication.shuxing + "&eletype=" + eletype
539
                    + "&payway=" + payway + "&supplier=" + MainApplication.costWay + "&stop_cost=" + stop_cost + "&scene=" + total;
540
                    + "&payway=" + payway + "&supplier=" + MainApplication.costWay + "&stop_cost=" + stop_cost + "&scene=" + total + BuildConfig.VERSION_NAME + "&version_code=" + BuildConfig.VERSION_CODE;;
540
        }
541
        }
541
        Log.e(TAG, "recommendZhan: url=" + url);
542
        Log.e(TAG, "recommendZhan: url=" + url);
542
543

+ 2 - 2
app/src/main/java/com/electric/chargingpile/application/MainApplication.java

75
    public static String firstPoint = "";
75
    public static String firstPoint = "";
76
    public static Boolean firstSsyd;
76
    public static Boolean firstSsyd;
77
    public static String password = "";
77
    public static String password = "";
78
    public static String url = "http://59.110.68.162";// 充电桩测试环境
79
//        public static String url = "http://cdz.evcharge.cc";// 充电桩正式环境
78
//    public static String url = "http://59.110.68.162";// 充电桩测试环境
79
        public static String url = "http://cdz.evcharge.cc";// 充电桩正式环境
80
//    public static String urlNew = "http://123.56.67.7:83/api/0300";// 一电测试环境
80
//    public static String urlNew = "http://123.56.67.7:83/api/0300";// 一电测试环境
81
    public static String urlNew = "https://api.touchev.com:83/api/0300";// 一电正式环境
81
    public static String urlNew = "https://api.touchev.com:83/api/0300";// 一电正式环境
82
    public static String pic_url = "http://cdz.evcharge.cc/zhannew/uploadfile/";
82
    public static String pic_url = "http://cdz.evcharge.cc/zhannew/uploadfile/";