1.添加推送逻辑,修改删除照片,修改友盟上的bug.
This commit is contained in:
parent
bfe2f6b985
commit
8ff0e92c8a
@ -9,8 +9,8 @@ android {
|
||||
applicationId "com.navinfo.outdoor"
|
||||
minSdkVersion 22
|
||||
targetSdkVersion 30
|
||||
versionCode 9
|
||||
versionName "6.1125"
|
||||
versionCode 10
|
||||
versionName "7.1130"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
}
|
||||
lintOptions {
|
||||
@ -66,9 +66,12 @@ dependencies {
|
||||
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
|
||||
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
|
||||
//友盟自动检测bug
|
||||
implementation 'com.umeng.umsdk:common:9.3.8'
|
||||
implementation 'com.umeng.umsdk:asms:1.2.2'
|
||||
implementation 'com.umeng.umsdk:apm:1.2.0'
|
||||
//友盟基础库依赖(必须)
|
||||
api 'com.umeng.umsdk:common:9.4.4'
|
||||
api 'com.umeng.umsdk:asms:1.4.1'
|
||||
//友盟Push依赖
|
||||
api 'com.umeng.umsdk:push:6.4.7'
|
||||
//状态栏侵染
|
||||
|
||||
// 基础依赖包,必须要依赖
|
||||
|
@ -2,7 +2,6 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
package="com.navinfo.outdoor">
|
||||
|
||||
<uses-permission android:name="android.permission.RECORD_AUDIO" />
|
||||
<uses-permission android:name="android.permission.READ_CALENDAR" /> <!-- <uses-permission android:name="android.permission.WRITE_CALENDAR" /> -->
|
||||
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" />
|
||||
@ -10,10 +9,9 @@
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.CAMERA" /> <!-- <uses-sdk android:minSdkVersion="8"></uses-sdk> -->
|
||||
<!-- 在SDCard中创建与删除文件权限 -->
|
||||
<uses-permission
|
||||
android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS"
|
||||
tools:ignore="ProtectedPermissions" /> <!-- 安装APK权限 -->
|
||||
<uses-permission android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS" tools:ignore="ProtectedPermissions" /> <!-- 安装APK权限 -->
|
||||
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" /> <!-- 友盟检测bug -->
|
||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" tools:node="remove" /><!--移除自启动能力-->
|
||||
<!-- <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> -->
|
||||
<!-- <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> -->
|
||||
<!-- <uses-permission android:name="android.permission.READ_PHONE_STATE" /> -->
|
||||
@ -73,7 +71,8 @@
|
||||
android:value="true" />
|
||||
<meta-data
|
||||
android:name="TencentMapSDK"
|
||||
android:value="EWWBZ-2PB62-6JXUL-CEX7G-N7UE6-XRB4V" /> <!-- 今日头屏幕适配 -->
|
||||
android:value="EWWBZ-2PB62-6JXUL-CEX7G-N7UE6-XRB4V" />
|
||||
<!-- 今日头屏幕适配 -->
|
||||
<meta-data
|
||||
android:name="design_width_in_dp"
|
||||
android:value="360" />
|
||||
@ -86,7 +85,6 @@
|
||||
android:screenOrientation="portrait">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
@ -129,6 +127,44 @@
|
||||
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||
android:resource="@xml/file_paths" />
|
||||
</provider>
|
||||
<!--移除关联启动能力-->
|
||||
<service
|
||||
android:name="com.taobao.accs.ChannelService"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<service
|
||||
android:name="com.taobao.accs.data.MsgDistributeService"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<receiver
|
||||
android:name="com.taobao.accs.EventReceiver"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<receiver
|
||||
android:name="com.taobao.accs.ServiceReceiver"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<service
|
||||
android:name="org.android.agoo.accs.AgooService"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<service
|
||||
android:name="com.umeng.message.UmengIntentService"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<service
|
||||
android:name="com.umeng.message.XiaomiIntentService"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<receiver
|
||||
android:name="com.taobao.agoo.AgooCommondReceiver"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
<service
|
||||
android:name="com.umeng.message.UmengMessageIntentReceiverService"
|
||||
android:exported="false"
|
||||
tools:replace="android:exported" />
|
||||
</application>
|
||||
|
||||
|
||||
</manifest>
|
@ -128,6 +128,7 @@ public class GuidanceActivity extends BaseActivity {
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressLint("InflateParams")
|
||||
@Override
|
||||
protected void initData() {
|
||||
super.initData();
|
||||
|
@ -5,6 +5,7 @@ import com.kongzue.dialog.util.BaseDialog;
|
||||
import com.kongzue.dialog.util.DialogSettings;
|
||||
import com.kongzue.dialog.v3.MessageDialog;
|
||||
import com.navinfo.outdoor.api.Constant;
|
||||
import com.navinfo.outdoor.api.UserApplication;
|
||||
import com.navinfo.outdoor.base.BaseActivity;
|
||||
import com.navinfo.outdoor.fragment.FindFragment;
|
||||
import com.navinfo.outdoor.fragment.MineFragment;
|
||||
@ -20,15 +21,21 @@ import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentPagerAdapter;
|
||||
import androidx.viewpager.widget.ViewPager;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.navinfo.outdoor.R;
|
||||
import com.google.android.material.tabs.TabLayout;
|
||||
import com.gyf.immersionbar.ImmersionBar;
|
||||
import com.umeng.message.PushAgent;
|
||||
import com.umeng.message.UmengNotificationClickHandler;
|
||||
import com.umeng.message.entity.UMessage;
|
||||
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.greenrobot.eventbus.Subscribe;
|
||||
@ -78,14 +85,46 @@ public class HomeActivity extends BaseActivity {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
//自定义点击通知时的打开动作
|
||||
UmengNotificationClickHandler notificationClickHandler = new UmengNotificationClickHandler() {
|
||||
@Override
|
||||
public void dealWithCustomAction(Context context, UMessage msg) {
|
||||
super.dealWithCustomAction(context, msg);
|
||||
Log.i("TAG", "dealWithCustomAction: " + msg.getRaw().toString());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void openActivity(Context context, UMessage msg) {
|
||||
super.openActivity(context, msg);
|
||||
Log.i("TAG", "click openActivity: " + msg.getRaw().toString());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void launchApp(Context context, UMessage msg) {
|
||||
super.launchApp(context, msg);
|
||||
Log.i("TAGEE", "click launchApp: " + msg.getRaw().toString());
|
||||
Intent messageIntent = new Intent(HomeActivity.this, FragmentManagement.class);
|
||||
messageIntent.putExtra("tag", 35);
|
||||
startActivity(messageIntent);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void dismissNotification(Context context, UMessage msg) {
|
||||
super.dismissNotification(context, msg);
|
||||
Log.i("TAG", "click dismissNotification: " + msg.getRaw().toString());
|
||||
}
|
||||
};
|
||||
UserApplication.instance.setNotificationClickHandler(notificationClickHandler);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initView() {
|
||||
super.initView();
|
||||
ImmersionBar.with(this)
|
||||
.navigationBarColor(R.color.tipTextColor)
|
||||
.statusBarDarkFont(true, 0.2f)
|
||||
//原理:如果当前设备支持状态栏字体变色,会设置状态栏字体为黑色,如果当前设备不支持状态栏字体变色,会使当前状态栏加上透明度,否则不执行透明度
|
||||
.init();
|
||||
//原理:如果当前设备支持状态栏字体变色,会设置状态栏字体为黑色,如果当前设备不支持状态栏字体变色,会使当前状态栏加上透明度,否则不执行透明度
|
||||
ImmersionBar.with(this).navigationBarColor(R.color.tipTextColor).statusBarDarkFont(true, 0.2f).init();
|
||||
mTab = findViewById(R.id.tab_layout);
|
||||
NoSlideViewPager mViewPager = findViewById(R.id.no_slide_view_pager);
|
||||
ArrayList<Fragment> fragments = new ArrayList<>();
|
||||
@ -101,7 +140,6 @@ public class HomeActivity extends BaseActivity {
|
||||
public Fragment getItem(int i) {
|
||||
return fragments.get(i);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getCount() {
|
||||
return fragments.size();
|
||||
@ -141,7 +179,6 @@ public class HomeActivity extends BaseActivity {
|
||||
obtain.what = Constant.HOME_MINE;
|
||||
obtain.obj = true;
|
||||
EventBus.getDefault().post(obtain);
|
||||
|
||||
}
|
||||
}
|
||||
//点击table layout效果
|
||||
@ -183,7 +220,6 @@ public class HomeActivity extends BaseActivity {
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
} else if (data.what == Constant.NEST_WORD_REGISTER) {
|
||||
String dataString = (String) data.obj;
|
||||
|
@ -35,6 +35,7 @@ import com.navinfo.outdoor.http.UploadCallBack;
|
||||
import com.navinfo.outdoor.util.Base64;
|
||||
import com.navinfo.outdoor.util.Md5Util;
|
||||
import com.navinfo.outdoor.util.TimestampUtil;
|
||||
import com.umeng.umcrash.UMCrash;
|
||||
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.greenrobot.eventbus.Subscribe;
|
||||
@ -252,18 +253,18 @@ public class LoginActivity extends BaseActivity implements View.OnClickListener
|
||||
});
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
UMCrash.generateCustomLog(e, "自定义");
|
||||
}
|
||||
}
|
||||
|
||||
private void initGetUserInfo() {
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder
|
||||
.getInstance()
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder.getInstance()
|
||||
.time(30)
|
||||
.Builder(this)
|
||||
.url(HttpInterface.USER_DETAIL_BY_USER_ID)
|
||||
.cls(UserDetailBean.class)
|
||||
.token(Constant.ACCESS_TOKEN)
|
||||
.params(new HttpParams())
|
||||
.cls(UserDetailBean.class);
|
||||
.params(new HttpParams());
|
||||
okGoBuilder.getRequest(new Callback<UserDetailBean>() {
|
||||
@Override
|
||||
public void onSuccess(UserDetailBean response, int id) {
|
||||
|
@ -184,7 +184,6 @@ public class MainActivity extends BaseActivity {
|
||||
initTime();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
|
@ -124,20 +124,10 @@ public class PhotographActivity extends BaseActivity implements View.OnClickList
|
||||
photographBuilder.append(TimestampUtil.time()).append(",").append("cameraView 用户横屏拍摄 ,");
|
||||
}
|
||||
File file = new File(photo_path);
|
||||
/*
|
||||
File destFolder = new File(file.getParentFile().getAbsolutePath()+"aaa");
|
||||
if (!destFolder.exists()) {
|
||||
destFolder.mkdirs();
|
||||
}*/
|
||||
result.toFile(file, new FileCallback() {
|
||||
@Override
|
||||
public void onFileReady(@Nullable File file) {
|
||||
/* Intent intent = new Intent();
|
||||
intent.putExtra("file", file.getAbsolutePath());
|
||||
setResult(0x104, intent);
|
||||
SystemTTS.getInstance(PhotographActivity.this).stopSpeak();
|
||||
PhotographActivity.this.finish();*/
|
||||
if (file.exists()) {
|
||||
if (file!=null&&file.exists()) {
|
||||
WebPNative webPNative = new WebPNative();
|
||||
new Thread(new Runnable() {
|
||||
@Override
|
||||
@ -155,7 +145,6 @@ public class PhotographActivity extends BaseActivity implements View.OnClickList
|
||||
PhotographActivity.this.finish();
|
||||
}
|
||||
});
|
||||
|
||||
if (!bitmap.isRecycled()) {
|
||||
bitmap.recycle();
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.Matrix;
|
||||
import android.location.Location;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
@ -41,12 +42,12 @@ import com.navinfo.outdoor.base.BaseActivity;
|
||||
import com.navinfo.outdoor.room.PoiEntity;
|
||||
import com.navinfo.outdoor.util.AWMp4ParserHelper;
|
||||
import com.navinfo.outdoor.util.BackHandlerHelper;
|
||||
import com.navinfo.outdoor.util.GPSUtils;
|
||||
import com.navinfo.outdoor.util.Geohash;
|
||||
import com.navinfo.outdoor.util.GeometryTools;
|
||||
import com.navinfo.outdoor.util.MyTecentLocationSource;
|
||||
import com.navinfo.outdoor.util.SystemTTS;
|
||||
import com.navinfo.outdoor.util.TimestampUtil;
|
||||
import com.navinfo.outdoor.util.ToastUtil;
|
||||
import com.otaliastudios.cameraview.CameraListener;
|
||||
import com.otaliastudios.cameraview.CameraLogger;
|
||||
import com.otaliastudios.cameraview.CameraView;
|
||||
@ -69,6 +70,7 @@ import com.tencent.tencentmap.mapsdk.maps.model.MarkerOptions;
|
||||
import com.tencent.tencentmap.mapsdk.maps.model.MyLocationStyle;
|
||||
import com.tencent.tencentmap.mapsdk.maps.model.Polyline;
|
||||
import com.tencent.tencentmap.mapsdk.maps.model.PolylineOptions;
|
||||
import com.umeng.commonsdk.internal.crash.UMCrashManager;
|
||||
import com.umeng.umcrash.UMCrash;
|
||||
import com.vividsolutions.jts.geom.Geometry;
|
||||
import com.wanghong.webpnative.WebPNative;
|
||||
@ -103,14 +105,6 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
private String finalVideoPath, geoWkt, detail; // 摄像后最终保存的文件名
|
||||
private ViewGroup layerChange; // 切换地图和相机的父控件
|
||||
private CheckBox capturePicture, cbMapType; //拍照
|
||||
private boolean isMapSlide = false;
|
||||
private boolean isOration = true;
|
||||
private boolean isTerminus = false;
|
||||
private boolean isBack = true;
|
||||
private int type = 0;
|
||||
private int radioPicture = 0;
|
||||
private int videoIndex = -1;
|
||||
private SimpleDateFormat formatter;
|
||||
private File paperFile, logFile;
|
||||
private ImageView ivZoomAdd, ivZoomDel, ivLocation, ivPicRoadImage, ivPicVideoImage, imageView;
|
||||
private TencentLocation oldCurrentLocation = null;
|
||||
@ -120,6 +114,20 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
private StringBuilder picturesBuilder;
|
||||
private LatLng startLatLine, endLatLine;
|
||||
private TextView tvTitle;
|
||||
private GPSUtils gpsUtils;
|
||||
private Location gpsLocation;
|
||||
private boolean isMapSlide = false;
|
||||
private boolean isOration = true;
|
||||
private boolean isTerminus = false;
|
||||
private boolean isBack = true;
|
||||
private int initCount;
|
||||
private int type = 0;
|
||||
private int radioPicture = 0;
|
||||
private int videoIndex = -1;
|
||||
private int startVideoIndex = -1;
|
||||
private int webp=1;
|
||||
@SuppressLint("SimpleDateFormat")
|
||||
private SimpleDateFormat formatter;
|
||||
private Handler handler = new Handler(new Handler.Callback() {
|
||||
@Override
|
||||
public boolean handleMessage(@NonNull Message msg) {
|
||||
@ -140,6 +148,7 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@Override
|
||||
protected int getLayout() {
|
||||
EventBus.getDefault().register(this);
|
||||
@ -166,17 +175,25 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
}
|
||||
formatter = new SimpleDateFormat("yyyyMMdd HHmmss");
|
||||
removables = new ArrayList<>();//存储轨迹的marker
|
||||
layerChange = findViewById(R.id.layer_change);
|
||||
formatter = new SimpleDateFormat("yyyyMMdd HHmmss");
|
||||
this.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
|
||||
systemTTS = SystemTTS.getInstance(PicturesActivity.this);
|
||||
tvMapView = findViewById(R.id.iv_map);
|
||||
tvMapView = findViewById(R.id.text_map_view);
|
||||
tvMapView.setOnClickListener(this);
|
||||
ivPicRoadImage = findViewById(R.id.iv_pic);
|
||||
ivPicVideoImage = findViewById(R.id.iv_pic_video);
|
||||
Button btnSwitch = findViewById(R.id.btn_switch);
|
||||
btnSwitch.setOnClickListener(this);
|
||||
gpsUtils = new GPSUtils(PicturesActivity.this);
|
||||
gpsUtils.setOnClickGPSStatus(new GPSUtils.OnClickGPSStatus() {
|
||||
@Override
|
||||
public void onGpsCount(int count) {
|
||||
initCount = count;
|
||||
gpsLocation = gpsUtils.getLocation();
|
||||
}
|
||||
});
|
||||
RadioGroup radioGroupPicture = findViewById(R.id.radio_group_picture);
|
||||
RadioButton radioBtnHand = findViewById(R.id.radio_btn_hand);
|
||||
RadioButton radioBtnAuto = findViewById(R.id.radio_btn_auto);
|
||||
@ -307,7 +324,6 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
File file = new File(finalVideoPath);
|
||||
initMarkerPaper();
|
||||
result.toFile(file, new FileCallback() {
|
||||
@Override
|
||||
public void onFileReady(@Nullable File file) {
|
||||
@ -338,7 +354,7 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
private PictureResult pictureResult;
|
||||
private File file;
|
||||
|
||||
public Jpg2WebpRunnable(PictureResult pictureResult,File file) {
|
||||
public Jpg2WebpRunnable(PictureResult pictureResult, File file) {
|
||||
this.pictureResult = pictureResult;
|
||||
this.file = file;
|
||||
}
|
||||
@ -346,23 +362,20 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
@Override
|
||||
public void run() {
|
||||
if (file.exists() && file != null) {
|
||||
WebPNative webPNative = new WebPNative();
|
||||
Bitmap bitmap = BitmapFactory.decodeFile(file.getAbsolutePath());
|
||||
webPNative.encodeRGBA(bitmap, file.getPath(), 90);
|
||||
if (!bitmap.isRecycled()) {
|
||||
bitmap.recycle();
|
||||
}
|
||||
initWeb(file);
|
||||
runOnUiThread(new Runnable() {
|
||||
@SuppressLint("SetTextI18n")
|
||||
@Override
|
||||
public void run() {
|
||||
if (PicturesActivity.this!=null) {
|
||||
if (PicturesActivity.this != null) {
|
||||
if (file.exists()) {
|
||||
initMarkerPaper();
|
||||
initMarker();
|
||||
videoIndex = Integer.parseInt(file.getName().replace(".webp", ""));
|
||||
finalVideoPath = Objects.requireNonNull(file.getParentFile()).getAbsolutePath() + "/" + (videoIndex + 1) + ".webp";
|
||||
tvTitle.setText("保存成功:" + (videoIndex + 1));
|
||||
}
|
||||
if (radioPicture == 1&&handler!=null) {
|
||||
if (radioPicture == 1 && handler != null) {
|
||||
Message message = new Message();
|
||||
message.what = 0x103;
|
||||
handler.sendMessage(message);
|
||||
@ -389,6 +402,31 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
private void initWeb(File file) {
|
||||
if (webp==3){
|
||||
return;
|
||||
}
|
||||
try {
|
||||
WebPNative webPNative = new WebPNative();
|
||||
Bitmap bitmap = BitmapFactory.decodeFile(file.getAbsolutePath());
|
||||
webPNative.encodeRGBA(bitmap, file.getPath(), 90);
|
||||
if (!bitmap.isRecycled()) {
|
||||
bitmap.recycle();
|
||||
}
|
||||
webp=1;
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
UMCrashManager.reportCrash(this,e);
|
||||
handler.postDelayed(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
webp++;
|
||||
initWeb(file);
|
||||
}
|
||||
}, 10);
|
||||
}
|
||||
}
|
||||
|
||||
private void initLine() {
|
||||
if (geoWkt != null) {
|
||||
String geo = Geohash.getInstance().decode(geoWkt);
|
||||
@ -494,13 +532,13 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
finalVideoPath = Objects.requireNonNull(paperFile.getParentFile()).getAbsolutePath() + "/" + videoIndex + ".webp";
|
||||
intent.putExtra(Constant.INTENT_PICTURES_PATH, finalVideoPath);
|
||||
setResult(0x111, intent);
|
||||
this.finish();
|
||||
PicturesActivity.this.finish();
|
||||
break;
|
||||
case R.id.image_view:
|
||||
picturesBuilder.append(TimestampUtil.time()).append(",").append("onClick 点击了切换的窗口 ,");
|
||||
v.setEnabled(false);
|
||||
benSwitch();
|
||||
handler.sendEmptyMessageDelayed(0x102, 2000);// 利用handler延迟发送更改状态信息
|
||||
benSwitch();
|
||||
break;
|
||||
case R.id.btn_switch:
|
||||
picturesBuilder.append(TimestampUtil.time()).append(",").append("onClick 点击了切换按钮 ,");
|
||||
@ -708,12 +746,17 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
|
||||
@SuppressLint("SetTextI18n")
|
||||
public void initMarkerPaper() {
|
||||
int endVideoIndex = videoIndex == -1 ? 0 : (videoIndex + 1);
|
||||
if (startVideoIndex == endVideoIndex) {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
// 记录当前时间、视频时间、以及当前经纬度信息
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append(formatter.format(new Date())); // 记录当前时
|
||||
sb.append(",");
|
||||
sb.append(videoIndex == -1 ? 0 : (videoIndex + 1));//個數
|
||||
startVideoIndex = videoIndex == -1 ? 0 : (videoIndex + 1);
|
||||
sb.append(",");
|
||||
sb.append(Constant.currentLocation.getLatitude());
|
||||
sb.append(",");
|
||||
@ -724,6 +767,7 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
} else {
|
||||
sb.append(Constant.currentLocation.getDirection());
|
||||
}
|
||||
sb.append(",");
|
||||
int gpsRssi = Constant.currentLocation.getGPSRssi();
|
||||
if (gpsRssi == 0) {
|
||||
sb.append("无信号");
|
||||
@ -738,6 +782,17 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
sb.append("强");
|
||||
sb.append(",");
|
||||
}
|
||||
sb.append(initCount);
|
||||
sb.append(",");
|
||||
if (gpsLocation != null) {
|
||||
sb.append(gpsLocation.getLatitude());
|
||||
sb.append(",");
|
||||
sb.append(gpsLocation.getLongitude());
|
||||
} else {
|
||||
sb.append(0);
|
||||
sb.append(",");
|
||||
sb.append(0);
|
||||
}
|
||||
sb.append("\r\n");
|
||||
if (isBack) {
|
||||
//快到终点的语音播报
|
||||
@ -753,17 +808,17 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
public void run() {
|
||||
initMarkerPaper();
|
||||
}
|
||||
}, 100);
|
||||
}, 10);
|
||||
}
|
||||
}
|
||||
|
||||
private void initTerminus() {
|
||||
if (Constant.currentLocation != null) {
|
||||
LatLng newLatLine = new LatLng(Constant.currentLocation.getLatitude(), Constant.currentLocation.getLongitude());
|
||||
if (endLatLine != null && startLatLine != null) {
|
||||
LatLng newLatLine = new LatLng(Constant.currentLocation.getLatitude(), Constant.currentLocation.getLongitude());
|
||||
double startDistance = GeometryTools.distanceToDouble(newLatLine, startLatLine);
|
||||
double endDistance = GeometryTools.distanceToDouble(newLatLine, endLatLine);
|
||||
if (startDistance > endDistance) {//endDistance: 起点 startDistance:终点
|
||||
if (startDistance > endDistance) { //endDistance: 起点 startDistance:终点
|
||||
if (startDistance < 50 && !isTerminus) {
|
||||
systemTTS.playText("即将到达任务终点");
|
||||
isTerminus = true;
|
||||
@ -811,12 +866,12 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
} else if (type == 4) {
|
||||
if (radioPicture == 2) {
|
||||
double speeds = ((geometry / 1) * 3600 / 1000);
|
||||
if (speeds > 80) {//80千米/h
|
||||
if (speeds > 80) { //80千米/h
|
||||
systemTTS.playText("您已超速");
|
||||
}
|
||||
} else if (radioPicture == 3) {
|
||||
double speeds = ((geometry / 2) * 3600 / 1000);
|
||||
if (speeds > 80) {//80千米/h
|
||||
if (speeds > 80) { //80千米/h
|
||||
systemTTS.playText("您已超速");
|
||||
}
|
||||
}
|
||||
@ -847,7 +902,7 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
finalVideoPath = Objects.requireNonNull(paperFile.getParentFile()).getAbsolutePath() + "/" + videoIndex + ".webp";
|
||||
intent.putExtra(Constant.INTENT_PICTURES_PATH, finalVideoPath);
|
||||
setResult(0x111, intent);
|
||||
finish();
|
||||
PicturesActivity.this.finish();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
@ -900,5 +955,4 @@ public class PicturesActivity extends BaseActivity implements View.OnClickListen
|
||||
timerTask = null;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -23,7 +23,7 @@ public class StatementActivity extends BaseActivity {
|
||||
ivStatement.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
finish();
|
||||
StatementActivity.this. finish();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -108,7 +108,7 @@ public class WebActivity extends BaseActivity implements View.OnClickListener {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (v.getId() == R.id.iv_icon) {
|
||||
finish();
|
||||
WebActivity.this.finish();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -41,10 +41,17 @@ public class CapacityEvaluationAdapter extends RecyclerView.Adapter<CapacityEval
|
||||
public void onBindViewHolder(@NonNull ViewHolder holder, int position) {
|
||||
TaskPrefectureBean.BodyBean.ListBean listBean = capacityList.get(position);
|
||||
holder.tvCapacity.setText(listBean.getTitle()+"");
|
||||
if (listBean.getStatus()!=null){
|
||||
holder.tvResults.setText(listBean.getStatus()+"");
|
||||
|
||||
Integer status = listBean.getStatus();
|
||||
if (status!=null){
|
||||
if (status==0){
|
||||
holder.tvResults.setText("不通过");
|
||||
}else if (status==1){
|
||||
holder.tvResults.setText("通过");
|
||||
}
|
||||
|
||||
}else {
|
||||
holder.tvResults.setText("");
|
||||
holder.tvResults.setText("不通过");
|
||||
}
|
||||
|
||||
Glide.with(context).load(listBean.getIconurl()).apply(RequestOptions.bitmapTransform(new CircleCrop())).into(holder.ivCapacity);
|
||||
|
@ -100,7 +100,6 @@ public class CapacityMeasureAdapter extends RecyclerView.Adapter<CapacityMeasure
|
||||
// Toast.makeText(context, "option" + option, Toast.LENGTH_SHORT).show();
|
||||
updateCheckedMap(questionId, buttonView, parentLayout);
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
cbOptionIndex.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
||||
|
@ -44,7 +44,7 @@ public class StaySubmitAdapter extends RecyclerView.Adapter<StaySubmitAdapter.Vi
|
||||
notifyDataSetChanged();
|
||||
}
|
||||
|
||||
public void setUpdateWork(){
|
||||
public void setUpdateWork() {
|
||||
new Thread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
@ -83,9 +83,7 @@ public class StaySubmitAdapter extends RecyclerView.Adapter<StaySubmitAdapter.Vi
|
||||
PoiEntity poiEntity = (PoiEntity) iterator.next();
|
||||
if (poiEntity.isChecked()) {
|
||||
PoiEntityDeleteUtil.getInstance().deleteUtil(context, poiEntity);
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setTaskStatus(100);
|
||||
PoiDatabase.getInstance(context).getPoiDao().updatePoiEntity(poiEntity);
|
||||
PoiDatabase.getInstance(context).getPoiDao().deletePoiEntity(poiEntity);
|
||||
iterator.remove();
|
||||
}
|
||||
}
|
||||
@ -121,14 +119,20 @@ public class StaySubmitAdapter extends RecyclerView.Adapter<StaySubmitAdapter.Vi
|
||||
poiEntity.setChecked(!poiEntity.isChecked());
|
||||
}
|
||||
});
|
||||
if (allRoad.get(position).isChecked()){
|
||||
if (poiEntity.getWork_type()==0){
|
||||
if (allRoad.get(position).isChecked()) {
|
||||
if (poiEntity.getWork_type() == 0) {
|
||||
holder.tvText.setText("待提交");
|
||||
}else if (poiEntity.getWork_type()==1){
|
||||
} else if (poiEntity.getWork_type() == 1) {
|
||||
holder.tvText.setText("提交中");
|
||||
allRoad.get(position).setChecked(true);
|
||||
}
|
||||
} else {
|
||||
if (poiEntity.getWork_type() == 1) {
|
||||
holder.tvText.setText("提交中");
|
||||
allRoad.get(position).setChecked(true);
|
||||
} else {
|
||||
holder.tvText.setText("待提交");
|
||||
}
|
||||
}else {
|
||||
holder.tvText.setText("待提交");
|
||||
}
|
||||
holder.itemView.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
@ -146,7 +150,7 @@ public class StaySubmitAdapter extends RecyclerView.Adapter<StaySubmitAdapter.Vi
|
||||
}
|
||||
|
||||
public static class ViewHolder extends RecyclerView.ViewHolder {
|
||||
private TextView tvName,tvText,tvDay;
|
||||
private TextView tvName, tvText, tvDay;
|
||||
private CheckBox cbUnSubmit;
|
||||
|
||||
public ViewHolder(@NonNull View itemView) {
|
||||
@ -172,9 +176,11 @@ public class StaySubmitAdapter extends RecyclerView.Adapter<StaySubmitAdapter.Vi
|
||||
};
|
||||
|
||||
public onClickItem onClickItem;
|
||||
|
||||
public void setOnClickItem(onClickItem onClickItem) {
|
||||
this.onClickItem = onClickItem;
|
||||
}
|
||||
|
||||
public interface onClickItem {
|
||||
void item(int position, PoiEntity allRoad);
|
||||
}
|
||||
|
@ -29,10 +29,6 @@ public class TaskPrefectureAdapter extends RecyclerView.Adapter<TaskPrefectureAd
|
||||
@Override
|
||||
public ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
|
||||
View mView = LayoutInflater.from(context).inflate(R.layout.task_prefecture_item, parent, false);
|
||||
/* int parentHeight= parent.getHeight();
|
||||
parent.getWidth();
|
||||
ViewGroup.LayoutParams layoutParams = viewHolder.itemView.getLayoutParams();
|
||||
layoutParams.height = (parentHeight/ 6);*/
|
||||
return new ViewHolder(mView);
|
||||
}
|
||||
|
||||
|
@ -54,7 +54,15 @@ public class WithdrawalAdapter extends RecyclerView.Adapter<WithdrawalAdapter.On
|
||||
WithdrawalBean.BodyBean.ListBean listBean = dataBeans.get(position);
|
||||
holder.tvTitle.setText(listBean.getExchangePrice() + "元");
|
||||
holder.tvTime.setText(listBean.getCommitDate());
|
||||
holder.tvDec.setText(listBean.getAdminConfirm() == 0 ? "未审核" : "已审核");
|
||||
int adminConfirm = listBean.getAdminConfirm();
|
||||
if (adminConfirm==-1){
|
||||
holder.tvDec.setText("未通过");
|
||||
}else if (adminConfirm==0){
|
||||
holder.tvDec.setText("未审核");
|
||||
}else if (adminConfirm==1){
|
||||
holder.tvDec.setText("已通过,支付完成,可能到账延迟");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -94,7 +94,10 @@ public class Constant {
|
||||
public static String FILE_PATH = null;//银行卡图片途径
|
||||
public static int LEVEL = 0;//用户等级
|
||||
public static boolean isPresent = true;//判断是否在提交中
|
||||
public static String YOU_MENG_APP_KEY = "6139d82c5f798a55cafc51d6";//友盟appkey
|
||||
public static final String UM_APP_KEY = "6139d82c5f798a55cafc51d6";//友盟appkey
|
||||
public static final String MESSAGE_SECRET="7f97e36475276e510cba50ac196428d0";//友盟 UmengMessageSecret
|
||||
public static final String APP_MESSAGE_SECRET="dyha2g9iiv4yfpz36pysrd4yljwzlyav";//友盟App Master Secret
|
||||
public static String DEVICE_TOKEN=null;
|
||||
// message word 值
|
||||
public static final int TREASURE_FRAGMENT = 100;//抽屉界面的展示和隐藏
|
||||
public static final int TREASURE_WORD = 39;//poi 对地图页面marker 的一个展示 编辑
|
||||
@ -142,6 +145,7 @@ public class Constant {
|
||||
public static final int STAY_SUBMIT_ITEM = 52;//待提交
|
||||
public static final int HAS_SUBMIT_ITEM = 53;//已提交
|
||||
public static final int EVENT_MESSAGE = 55;//提示消息
|
||||
public static final int CAPACITY_EVALUATION=59;//能力测试的返回
|
||||
public static final String INTENT_POI_VIDEO_TYPE = "poi_video_type";
|
||||
public static int NUMBER = 200; //任务个数
|
||||
public static int LIMIT_TYPE = -1; //权限类型,普通任务-0,专属任务-1
|
||||
@ -155,19 +159,19 @@ public class Constant {
|
||||
public static LatLng markerLacing;
|
||||
public static JobSearchBean jobSearchBean;//数
|
||||
public static MapView treasureMap;
|
||||
public static final String INTENT_ID = "id";//poiEntity 的id
|
||||
public static boolean IS_FILTER_LIST_ITEM = true;//poi页面的查重
|
||||
public static final String INTENT_VIDEO_PATH = "INTENT_VIDEO_PATH"; // 拍照界面指定的视频文件保存位置
|
||||
public static final String INTENT_JPG_PATH = "INTENT_JPG_PATH"; // 拍照界面指定的图片保存位置
|
||||
public static final String INTENT_PHOTO_PATH = "INTENT_PHOTO_PATH"; // 拍照界面指定的图片保存位置
|
||||
public static final String INTENT_PICTURES_PATH = "INTENT_VIDEO_PATH"; // 拍照界面指定的视频文件保存位置
|
||||
public static final String INTENT_VIDEO_OBLATION = "INTENT_VIDEO_OBLATION"; // 视频拍摄时屏幕方向 0-强制横屏 其他-任意
|
||||
public static final String INTENT_ID = "id";//poiEntity 的id
|
||||
public static final String INTENT_TYPE = "type";//poiEntity 的type
|
||||
public static final String INTENT_GEO_WKT = "geowkt";//poiEntity 的geowkt
|
||||
public static final String INTENT_DETAIL = "Detail";//poiEntity 的detail
|
||||
public static SlidingUpPanelLayout SLIDING_LAYOUT = null;//設置
|
||||
public static boolean IS_FILTER_LIST_ITEM = true;//poi页面的查重
|
||||
public static TencentMap.OnMarkerClickListener markerClickListener = null;
|
||||
public static final String NAVIN_FO = "11.26";//版本日期
|
||||
public static final String NAVIN_FO = "12.02";//版本日期
|
||||
|
||||
//marker
|
||||
public static final BitmapDescriptor MARKER_POI_SHOW = BitmapDescriptorFactory.fromResource(R.drawable.marker_poi_show);
|
||||
@ -191,9 +195,7 @@ public class Constant {
|
||||
public static final BitmapDescriptor GRAY_OTHER = BitmapDescriptorFactory.fromResource(R.drawable.grayother);
|
||||
public static final BitmapDescriptor GRAY_FACET = BitmapDescriptorFactory.fromResource(R.drawable.grayfacet);
|
||||
public static final BitmapDescriptor ICON_OPERATION = BitmapDescriptorFactory.fromResource(R.mipmap.icon_operation);
|
||||
/*
|
||||
*联系我们的QQ群名称和QQ群号
|
||||
*/
|
||||
/*联系我们的QQ群名称和QQ群号*/
|
||||
public static String REGION_JIG_NAME = "京津冀晋蒙-地图寻宝群";
|
||||
public static String REGION_JIG_PHONE = "9721810";
|
||||
public static String REGION_HEI_NAME = "黑吉辽-地图寻宝群";
|
||||
|
@ -1,7 +1,11 @@
|
||||
package com.navinfo.outdoor.api;
|
||||
|
||||
import android.app.Application;
|
||||
import android.app.Notification;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.StrictMode;
|
||||
import android.util.Log;
|
||||
|
||||
import com.lzy.okgo.OkGo;
|
||||
import com.lzy.okgo.cache.CacheEntity;
|
||||
@ -10,9 +14,15 @@ import com.lzy.okgo.cookie.CookieJarImpl;
|
||||
import com.lzy.okgo.cookie.store.DBCookieStore;
|
||||
import com.lzy.okgo.interceptor.HttpLoggingInterceptor;
|
||||
import com.lzy.okgo.model.HttpHeaders;
|
||||
import com.navinfo.outdoor.util.SystemTTS;
|
||||
import com.navinfo.outdoor.activity.FragmentManagement;
|
||||
import com.navinfo.outdoor.util.TalentLocationUtils;
|
||||
import com.umeng.commonsdk.UMConfigure;
|
||||
import com.umeng.message.IUmengRegisterCallback;
|
||||
import com.umeng.message.MsgConstant;
|
||||
import com.umeng.message.PushAgent;
|
||||
import com.umeng.message.UmengMessageHandler;
|
||||
import com.umeng.message.UmengNotificationClickHandler;
|
||||
import com.umeng.message.entity.UMessage;
|
||||
import com.umeng.umcrash.UMCrash;
|
||||
import com.umeng.umcrash.UMCrashCallback;
|
||||
|
||||
@ -26,36 +36,77 @@ import okhttp3.OkHttpClient;
|
||||
|
||||
public class UserApplication extends Application {
|
||||
public static UserApplication userApplication;
|
||||
public static ExecutorService fixedThreadPool;
|
||||
public static ExecutorService fixedThreadPool;
|
||||
public static PushAgent instance;
|
||||
|
||||
@Override
|
||||
public void onCreate() {
|
||||
super.onCreate();
|
||||
userApplication = this;
|
||||
initUMSDK();
|
||||
initOkGo();
|
||||
TalentLocationUtils.getInstance(this).startLocation(this);
|
||||
//创建一个线程池
|
||||
fixedThreadPool = Executors.newFixedThreadPool(5);
|
||||
}
|
||||
|
||||
public static UserApplication getUserApplication() {
|
||||
return userApplication;
|
||||
}
|
||||
|
||||
private void initUMSDK() {
|
||||
//友盟 检测bug
|
||||
UMConfigure.init(this, Constant.YOU_MENG_APP_KEY, "navinfo", UMConfigure.DEVICE_TYPE_PHONE, "");
|
||||
/**
|
||||
*设置组件化的Log开关
|
||||
*参数: boolean 默认为false,如需查看LOG设置为true
|
||||
*/
|
||||
UMConfigure.init(this, Constant.UM_APP_KEY, "navinfo", UMConfigure.DEVICE_TYPE_PHONE, Constant.MESSAGE_SECRET);
|
||||
//设置组件化的Log开关 如需查看LOG设置为true
|
||||
UMConfigure.setLogEnabled(true);
|
||||
// String e ="测试自定义异常代码是否运行!!!!!!";
|
||||
// UMCrash.generateCustomLog(e,"UmengException");
|
||||
UMCrash.registerUMCrashCallback(new UMCrashCallback() {
|
||||
@Override
|
||||
public String onCallback() {
|
||||
return "注册友盟异常查看功能";
|
||||
}
|
||||
});
|
||||
initOkGo();
|
||||
TalentLocationUtils.getInstance(this).startLocation(this);
|
||||
fixedThreadPool = Executors.newFixedThreadPool(5);
|
||||
}
|
||||
|
||||
public static UserApplication getUserApplication() {
|
||||
|
||||
return userApplication;
|
||||
|
||||
instance = PushAgent.getInstance(this);
|
||||
instance.register(new IUmengRegisterCallback() {
|
||||
@Override
|
||||
public void onSuccess(String s) {
|
||||
//注册成功会返回deviceToken deviceToken是推送消息的唯一标志
|
||||
Constant.DEVICE_TOKEN = s;
|
||||
Log.i("TAGEE", "Success 注册成功:deviceToken:--> " + Constant.DEVICE_TOKEN);
|
||||
}
|
||||
@Override
|
||||
public void onFailure(String s, String s1) {
|
||||
Log.e("TAGEE", "Failure 注册失败:--> " + "code:" + s + ", desc:" + s1);
|
||||
}
|
||||
});
|
||||
UmengMessageHandler msgHandler = new UmengMessageHandler() {
|
||||
//处理通知栏消息
|
||||
@Override
|
||||
public void dealWithNotificationMessage(Context context, UMessage msg) {
|
||||
super.dealWithNotificationMessage(context, msg);
|
||||
Log.i("TAGEE", "dealWithNotificationMessage:" + msg.getRaw().toString());
|
||||
}
|
||||
//自定义通知样式,此方法可以修改通知样式等
|
||||
@Override
|
||||
public Notification getNotification(Context context, UMessage msg) {
|
||||
Log.i("TAGEE", "notification receiver:" + msg.getRaw().toString());
|
||||
return super.getNotification(context, msg);
|
||||
}
|
||||
//处理透传消息
|
||||
@Override
|
||||
public void dealWithCustomMessage(Context context, UMessage msg) {
|
||||
super.dealWithCustomMessage(context, msg);
|
||||
Log.i("TAGEE", "dealWithCustomMessage:" + msg.getRaw().toString());
|
||||
}
|
||||
};
|
||||
instance.setMessageHandler(msgHandler);
|
||||
//App处于前台时不显示通知
|
||||
//instance.setNotificationOnForeground(false);
|
||||
//设置显示通知的数量
|
||||
//instance.setDisplayNotificationNumber(0);
|
||||
//服务端控制声音
|
||||
//instance.setNotificationPlaySound(MsgConstant.NOTIFICATION_PLAY_SERVER);
|
||||
//通知免打扰时段
|
||||
//instance.setNoDisturbMode(23,0,7,0);
|
||||
}
|
||||
|
||||
private void initOkGo() {
|
||||
@ -69,7 +120,7 @@ public class UserApplication extends Application {
|
||||
//设置请求头,token值
|
||||
HttpHeaders headers = new HttpHeaders();
|
||||
//headers.put("X-Access-Token", SPUtils.get(SpKey.TOKEN, "")+"");
|
||||
// LogUtils.v("X-Access-Token:" + SPUtils.get(SpKey.TOKEN, ""));
|
||||
//LogUtils.v("X-Access-Token:" + SPUtils.get(SpKey.TOKEN, ""));
|
||||
builder.addInterceptor(loggingInterceptor);
|
||||
//自动管理cookie(或者叫session的保持),以下几种任选其一就行
|
||||
//使用sp保持cookie,如果cookie不过期,则一直有效
|
||||
@ -80,15 +131,11 @@ public class UserApplication extends Application {
|
||||
//builder.cookieJar(new CookieJarImpl(new MemoryCookieStore()));
|
||||
//超时时间设置,默认60秒
|
||||
//全局的读取超时时间
|
||||
|
||||
builder.readTimeout(0, TimeUnit.MILLISECONDS);
|
||||
|
||||
//全局的写入超时时间
|
||||
builder.writeTimeout(0, TimeUnit.MILLISECONDS);
|
||||
|
||||
//全局的连接超时时间
|
||||
builder.connectTimeout(0, TimeUnit.MILLISECONDS);
|
||||
|
||||
OkGo.getInstance().init(this)
|
||||
.setOkHttpClient(builder.build())
|
||||
//全局统一缓存模式,默认不使用缓存,可以不传
|
||||
@ -99,7 +146,6 @@ public class UserApplication extends Application {
|
||||
.addCommonHeaders(headers)
|
||||
//全局统一超时重连次数,默认为三次,那么最差的情况会请求4次(一次原始请求,三次重连请求),不需要可以设置为0;
|
||||
.setRetryCount(0);
|
||||
|
||||
StrictMode.VmPolicy.Builder picBuilder = new StrictMode.VmPolicy.Builder();
|
||||
StrictMode.setVmPolicy(picBuilder.build());
|
||||
picBuilder.detectFileUriExposure();
|
||||
|
@ -27,6 +27,7 @@ import com.navinfo.outdoor.activity.WebActivity;
|
||||
import com.navinfo.outdoor.api.UserApplication;
|
||||
import com.gyf.immersionbar.ImmersionBar;
|
||||
import com.navinfo.outdoor.util.NetWorkUtils;
|
||||
import com.umeng.message.PushAgent;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Timer;
|
||||
@ -40,6 +41,8 @@ public abstract class BaseActivity extends AppCompatActivity {
|
||||
@Override
|
||||
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
//应用活跃统计
|
||||
PushAgent.getInstance(this).onAppStart();
|
||||
// setScreenRoate(true);
|
||||
//初始化,默认透明状态栏和黑色导航栏
|
||||
ImmersionBar.with(this).init();
|
||||
|
@ -100,7 +100,7 @@ public abstract class BaseFragment extends Fragment implements FragmentBackHandl
|
||||
if (alertDialog!=null) {
|
||||
alertDialog.dismiss();
|
||||
}
|
||||
alertDialog = new AlertDialog.Builder(getActivity()).create();
|
||||
alertDialog = new AlertDialog.Builder(getContext()).create();
|
||||
alertDialog.getWindow().setBackgroundDrawable(new ColorDrawable());
|
||||
alertDialog.setCancelable(false);
|
||||
alertDialog.setOnKeyListener((dialog, keyCode, event) -> {
|
||||
|
File diff suppressed because one or more lines are too long
@ -90,7 +90,7 @@ public class TaskPrefectureBean {
|
||||
private Integer fid;
|
||||
private Integer updatepid;
|
||||
private String updatetime;
|
||||
private Object status;
|
||||
private Integer status;
|
||||
|
||||
public Integer getId() {
|
||||
return id;
|
||||
@ -172,11 +172,11 @@ public class TaskPrefectureBean {
|
||||
this.updatetime = updatetime;
|
||||
}
|
||||
|
||||
public Object getStatus() {
|
||||
public Integer getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(Object status) {
|
||||
public void setStatus(Integer status) {
|
||||
this.status = status;
|
||||
}
|
||||
}
|
||||
|
@ -5,12 +5,12 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
import android.os.Bundle;
|
||||
import android.os.Message;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.Toast;
|
||||
|
||||
import androidx.recyclerview.widget.DividerItemDecoration;
|
||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
|
||||
import com.github.lazylibrary.util.FileUtils;
|
||||
@ -18,10 +18,8 @@ import com.lzy.okgo.model.HttpParams;
|
||||
import com.navinfo.outdoor.R;
|
||||
import com.navinfo.outdoor.activity.FragmentManagement;
|
||||
import com.navinfo.outdoor.adapter.CapacityEvaluationAdapter;
|
||||
|
||||
import com.navinfo.outdoor.api.Constant;
|
||||
import com.navinfo.outdoor.base.BaseFragment;
|
||||
|
||||
import com.navinfo.outdoor.bean.TaskPrefectureBean;
|
||||
import com.navinfo.outdoor.http.Callback;
|
||||
import com.navinfo.outdoor.http.HttpInterface;
|
||||
@ -31,7 +29,9 @@ import com.jcodecraeer.xrecyclerview.XRecyclerView;
|
||||
import com.navinfo.outdoor.util.FlushTokenUtil;
|
||||
import com.umeng.umcrash.UMCrash;
|
||||
|
||||
import org.json.JSONObject;
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.greenrobot.eventbus.Subscribe;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.io.File;
|
||||
import java.text.DateFormat;
|
||||
@ -63,6 +63,14 @@ public class CapacityEvaluationFragment extends BaseFragment implements View.OnC
|
||||
return R.layout.fragment_capacity_evaluation;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onStart() {
|
||||
super.onStart();
|
||||
if (!EventBus.getDefault().isRegistered(this)) {//加上判断
|
||||
EventBus.getDefault().register(this);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initView() {
|
||||
super.initView();
|
||||
@ -73,8 +81,6 @@ public class CapacityEvaluationFragment extends BaseFragment implements View.OnC
|
||||
capacityEvaluationRecycler.setRefreshProgressStyle(ProgressStyle.BallSpinFadeLoader);
|
||||
capacityEvaluationRecycler.setLoadingMoreProgressStyle(ProgressStyle.BallRotate);
|
||||
//取消上拉加载,刷新功能
|
||||
/*capacityEvaluationRecycler.setPullRefreshEnabled(false);
|
||||
capacityEvaluationRecycler.setLoadingMoreEnabled(false);*/
|
||||
capacityEvaluationAdapter = new CapacityEvaluationAdapter(capacityList, getActivity());
|
||||
capacityEvaluationRecycler.setAdapter(capacityEvaluationAdapter);
|
||||
capacityEvaluationRecycler.getDefaultFootView().setNoMoreHint("加载成功");
|
||||
@ -102,6 +108,14 @@ public class CapacityEvaluationFragment extends BaseFragment implements View.OnC
|
||||
});
|
||||
}
|
||||
|
||||
@Subscribe
|
||||
public void onEvent(@NotNull Message data) {
|
||||
if (data.what == Constant.CAPACITY_EVALUATION) {
|
||||
capacityPage = 1;
|
||||
initNewWork(true);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initData() {
|
||||
super.initData();
|
||||
@ -163,7 +177,7 @@ public class CapacityEvaluationFragment extends BaseFragment implements View.OnC
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")) {
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
@ -228,6 +242,8 @@ public class CapacityEvaluationFragment extends BaseFragment implements View.OnC
|
||||
|
||||
@Override
|
||||
public void onDestroy() {
|
||||
if (EventBus.getDefault().isRegistered(this))//加上判断
|
||||
EventBus.getDefault().unregister(this);
|
||||
super.onDestroy();
|
||||
capacityEvaluationBuilder.append("onDestroy ");
|
||||
capacityEvaluationBuilder.append("\r\n");
|
||||
|
@ -4,7 +4,9 @@ import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
import android.os.Bundle;
|
||||
import android.os.Message;
|
||||
import android.util.Log;
|
||||
import android.view.KeyEvent;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.ImageView;
|
||||
@ -39,6 +41,7 @@ import com.kongzue.dialog.v3.MessageDialog;
|
||||
import com.navinfo.outdoor.util.FlushTokenUtil;
|
||||
import com.navinfo.outdoor.util.TimestampUtil;
|
||||
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.json.JSONException;
|
||||
|
||||
import java.io.File;
|
||||
@ -64,9 +67,8 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
private Gson gson;
|
||||
private File logFile;
|
||||
private StringBuilder capacityMeasureBuilder;
|
||||
private Button btnSubmit;
|
||||
private TextView tvCapacity;
|
||||
|
||||
private Button btnSubmit;
|
||||
|
||||
public static CapacityMeasurementFragment newInstance(Bundle bundle) {
|
||||
CapacityMeasurementFragment fragment = new CapacityMeasurementFragment();
|
||||
@ -82,7 +84,7 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
@Override
|
||||
protected void initView() {
|
||||
super.initView();
|
||||
ImageView ivMeasurementFinish = findViewById(R.id.iv_measurement_finish);
|
||||
ImageView ivMeasurementFinish = findViewById(R.id.iv_measurement_finish);
|
||||
ivMeasurementFinish.setOnClickListener(this);
|
||||
tvCapacity = findViewById(R.id.tv_capacity_measurement);
|
||||
RecyclerView capacityMeasurementRel = findViewById(R.id.capacity_measurementRel);
|
||||
@ -127,7 +129,7 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
private void initNetWorks() {
|
||||
showLoadingDialog();
|
||||
String id = Objects.requireNonNull(getActivity()).getIntent().getStringExtra("id");
|
||||
if (id==null){
|
||||
if (id == null) {
|
||||
return;
|
||||
}
|
||||
HttpParams httpParams = new HttpParams();
|
||||
@ -145,32 +147,34 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
public void onSuccess(MeasureBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
String title = response.getBody().getTitle();
|
||||
if (title!=null){
|
||||
if (title != null) {
|
||||
tvCapacity.setText(title);
|
||||
}
|
||||
//单选
|
||||
if (response.getBody().getMultiChoice() != null) {
|
||||
List<MeasureBean.BodyBean.MultiChoiceBean> multiChoice = response.getBody().getMultiChoice();
|
||||
for (int i = 0; i < multiChoice.size(); i++) {
|
||||
baleen.add(new BolBean(multiChoice.get(i).getId(), multiChoice.get(i).getQuestion(), multiChoice.get(i).getOption(), true));
|
||||
examId = multiChoice.get(i).getExamId();
|
||||
}
|
||||
}
|
||||
//多选
|
||||
if (response.getBody().getSingleChoice() != null) {
|
||||
List<MeasureBean.BodyBean.SingleChoiceBean> singleChoice = response.getBody().getSingleChoice();
|
||||
for (int i = 0; i < singleChoice.size(); i++) {
|
||||
baleen.add(new BolBean(singleChoice.get(i).getId(), singleChoice.get(i).getQuestion(), singleChoice.get(i).getOption(), false));
|
||||
baleen.add(new BolBean(singleChoice.get(i).getId(), singleChoice.get(i).getQuestion(), singleChoice.get(i).getOption(), true));
|
||||
examId = singleChoice.get(i).getExamId();
|
||||
}
|
||||
}
|
||||
//多选
|
||||
if (response.getBody().getMultiChoice() != null) {
|
||||
List<MeasureBean.BodyBean.MultiChoiceBean> multiChoice = response.getBody().getMultiChoice();
|
||||
for (int i = 0; i < multiChoice.size(); i++) {
|
||||
baleen.add(new BolBean(multiChoice.get(i).getId(), multiChoice.get(i).getQuestion(), multiChoice.get(i).getOption(), false));
|
||||
examId = multiChoice.get(i).getExamId();
|
||||
}
|
||||
}
|
||||
if (baleen != null) {
|
||||
if (baleen.size()>0){
|
||||
if (baleen.size() > 0) {
|
||||
capacityMeasureAdapter.setMeasureList(baleen);
|
||||
}/*else {
|
||||
btnSubmit.setVisibility(View.VISIBLE);
|
||||
tvCapacity.setVisibility(View.VISIBLE);
|
||||
} else {
|
||||
btnSubmit.setVisibility(View.GONE);
|
||||
tvCapacity.setVisibility(View.GONE);
|
||||
}*/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -179,12 +183,11 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")){
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}else {
|
||||
} else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -194,96 +197,103 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
switch (v.getId()) {
|
||||
case R.id.iv_measurement_finish:
|
||||
capacityMeasureBuilder.append(TimestampUtil.time()).append(",").append("点击了返回的按钮 ,");
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = Constant.CAPACITY_EVALUATION;
|
||||
EventBus.getDefault().post(obtain);
|
||||
Objects.requireNonNull(getActivity()).finish();
|
||||
break;
|
||||
case R.id.btn:
|
||||
capacityMeasureBuilder.append(TimestampUtil.time()).append(",").append("点击了提交的的按钮 ,");
|
||||
if (baleen.size() != 0) {
|
||||
Map<String, String> checkedMap = capacityMeasureAdapter.getCheckedMap();
|
||||
for (int i = 0; i < baleen.size(); i++) {
|
||||
final String id = baleen.get(i).getId();
|
||||
if (!checkedMap.containsKey(id) || checkedMap.get(id) == null || ("").equals(checkedMap.get(id))) {
|
||||
Toast.makeText(getActivity(), "有题目未填写答案,请仔细检查!", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
if (baleen.size() != 0) {
|
||||
Map<String, String> checkedMap = capacityMeasureAdapter.getCheckedMap();
|
||||
for (int i = 0; i < baleen.size(); i++) {
|
||||
final String id = baleen.get(i).getId();
|
||||
if (!checkedMap.containsKey(id) || checkedMap.get(id) == null || ("").equals(checkedMap.get(id))) {
|
||||
Toast.makeText(getActivity(), "有题目未填写答案,请仔细检查!", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
for (Map.Entry<String, String> entry : checkedMap.entrySet()) {
|
||||
ExamBean examBean = new ExamBean();
|
||||
examBean.setId(entry.getKey());
|
||||
String value = entry.getValue();
|
||||
String[] values = value.split(",");
|
||||
List<String> answerList = new ArrayList<>();
|
||||
for (String s : values) {
|
||||
if (s != null && !s.equals("")) {
|
||||
answerList.add(s);
|
||||
}
|
||||
}
|
||||
examBean.setAnswer(answerList);
|
||||
examBeans.add(examBean);
|
||||
}
|
||||
initExamSubmit();
|
||||
} else {
|
||||
Toast.makeText(getActivity(), "无数据,无法提交", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
for (Map.Entry<String, String> entry : checkedMap.entrySet()) {
|
||||
ExamBean examBean = new ExamBean();
|
||||
examBean.setId(entry.getKey());
|
||||
String value = entry.getValue();
|
||||
String[] values = value.split(",");
|
||||
List<String> answerList = new ArrayList<>();
|
||||
for (String s : values) {
|
||||
if (s != null && !s.equals("")) {
|
||||
answerList.add(s);
|
||||
}
|
||||
}
|
||||
examBean.setAnswer(answerList);
|
||||
examBeans.add(examBean);
|
||||
}
|
||||
initExamSubmit();
|
||||
} else {
|
||||
Toast.makeText(getActivity(), "无数据,无法提交", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void initExamSubmit() {
|
||||
private void initExamSubmit() {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("examId", examId);//试卷ID
|
||||
map.put("answerList", examBeans);//答案列表
|
||||
String json = gson.toJson(map);
|
||||
examBeans.clear();
|
||||
showLoadingDialog();
|
||||
OkGoBuilder.getInstance()
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder.getInstance()
|
||||
.time(30)
|
||||
.Builder(getActivity())
|
||||
.url(HttpInterface.EXAM_SUBMIT)
|
||||
.cls(ExamSubmitBean.class)
|
||||
.json(json)
|
||||
.params(new HttpParams())
|
||||
.token(Constant.ACCESS_TOKEN)
|
||||
.postCapacity(new Callback<ExamSubmitBean>() {
|
||||
@Override
|
||||
public void onSuccess(ExamSubmitBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
if (response.getCode() == 200) {
|
||||
String message = null;
|
||||
if (response.getBody() == 0) {
|
||||
message = "不通过";
|
||||
} else if (response.getBody()==1){
|
||||
message = "通过";
|
||||
}
|
||||
DialogSettings.style = DialogSettings.STYLE.STYLE_IOS;
|
||||
MessageDialog.show((AppCompatActivity) Objects.requireNonNull(getActivity()), "提示", message+"", "确定").setOkButton(new OnDialogButtonClickListener() {
|
||||
.token(Constant.ACCESS_TOKEN);
|
||||
okGoBuilder.postCapacity(new Callback<ExamSubmitBean>() {
|
||||
@Override
|
||||
public void onSuccess(ExamSubmitBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
if (response.getCode() == 200) {
|
||||
String message = null;
|
||||
if (response.getBody() == 0) {
|
||||
message = "不通过";
|
||||
} else if (response.getBody() == 1) {
|
||||
message = "通过";
|
||||
}
|
||||
DialogSettings.style = DialogSettings.STYLE.STYLE_IOS;
|
||||
DialogSettings.cancelable = false;
|
||||
MessageDialog.show((AppCompatActivity) Objects
|
||||
.requireNonNull(getActivity()), "提示", message, "确定")
|
||||
.setOkButton(new OnDialogButtonClickListener() {
|
||||
@Override
|
||||
public boolean onClick(BaseDialog baseDialog, View v) {
|
||||
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = Constant.CAPACITY_EVALUATION;
|
||||
EventBus.getDefault().post(obtain);
|
||||
getActivity().finish();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}else if (response.getCode()==230){
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
}else {
|
||||
Toast.makeText(getActivity(), response.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
Log.d("TAG", "onSuccess: " + response.toString());
|
||||
}
|
||||
} else if (response.getCode() == 230) {
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
} else {
|
||||
Toast.makeText(getActivity(), response.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")){
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
});
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -305,4 +315,5 @@ public class CapacityMeasurementFragment extends BaseFragment implements View.On
|
||||
capacityMeasureBuilder.append("\r\n");
|
||||
FileUtils.writeFile(logFile.getAbsolutePath(), capacityMeasureBuilder.toString(), true);
|
||||
}
|
||||
|
||||
}
|
@ -78,40 +78,26 @@ import java.util.Objects;
|
||||
*/
|
||||
public class ChargingPileFragment extends BaseDrawerFragment implements View.OnClickListener {
|
||||
private EditText editDescribe;
|
||||
private TextView tvNameContent;
|
||||
private Button btnSaveLocal;
|
||||
private CheckBox checkBoxLife;
|
||||
private Spinner spinnerType, spinnerScutcheon, spinnerStake;
|
||||
String[] type = new String[]{"地上五层", "地上四层", "地上三层", "地上二层", "地上一层", "地下一层", "地下二层", "地下三层", "地下四层", "地下五层"};
|
||||
String[] scutcheon = new String[]{"存在", "不存在"};
|
||||
String[] spanner = new String[]{"存在", "不存在"};
|
||||
String[] stake = new String[]{"可以使用", "不可使用", "维修中", "建设中", "规划中"};
|
||||
private RelativeLayout rlPanorama, rlCoding, rlEquipment, rlFacility, rlUsable, rlAvailable, rlParking, rlNumber, rlScutcheon, rlDevice;
|
||||
private Spinner spinnerType, spinnerScutcheon, spinnerStake ,spinnerExist;
|
||||
private String[] type = new String[]{"地上五层", "地上四层", "地上三层", "地上二层", "地上一层", "地下一层", "地下二层", "地下三层", "地下四层", "地下五层"};
|
||||
private String[] scutcheon = new String[]{"存在", "不存在"};
|
||||
private String[] spanner = new String[]{"存在", "不存在"};
|
||||
private String[] stake = new String[]{"可以使用", "不可使用", "维修中", "建设中", "规划中"};
|
||||
private RelativeLayout rlPanorama, rlCoding, rlEquipment, rlFacility, rlUsable, rlAvailable, rlParking, rlNumber, rlScutcheon, rlDevice,relative_exist,linearType, linearScutcheon, linearStake, linearRelative;
|
||||
private ImageView ivPanorama, ivCoding, ivEquipment, ivFacility, ivUsable, ivAvailable, ivParking, ivNumber, ivScutcheon, ivDevice;
|
||||
private TextView tvPanorama, tvCoding, tvEquipment, tvFacility, tvUsable, tvAvailable, tvParking, tvNumber, tvScutcheon, tvDevice;
|
||||
private int exist = 0;
|
||||
private int cp_floor = 1;
|
||||
private int sign_exist = 0;
|
||||
private int cp_availableState = 0;
|
||||
private TextView tvPanorama, tvCoding, tvEquipment, tvFacility, tvUsable, tvAvailable, tvParking, tvNumber, tvScutcheon, tvDevice,tvText,tvNameContent;
|
||||
private int exist = 0, cp_floor = 1, sign_exist = 0, cp_availableState = 0;
|
||||
private String buffer1 = "", buffer2 = "", buffer3 = "", buffer4 = "", buffer5 = "";
|
||||
|
||||
private CheckBox checkButton1, checkButton2, checkButton3, checkButton4, checkButton5;
|
||||
private String pid;
|
||||
private String station;
|
||||
private CheckBox checkBoxLife,checkButton1, checkButton2, checkButton3, checkButton4, checkButton5;
|
||||
private String pid, station;
|
||||
private LatLng latLng;
|
||||
private Marker markerPile;
|
||||
private Point screenPilePositions;
|
||||
private ChargingPileEntity chargingPileEntity;
|
||||
private File logFile;
|
||||
private StringBuilder chargingPileBuilder;
|
||||
private Spinner spinnerExist;
|
||||
private RelativeLayout relative_exist;
|
||||
private TextView tvText;
|
||||
private LinearLayout llCharging;
|
||||
private RelativeLayout linearType;
|
||||
private RelativeLayout linearScutcheon;
|
||||
private RelativeLayout linearStake;
|
||||
private RelativeLayout linearRelative;
|
||||
|
||||
public static ChargingPileFragment newInstance(Bundle bundle) {
|
||||
ChargingPileFragment fragment = new ChargingPileFragment();
|
||||
@ -852,49 +838,6 @@ public class ChargingPileFragment extends BaseDrawerFragment implements View.OnC
|
||||
}
|
||||
}
|
||||
|
||||
/* private void initPileMarker(LatLng latLng) {
|
||||
BitmapDescriptor pileDescriptor = BitmapDescriptorFactory.fromResource(R.mipmap.icon_operation);
|
||||
if (markerPile == null) {
|
||||
markerPile = tencentMap.addMarker(new MarkerOptions(latLng).icon(pileDescriptor));
|
||||
markerPile.setZIndex(MARKER_BIG);
|
||||
}
|
||||
|
||||
CameraUpdate cameraSigma = CameraUpdateFactory.newCameraPosition(new CameraPosition(
|
||||
latLng, //中心点坐标,地图目标经纬度
|
||||
tencentMap.getCameraPosition().zoom, //目标缩放级别
|
||||
tencentMap.getCameraPosition().tilt, //目标倾斜角[0.0 ~ 45.0] (垂直地图时为0)
|
||||
tencentMap.getCameraPosition().bearing)); //目标旋转角 0~360° (正北方为0)
|
||||
tencentMap.animateCamera(cameraSigma, new TencentMap.CancelableCallback() {
|
||||
@Override
|
||||
public void onFinish() {
|
||||
screenPilePositions = tencentMap.getProjection().toScreenLocation(latLng);
|
||||
sliding_layout.setPanelState(SlidingUpPanelLayout.PanelState.COLLAPSED);
|
||||
//创建Marker对象之前,设置属性
|
||||
if (markerPile != null) {
|
||||
markerPile.setFixingPoint(screenPosition.x, screenPosition.y);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCancel() {
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private void initCheckedPileMarker(int poiWord) {
|
||||
if (screenPilePositions != null) {
|
||||
sliding_layout.setPanelState(SlidingUpPanelLayout.PanelState.COLLAPSED);
|
||||
LatLng latLng = tencentMap.getProjection().fromScreenLocation(screenPilePositions);
|
||||
markerPile.setPosition(latLng);
|
||||
markerPile.setFixingPointEnable(false);
|
||||
Constant.markerLatlng = latLng;
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = poiWord;
|
||||
obtain.obj = latLng;
|
||||
EventBus.getDefault().post(obtain);
|
||||
}
|
||||
}*/
|
||||
|
||||
public void setCList(ArrayList<String> list) {
|
||||
switch (list.size()) {
|
||||
case 1:
|
||||
@ -1131,7 +1074,6 @@ public class ChargingPileFragment extends BaseDrawerFragment implements View.OnC
|
||||
File equipmentFile = PhotoUtils.showPhotoFile("c", latLng);
|
||||
intentEquipment.putExtra(Constant.INTENT_PHOTO_PATH, equipmentFile.getPath());
|
||||
startActivityForResult(intentEquipment, 103);
|
||||
|
||||
break;
|
||||
case R.id.rl_facility:
|
||||
chargingPileBuilder.append("点击了设备标牌进行拍照,");
|
||||
@ -1186,57 +1128,6 @@ public class ChargingPileFragment extends BaseDrawerFragment implements View.OnC
|
||||
}
|
||||
}
|
||||
|
||||
/* private void chargingPileByWork(ChargingPileEntity chargingPileEntity) {
|
||||
showLoadingDialog();
|
||||
HttpParams httpParams = new HttpParams();
|
||||
httpParams.put("taskId", taskId);
|
||||
httpParams.put("name", chargingPileEntity.getName());
|
||||
httpParams.put("existence", chargingPileEntity.getExist());
|
||||
httpParams.put("geo", chargingPileEntity.getP());
|
||||
httpParams.put("memo", chargingPileEntity.getMemo());
|
||||
httpParams.put("ffid", chargingPileEntity.getFid());
|
||||
HashMap<String, Object> hashMap = new HashMap<>();
|
||||
hashMap.put("cp_openType",chargingPileEntity.getCp_openType());
|
||||
hashMap.put("cp_floor",chargingPileEntity.getCp_floor());
|
||||
hashMap.put("cp_availableState",chargingPileEntity.getCp_availableState());
|
||||
hashMap.put("sign_exist",chargingPileEntity.getSign_exist());
|
||||
httpParams.put("detail", String.valueOf(hashMap));
|
||||
OkGoBuilder.getInstance()
|
||||
.Builder(getActivity())
|
||||
.url(HttpInterface.SUBMIT_CSTASK)
|
||||
.method(OkGoBuilder.GET)
|
||||
.cls(ChargingPileSaveBean.class)
|
||||
.params(httpParams)
|
||||
.callback(new Callback<ChargingPileSaveBean>() {
|
||||
@Override
|
||||
public void onSuccess(ChargingPileSaveBean chargingPileSaveBean, int id) {
|
||||
dismissLoadingDialog();
|
||||
chargingPileBody = chargingPileSaveBean.getBody();
|
||||
Toast.makeText(getActivity(), "保存成功", Toast.LENGTH_SHORT).show();
|
||||
Log.d("TAG", "onSuccess: " + chargingPileSaveBean.getBody());
|
||||
phoneList();
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = Constant.CHARGING_PILE_BODY;
|
||||
obtain.obj = chargingPileBody;
|
||||
EventBus.getDefault().post(obtain);
|
||||
|
||||
Message obtain1 = Message.obtain();
|
||||
obtain1.what = Constant.CHARGING_PILE_PHOTO;
|
||||
obtain1.obj = phoneLists;
|
||||
EventBus.getDefault().post(obtain1);
|
||||
getActivity().onBackPressed();
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
Toast.makeText(getActivity(), e.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
}).build();
|
||||
}*/
|
||||
|
||||
@Override
|
||||
public void onSaveInstanceState(@NonNull Bundle outState) {
|
||||
super.onSaveInstanceState(outState);
|
||||
|
@ -106,24 +106,21 @@ import okhttp3.Response;
|
||||
*/
|
||||
public class ChargingStationFragment extends BaseDrawerFragment implements View.OnClickListener {
|
||||
private EditText editDescribe;
|
||||
private RelativeLayout rlPanorama, rlName, rlInternalPhotos, rlElse, rlScutcheon, rlNull;
|
||||
private RelativeLayout rlPanorama, rlName, rlInternalPhotos, rlElse, rlScutcheon, rlNull,linearExist;
|
||||
private ImageView ivPanorama, ivName, ivInternal, ivElse, ivScutcheon;
|
||||
private TextView tvExamine, tvPanorama, tvNamePic, tvInternal, tvElse, tvScutcheon;
|
||||
private EditText editNameContent, editSiteContent;
|
||||
private ArrayList<PhoneBean> poiBeans;
|
||||
private Button btnSaveLocal, btnUploading;
|
||||
private CheckBox checkBoxLife;
|
||||
private Spinner spinnerType;
|
||||
private Spinner spinnerType,spinnerExist;
|
||||
String[] caye = new String[]{"充电站", "充换电站", "充电桩组", "换电站"};//1."充电站"2 "充换电站"3 "充电桩组"4 "换电站"5 ,
|
||||
String[] spinner = new String[]{"存在", "不存在", "无法验证"};
|
||||
private int existence = 0;
|
||||
private LinearLayout linearChargingPile;
|
||||
private LinearLayout linearChargingPile,linearContact;
|
||||
private ChargingPileAdapter chargingPileAdapter;
|
||||
private int station_type = 1;
|
||||
private LatLng latLng;
|
||||
private RelativeLayout linearExist;
|
||||
private Spinner spinnerExist;
|
||||
private LinearLayout linearContact;
|
||||
private ContactView contactView;
|
||||
private ArrayList<File> chargingStationList;
|
||||
private NestedScrollView nestedScrollView;
|
||||
@ -728,11 +725,9 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
});
|
||||
}
|
||||
}).start();
|
||||
|
||||
if (showPoiEntity.getTaskStatus() == 3) {
|
||||
disables();
|
||||
}
|
||||
|
||||
initPile();
|
||||
}
|
||||
}
|
||||
@ -809,7 +804,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")) {
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
@ -1065,7 +1060,6 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
break;
|
||||
case R.id.rl_panorama:
|
||||
chargingStationBuilder.append(TimestampUtil.time()).append("点击了全景照片进行拍照 ,");
|
||||
findingDuplicateByWork();
|
||||
Intent intentPanorama = new Intent(getActivity(), PhotographActivity.class);
|
||||
File PanoramaFile = PhotoUtils.showPhotoFile("a", latLng);
|
||||
intentPanorama.putExtra(Constant.INTENT_PHOTO_PATH, PanoramaFile.getPath());
|
||||
@ -1121,9 +1115,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
EventBus.getDefault().post(obtain);
|
||||
}
|
||||
|
||||
/*
|
||||
* 根据充电站数据检查充电桩数据,如果没有网络保存,则批量网络保存
|
||||
*/
|
||||
/* 根据充电站数据检查充电桩数据,如果没有网络保存,则批量网络保存*/
|
||||
private void saveChargingPileByChargingStation(PoiEntity chargingStationPoiEntity) {
|
||||
if (chargingStationPoiEntity != null) {
|
||||
List<ChargingPileEntity> chargingPileEntityList = PoiDatabase.getInstance(getActivity()).getChargingPileDao().getChargingPileByStationId(chargingStationPoiEntity.getId());
|
||||
@ -1138,7 +1130,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
}
|
||||
|
||||
private void initRoadSaveLocal(boolean isLocal) {
|
||||
private void initRoadSaveLocal(boolean isLocal) {
|
||||
XXPermissions.with(this)
|
||||
//读写权限
|
||||
.permission(Permission.MANAGE_EXTERNAL_STORAGE)
|
||||
@ -1213,10 +1205,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
WaitDialog.dismiss(1000);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* 根据充电站数据检查充电桩数据,如果没有网络保存,则批量网络上传
|
||||
*/
|
||||
/*根据充电站数据检查充电桩数据,如果没有网络保存,则批量网络上传*/
|
||||
private void saveChargingPileUploadChargingStation(PoiEntity chargingStationPoiEntity) {
|
||||
if (chargingStationPoiEntity != null) {
|
||||
// 首先批量上传充电桩数据
|
||||
@ -1230,10 +1219,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* 上传充电桩数据
|
||||
*/
|
||||
/*上传充电桩数据*/
|
||||
private void chargingPileUploadNetWork(ChargingPileEntity chargingPileEntity) {
|
||||
List<File> chargingPileFileList = new ArrayList<>();
|
||||
if (chargingPileEntity.getPhotos() != null && !chargingPileEntity.getPhotos().isEmpty()) {
|
||||
@ -1270,7 +1256,6 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void stationUploadByNetWork(PoiEntity poiEntity, ArrayList<File> chargingStationList) {
|
||||
if (poiEntity == null) {
|
||||
Toast.makeText(getActivity(), "没有保存本地", Toast.LENGTH_SHORT).show();
|
||||
@ -1308,10 +1293,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
}).start();
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存充电站数据到服务器
|
||||
*/
|
||||
/*保存充电站数据到服务器*/
|
||||
private void chargingStationSaveByWork(PoiEntity poiEntity) {
|
||||
HttpParams httpParams = new HttpParams();
|
||||
httpParams.put("taskId", poiEntity.getTaskId());
|
||||
@ -1386,7 +1368,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")) {
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
@ -1478,7 +1460,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")) {
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
@ -1510,9 +1492,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
initStationSharePre();
|
||||
}
|
||||
|
||||
/**
|
||||
* 防止当页面崩溃后出现数据丢失
|
||||
*/
|
||||
/*防止当页面崩溃后出现数据丢失*/
|
||||
public void initStationSharePre() {
|
||||
//获取SharedPreferences对象,方法中两个参数的意思为:第一个name
|
||||
//表示文件名,系统将会在/dada/dada/包名/shared_prefs目录下生成
|
||||
@ -1626,7 +1606,8 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
hashMap.put("cp_floor", chargingPileEntity.getCp_floor());
|
||||
hashMap.put("cp_availableState", chargingPileEntity.getCp_availableState());
|
||||
hashMap.put("sign_exist", chargingPileEntity.getSign_exist());
|
||||
httpParams.put("detail", String.valueOf(hashMap));
|
||||
String s = new Gson().toJson(hashMap);
|
||||
httpParams.put("detail",s);
|
||||
try {
|
||||
Response execute = OkGoBuilder
|
||||
.getInstance()
|
||||
@ -1639,14 +1620,11 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
String responseBodyStr = execute.body().string();
|
||||
Gson gson = new Gson();
|
||||
ChargingPileSaveBean chargingPileSaveBean = gson.fromJson(responseBodyStr, ChargingPileSaveBean.class);
|
||||
if (chargingPileSaveBean.getCode() != 200) {
|
||||
return;
|
||||
} else {
|
||||
if (chargingPileSaveBean.getCode() == 200) {
|
||||
chargingPileEntity.setBodyId(chargingPileSaveBean.getBody());
|
||||
InsertAndUpdateUtils.getInstance().insertOrUpdateChargingPile(getActivity(), chargingPileEntity); // 更新当前充电桩的bodyId
|
||||
Log.d("TAGSS", "saveChargingPileByWork: 充电桩" + chargingPileEntity.getName() + "保存成功");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
} catch (IOException e) {
|
||||
@ -1707,7 +1685,6 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
removablesLocality.get(i).remove();
|
||||
}
|
||||
removablesLocality.clear();
|
||||
|
||||
chargingStationBuilder.append(TimestampUtil.time()).append("onDestroy");
|
||||
chargingStationBuilder.append("\r\n");
|
||||
FileUtils.writeFile(logFile.getAbsolutePath(), chargingStationBuilder.toString(), true);
|
||||
@ -1780,7 +1757,7 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")) {
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
@ -1789,7 +1766,6 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
} else {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@ -1799,7 +1775,6 @@ public class ChargingStationFragment extends BaseDrawerFragment implements View.
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
|
@ -175,12 +175,8 @@ public class EventPrefectureFragment extends BaseFragment implements View.OnClic
|
||||
eventRecycler.setLayoutManager(new LinearLayoutManager(getActivity()));
|
||||
eventRecycler.setRefreshProgressStyle(ProgressStyle.BallSpinFadeLoader);
|
||||
eventRecycler.setLoadingMoreProgressStyle(ProgressStyle.BallRotate);
|
||||
//取消上拉加载,刷新功能。
|
||||
// eventRecycler.setPullRefreshEnabled(false);
|
||||
// eventRecycler.setLoadingMoreEnabled(false);
|
||||
eventPrefectureAdapter = new EventPrefectureAdapter(taskExplainBean,getActivity());
|
||||
eventRecycler.setAdapter(eventPrefectureAdapter);
|
||||
|
||||
eventRecycler.setLoadingListener(new XRecyclerView.LoadingListener() {
|
||||
@Override
|
||||
public void onRefresh() {
|
||||
@ -193,7 +189,6 @@ public class EventPrefectureFragment extends BaseFragment implements View.OnClic
|
||||
initNetwork(false);
|
||||
}
|
||||
});
|
||||
|
||||
eventPrefectureAdapter.setClickItem(new EventPrefectureAdapter.clickItem() {
|
||||
@Override
|
||||
public void item(int aInt) {
|
||||
|
@ -67,7 +67,7 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
private TextView tvType, tvExclusive, tvPhotograph, tvNumber;
|
||||
private FilterAdapter filterAdapter;
|
||||
private ArrayList<PoiEntity> poiEntities;
|
||||
private ArrayList<PoiEntity> btnChock;
|
||||
private List<PoiEntity> btnChock;
|
||||
private CheckBox checkOk;
|
||||
private File logFile;
|
||||
private StringBuilder filterBuilder;
|
||||
@ -98,7 +98,6 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
Bundle arguments = getArguments();
|
||||
if (arguments != null) {
|
||||
isSliding = arguments.getBoolean("isSliding", true);
|
||||
Log.d("TAG", "onCaress's: " + isSliding);
|
||||
}
|
||||
if (isSliding) {
|
||||
// 监听到返回按钮点击事件
|
||||
@ -106,8 +105,6 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
obtain.what = Constant.TREASURE_FRAGMENT;
|
||||
obtain.obj = isSliding;
|
||||
EventBus.getDefault().post(obtain);
|
||||
|
||||
|
||||
Message obtain1 = Message.obtain();
|
||||
obtain1.what = Constant.JOB_WORD_MONITOR;
|
||||
obtain1.obj = true;
|
||||
@ -275,7 +272,7 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
tvType.setText("未领取");
|
||||
} else if (Constant.TASK_STARTUP == 1) {
|
||||
tvType.setText("已领取");
|
||||
}else if (Constant.TASK_STARTUP ==2){
|
||||
} else if (Constant.TASK_STARTUP == 2) {
|
||||
tvType.setText("已领取(网络)");
|
||||
}
|
||||
Button btnFilter = findViewById(R.id.btn_filter);
|
||||
@ -398,7 +395,6 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
obtains.what = Constant.JOB_WORD_MONITOR;
|
||||
obtains.obj = true;
|
||||
EventBus.getDefault().post(obtains);
|
||||
|
||||
onBackPressed();
|
||||
break;
|
||||
case R.id.cl_number:
|
||||
@ -463,15 +459,11 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
}
|
||||
});
|
||||
break;
|
||||
/*
|
||||
1 "POI"
|
||||
2 "充电站"
|
||||
3 "POI录像"
|
||||
4 "道路录像"
|
||||
5 "其他"
|
||||
6 "面状任务"
|
||||
*/
|
||||
|
||||
case R.id.cl_exclusive:
|
||||
/*
|
||||
*1 "POI",2 "充电站",3 "POI录像",4 "道路录像",5 "其他",6 "面状任务"
|
||||
*/
|
||||
filterBuilder.append(TimestampUtil.time()).append(",").append("点击了任务类型的按钮 ,");
|
||||
BottomMenu.show((AppCompatActivity) Objects.requireNonNull(getContext()), new String[]{"全部", "POI", "充电站", "POI录像", "道路录像", "其他", "面状任务"}, new OnMenuItemClickListener() {
|
||||
@Override
|
||||
@ -514,9 +506,12 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
}
|
||||
});
|
||||
break;
|
||||
case R.id.cl_type://任务状态 0.未领取 1.已领取,2.未保存(保存到本地但未提交成功),3.已保存(保存到本地提交成功),4已上传(结束采集),
|
||||
case R.id.cl_type:
|
||||
/*
|
||||
任务状态 0.未领取 1.已领取,2.未保存(保存到本地但未提交成功),3.已保存(保存到本地提交成功),4已上传(结束采集),
|
||||
*/
|
||||
filterBuilder.append(TimestampUtil.time()).append("点击了任务状态的按钮 ,");
|
||||
BottomMenu.show((AppCompatActivity) Objects.requireNonNull(getContext()), new String[]{"全部", "未领取", "已领取","已领取(网络)"/*, "未保存", "已保存"*/}, new OnMenuItemClickListener() {
|
||||
BottomMenu.show((AppCompatActivity) Objects.requireNonNull(getContext()), new String[]{"全部", "未领取", "已领取", "已领取(网络)"/*, "未保存", "已保存"*/}, new OnMenuItemClickListener() {
|
||||
@Override
|
||||
public void onClick(String text, int index) {
|
||||
tvType.setText(text);
|
||||
@ -563,41 +558,42 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
||||
.cls(FilterBatchBean.class)
|
||||
.url(HttpInterface.RECEIVE_TASK);
|
||||
okGoBuilder.getRequest(new Callback<FilterBatchBean>() {
|
||||
@Override
|
||||
public void onSuccess(FilterBatchBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
if (response.getCode()==200){
|
||||
List<FilterBatchBean.BodyBean.SuccessBean> success = response.getBody().getSuccess();
|
||||
for (int i = 0; i < success.size(); i++) {
|
||||
initType(success.get(i));
|
||||
}
|
||||
filterAdapter.setAddFilter(false);
|
||||
filterAdapter.notifyDataSetChanged();
|
||||
btnChock.clear();
|
||||
checkOk.setChecked(false);
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = Constant.JOB_WORD_MONITOR;
|
||||
obtain.obj = true;
|
||||
EventBus.getDefault().post(obtain);
|
||||
Toast.makeText(getContext(), "领取成功", Toast.LENGTH_SHORT).show();
|
||||
}else if (response.getCode()==230){
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
}else {
|
||||
Toast.makeText(getContext(), response.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
@Override
|
||||
public void onSuccess(FilterBatchBean response, int id) {
|
||||
dismissLoadingDialog();
|
||||
if (response.getCode() == 200) {
|
||||
List<FilterBatchBean.BodyBean.SuccessBean> success = response.getBody().getSuccess();
|
||||
for (int i = 0; i < success.size(); i++) {
|
||||
initType(success.get(i));
|
||||
}
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")|| message.contains("Read time out")){
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
});
|
||||
filterAdapter.setAddFilter(false);
|
||||
filterAdapter.notifyDataSetChanged();
|
||||
btnChock.clear();
|
||||
checkOk.setChecked(false);
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = Constant.JOB_WORD_MONITOR;
|
||||
obtain.obj = true;
|
||||
EventBus.getDefault().post(obtain);
|
||||
Toast.makeText(getContext(), "领取成功", Toast.LENGTH_SHORT).show();
|
||||
} else if (response.getCode() == 230) {
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
} else {
|
||||
Toast.makeText(getContext(), response.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -109,10 +109,10 @@ public class FindFragment extends BaseFragment implements View.OnClickListener {
|
||||
break;
|
||||
case R.id.linear_end:
|
||||
findBuilder.append(TimestampUtil.time()).append(",").append("点击了帮助中心:能力测评 ,");
|
||||
Toast.makeText(getContext(), "该功能以后上新,敬请期待", Toast.LENGTH_SHORT).show();
|
||||
/*Intent endIntent = new Intent(getActivity(), FragmentManagement.class);
|
||||
//Toast.makeText(getContext(), "该功能以后上新,敬请期待", Toast.LENGTH_SHORT).show();
|
||||
Intent endIntent = new Intent(getActivity(), FragmentManagement.class);
|
||||
endIntent.putExtra("tag", 11);
|
||||
startActivity(endIntent);*/
|
||||
startActivity(endIntent);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -189,8 +189,7 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
||||
|
||||
/**
|
||||
* 保存小数点后两位
|
||||
*
|
||||
* @param value
|
||||
* @param value value
|
||||
*/
|
||||
public static String format2(double value) {
|
||||
DecimalFormat df = new DecimalFormat("0.00");
|
||||
@ -282,13 +281,13 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
||||
return;
|
||||
} else {
|
||||
if (geometry > 50) {
|
||||
// Voice.sprat("注意在附近50米范围内进行采集",0);
|
||||
//Voice.sprat("注意在附近50米范围内进行采集",0);
|
||||
DialogSettings.style = DialogSettings.STYLE.STYLE_IOS;
|
||||
MessageDialog.show((AppCompatActivity) Objects.requireNonNull(getActivity()), "提示", "注意在任务附近50米范围内进行采集", "确定").setOnOkButtonClickListener(new OnDialogButtonClickListener() {
|
||||
@Override
|
||||
public boolean onClick(BaseDialog baseDialog, View v) {
|
||||
initGather();
|
||||
// Voice.sprat("注意在附近50米范围内进行采集",1);
|
||||
//Voice.sprat("注意在附近50米范围内进行采集",1);
|
||||
return false;
|
||||
}
|
||||
});
|
||||
@ -811,7 +810,6 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
||||
poiListEntity.setTelPhone(listBean.getTelephone());
|
||||
}
|
||||
}
|
||||
|
||||
poiListEntity.setTaskStatus(statusId);
|
||||
poiListEntity.setGeoWkt(listBean.getGeo());
|
||||
String encodeStr = listBean.getGeo();
|
||||
|
@ -49,7 +49,7 @@ import java.util.Objects;
|
||||
* 记录-已提交
|
||||
*/
|
||||
public class HasSubmitFragment extends BaseFragment implements View.OnClickListener {
|
||||
private TextView auditProcess, auditThrough, auditNotThrough, chargingAuditProcess, chargingAuditThrough, chargingAuditNotThrough, roadAuditProcess, roadAuditThrough, roadAuditNotThrough, otherAuditProcess, otherAuditThrough, otherAuditNotThrough, poiVideoAuditProcess, poiVideoAuditThrough, poiVideoAuditNotThrough;
|
||||
private TextView poiAuditProcess, poiAuditThrough, poiAuditNotThrough, chargingAuditProcess, chargingAuditThrough, chargingAuditNotThrough, roadAuditProcess, roadAuditThrough, roadAuditNotThrough, otherAuditProcess, otherAuditThrough, otherAuditNotThrough, poiVideoAuditProcess, poiVideoAuditThrough, poiVideoAuditNotThrough;
|
||||
private StringBuilder hasSubmitBuilder;
|
||||
private File logFile;
|
||||
private HasSubmitBean.BodyBean hasSubmitBeanBody;
|
||||
@ -77,9 +77,9 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
super.initView();
|
||||
ConstraintLayout clPoi = findViewById(R.id.cl_poi);
|
||||
clPoi.setOnClickListener(this);
|
||||
auditProcess = findViewById(R.id.audit_process);
|
||||
auditThrough = findViewById(R.id.audit_through);
|
||||
auditNotThrough = findViewById(R.id.audit_not_through);
|
||||
poiAuditProcess = findViewById(R.id.poi_audit_process);
|
||||
poiAuditThrough = findViewById(R.id.poi_audit_through);
|
||||
poiAuditNotThrough = findViewById(R.id.poi_audit_not_through);
|
||||
|
||||
ConstraintLayout clRoad = findViewById(R.id.cl_road);
|
||||
clRoad.setOnClickListener(this);
|
||||
@ -140,8 +140,8 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
httpParams.put("pageSize", 10);
|
||||
httpParams.put("pageNum", 1);
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder.getInstance()
|
||||
.time(30)
|
||||
.Builder(getActivity())
|
||||
.time(30)
|
||||
.url(HttpInterface.GET_COMMIT_LIST)
|
||||
.cls(HasSubmitBean.class)
|
||||
.params(httpParams)
|
||||
@ -158,13 +158,12 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
@SuppressLint("SetTextI18n")
|
||||
@Override
|
||||
public void run() {
|
||||
otherAuditProcess.setText(hasSubmitBeanBody.getAuditingCount() + "");
|
||||
otherAuditThrough.setText(hasSubmitBeanBody.getPassCount() + "");
|
||||
otherAuditNotThrough.setText(hasSubmitBeanBody.getNotPassCount() + "");
|
||||
otherAuditProcess.setText(String.valueOf(hasSubmitBeanBody.getAuditingCount()));
|
||||
otherAuditThrough.setText(String.valueOf(hasSubmitBeanBody.getPassCount()));
|
||||
otherAuditNotThrough.setText(String.valueOf(hasSubmitBeanBody.getNotPassCount()));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
} else if (hasSubmitBean.getCode() == 230) {
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
@ -232,9 +231,9 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
@SuppressLint("SetTextI18n")
|
||||
@Override
|
||||
public void run() {
|
||||
chargingAuditProcess.setText(hasSubmitBeanBody.getAuditingCount() + "");
|
||||
chargingAuditThrough.setText(hasSubmitBeanBody.getPassCount() + "");
|
||||
chargingAuditNotThrough.setText(hasSubmitBeanBody.getNotPassCount() + "");
|
||||
chargingAuditProcess.setText(String.valueOf(hasSubmitBeanBody.getAuditingCount()));
|
||||
chargingAuditThrough.setText(String.valueOf(hasSubmitBeanBody.getPassCount()));
|
||||
chargingAuditNotThrough.setText(String.valueOf(hasSubmitBeanBody.getNotPassCount()));
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -305,9 +304,9 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
@SuppressLint("SetTextI18n")
|
||||
@Override
|
||||
public void run() {
|
||||
roadAuditProcess.setText(hasSubmitBeanBody.getAuditingCount() + "");
|
||||
roadAuditThrough.setText(hasSubmitBeanBody.getPassCount() + "");
|
||||
roadAuditNotThrough.setText(hasSubmitBeanBody.getNotPassCount() + "");
|
||||
roadAuditProcess.setText(String.valueOf(hasSubmitBeanBody.getAuditingCount()));
|
||||
roadAuditThrough.setText(String.valueOf(hasSubmitBeanBody.getPassCount()));
|
||||
roadAuditNotThrough.setText(String.valueOf(hasSubmitBeanBody.getNotPassCount()));
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -378,9 +377,9 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
@SuppressLint("SetTextI18n")
|
||||
@Override
|
||||
public void run() {
|
||||
poiVideoAuditProcess.setText(hasSubmitBeanBody.getAuditingCount() + "");
|
||||
poiVideoAuditThrough.setText(hasSubmitBeanBody.getPassCount() + "");
|
||||
poiVideoAuditNotThrough.setText(hasSubmitBeanBody.getNotPassCount() + "");
|
||||
poiVideoAuditProcess.setText(String.valueOf(hasSubmitBeanBody.getAuditingCount()));
|
||||
poiVideoAuditThrough.setText(String.valueOf(hasSubmitBeanBody.getPassCount()));
|
||||
poiVideoAuditNotThrough.setText(String.valueOf(hasSubmitBeanBody.getNotPassCount()));
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -396,7 +395,6 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -414,7 +412,6 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
} else {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@ -454,9 +451,9 @@ public class HasSubmitFragment extends BaseFragment implements View.OnClickListe
|
||||
@SuppressLint("SetTextI18n")
|
||||
@Override
|
||||
public void run() {
|
||||
auditProcess.setText(hasSubmitBeanBody.getAuditingCount() + "");
|
||||
auditThrough.setText(hasSubmitBeanBody.getPassCount() + "");
|
||||
auditNotThrough.setText(hasSubmitBeanBody.getNotPassCount() + "");
|
||||
poiAuditProcess.setText(String.valueOf(hasSubmitBeanBody.getAuditingCount()));
|
||||
poiAuditThrough.setText(String.valueOf(hasSubmitBeanBody.getPassCount()));
|
||||
poiAuditNotThrough.setText(String.valueOf(hasSubmitBeanBody.getNotPassCount()));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -29,7 +29,6 @@ import com.navinfo.outdoor.bean.GetPriceBean;
|
||||
import com.navinfo.outdoor.http.Callback;
|
||||
import com.navinfo.outdoor.http.HttpInterface;
|
||||
import com.navinfo.outdoor.http.OkGoBuilder;
|
||||
import com.navinfo.outdoor.util.DoubleUtil;
|
||||
import com.navinfo.outdoor.util.FlushTokenUtil;
|
||||
import com.navinfo.outdoor.util.TimestampUtil;
|
||||
|
||||
|
@ -89,8 +89,8 @@ import java.util.Objects;
|
||||
*/
|
||||
public class OtherFragment extends BaseDrawerFragment implements View.OnClickListener {
|
||||
private Spinner spinnerOther;
|
||||
String[] others = new String[]{"门牌", "公交", "情报"};// //门牌:7 公交:8 情报:9 现在其他任务类型里就这三种
|
||||
String[] spinner = new String[]{"存在", "不存在", "无法验证"};
|
||||
private String[] others = new String[]{"门牌", "公交", "情报"};// //门牌:7 公交:8 情报:9 现在其他任务类型里就这三种
|
||||
private String[] spinner = new String[]{"存在", "不存在", "无法验证"};
|
||||
private RelativeLayout linearExist;
|
||||
private Spinner spinnerExist;
|
||||
private int existence = 0;
|
||||
|
@ -835,7 +835,6 @@ public class PoiFragment extends BaseDrawerFragment implements View.OnClickListe
|
||||
findingDuplicateByWork();
|
||||
break;
|
||||
case R.id.rl_panorama:
|
||||
findingDuplicateByWork();
|
||||
poiBuilder.append(TimestampUtil.time()).append(",").append("点击了全景图的进行拍照,");
|
||||
Intent intentPanorama = new Intent(getActivity(), PhotographActivity.class);
|
||||
File filePanorama = PhotoUtils.showPhotoFile("a", latLng);
|
||||
|
@ -98,7 +98,6 @@ public class PoiTaskFragment extends BaseFragment implements View.OnClickListene
|
||||
page = 1;
|
||||
initWork(type, true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoadMore() {
|
||||
initWork(type, false);
|
||||
@ -134,7 +133,6 @@ public class PoiTaskFragment extends BaseFragment implements View.OnClickListene
|
||||
if (Constant.USHERED != null) {
|
||||
poiTaskBuilder.append("userId:").append(Constant.USHERED).append(",");
|
||||
}
|
||||
|
||||
assert getArguments() != null;
|
||||
type = getArguments().getInt("type", 0);
|
||||
listBeans = new ArrayList<>();
|
||||
|
@ -158,13 +158,15 @@ public class PoiVideoFragment extends BaseDrawerFragment implements View.OnClick
|
||||
@Override
|
||||
public boolean onClick(BaseDialog baseDialog, View v) {
|
||||
poiVideoBuilder.append(TimestampUtil.time()).append(",").append("点击了返回当前页面的 确定 按钮,");
|
||||
if (showPoiEntity.getId() != null) {
|
||||
List<File> fileListByUUID = AWMp4ParserHelper.getInstance().getFileListByUUID(showPoiEntity.getId());
|
||||
for (int i = 0; i < fileListByUUID.size(); i++) {
|
||||
fileListByUUID.get(i).delete();
|
||||
if (showPoiEntity!=null){
|
||||
if (showPoiEntity.getId() != null) {
|
||||
List<File> fileListByUUID = AWMp4ParserHelper.getInstance().getFileListByUUID(showPoiEntity.getId());
|
||||
for (int i = 0; i < fileListByUUID.size(); i++) {
|
||||
fileListByUUID.get(i).delete();
|
||||
}
|
||||
File filePath = AWMp4ParserHelper.getInstance().getFilePath(showPoiEntity.getId());
|
||||
filePath.delete();
|
||||
}
|
||||
File filePath = AWMp4ParserHelper.getInstance().getFilePath(showPoiEntity.getId());
|
||||
filePath.delete();
|
||||
}
|
||||
Message obtain = Message.obtain();
|
||||
obtain.what = Constant.JOB_WORD_MONITOR;
|
||||
@ -740,7 +742,6 @@ public class PoiVideoFragment extends BaseDrawerFragment implements View.OnClick
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -83,7 +83,6 @@ public class RecordFragment extends BaseFragment {
|
||||
EventBus.getDefault().post(obtain);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTabUnselected(TabLayout.Tab tab) { }
|
||||
|
||||
|
@ -65,7 +65,6 @@ public class RegisterFragment extends BaseFragment implements View.OnClickListen
|
||||
return fragment;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected int getLayout() {
|
||||
return R.layout.fragment_register;
|
||||
|
@ -87,13 +87,11 @@ public class RoadFragment extends BaseDrawerFragment implements View.OnClickList
|
||||
private EditText etRoadName, etDesc;
|
||||
private ImageView ivRoadPicture;
|
||||
private Button btnRoadSave;
|
||||
private File fileZip;
|
||||
private File fileZip,logFile;
|
||||
private FrameLayout fmRoadPic;
|
||||
private Marker markerRoad;
|
||||
private LatLng latLng;
|
||||
private File logFile;
|
||||
private LatLng latLng,rearLatLng;
|
||||
private StringBuilder roadBuilder;
|
||||
private LatLng rearLatLng;
|
||||
|
||||
public static RoadFragment newInstance(Bundle bundle) {
|
||||
RoadFragment fragment = new RoadFragment();
|
||||
@ -564,7 +562,6 @@ public class RoadFragment extends BaseDrawerFragment implements View.OnClickList
|
||||
Toast.makeText(getActivity(), "没有申请权限,请手动申请", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDenied(List<String> permissions, boolean never) {
|
||||
if (never) {
|
||||
@ -596,7 +593,6 @@ public class RoadFragment extends BaseDrawerFragment implements View.OnClickList
|
||||
WaitDialog.show((AppCompatActivity) getActivity(), "任务已保存本地,请稍后");
|
||||
WaitDialog.dismiss(1000);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
@ -5,7 +5,6 @@ import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
import android.os.Bundle;
|
||||
import android.os.Message;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.CheckBox;
|
||||
@ -41,6 +40,7 @@ import com.navinfo.outdoor.room.PoiDao;
|
||||
import com.navinfo.outdoor.room.PoiDatabase;
|
||||
import com.navinfo.outdoor.room.PoiEntity;
|
||||
import com.navinfo.outdoor.util.FlushTokenUtil;
|
||||
import com.navinfo.outdoor.util.PoiEntityDeleteUtil;
|
||||
import com.navinfo.outdoor.util.PoiSaveUtils;
|
||||
import com.navinfo.outdoor.util.TimestampUtil;
|
||||
import com.umeng.umcrash.UMCrash;
|
||||
@ -68,7 +68,6 @@ public class StaySubmitFragment extends BaseFragment implements View.OnClickList
|
||||
private File logFile;
|
||||
private StringBuilder staySubmitBuilder;
|
||||
private TextView tvNumber;
|
||||
private int anInt=0;
|
||||
|
||||
public static StaySubmitFragment newInstance(Bundle bundle) {
|
||||
StaySubmitFragment fragment = new StaySubmitFragment();
|
||||
@ -129,8 +128,12 @@ public class StaySubmitFragment extends BaseFragment implements View.OnClickList
|
||||
@Override
|
||||
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||
staySubmitBuilder.append(TimestampUtil.time()).append(",").append("点击了全选进行勾选 ,");
|
||||
staySubmitAdapter.setAllDataChecked(isChecked);
|
||||
staySubmitAdapter.notifyDataSetChanged();
|
||||
if (Constant.isPresent) {
|
||||
staySubmitAdapter.setAllDataChecked(isChecked);
|
||||
staySubmitAdapter.notifyDataSetChanged();
|
||||
} else {
|
||||
Toast.makeText(getContext(), "有正在提交的数据,等提交成功后,方可操作", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -270,27 +273,21 @@ public class StaySubmitFragment extends BaseFragment implements View.OnClickList
|
||||
switch (index) {
|
||||
case 0:
|
||||
initRoadWord(0);
|
||||
anInt=0;
|
||||
break;
|
||||
case 1:
|
||||
initRoadWord(1);
|
||||
anInt=1;
|
||||
break;
|
||||
case 2:
|
||||
initRoadWord(2);
|
||||
anInt=2;
|
||||
break;
|
||||
case 3:
|
||||
initRoadWord(3);
|
||||
anInt=3;
|
||||
break;
|
||||
case 4:
|
||||
initRoadWord(4);
|
||||
anInt=4;
|
||||
break;
|
||||
case 5:
|
||||
initRoadWord(5);
|
||||
anInt=5;
|
||||
break;
|
||||
}
|
||||
tvStayType.setText(text);
|
||||
@ -352,6 +349,7 @@ public class StaySubmitFragment extends BaseFragment implements View.OnClickList
|
||||
for (PoiEntity poiEntity : allRoad) {
|
||||
if (poiEntity.isChecked()) {
|
||||
poiEntities.add(poiEntity);
|
||||
PoiEntityDeleteUtil.getInstance().deleteUtil(getContext(), poiEntity);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -169,9 +169,9 @@ public class TaskExplainFragment extends BaseFragment implements View.OnClickLis
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")||message.contains("Read time out")){
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}else {
|
||||
} else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
|
@ -81,6 +81,7 @@ public class TaskPrefectureFragment extends BaseFragment implements View.OnClick
|
||||
taskPage = 1;
|
||||
initNetwork(true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoadMore() {
|
||||
initNetwork(false);
|
||||
@ -153,9 +154,9 @@ public class TaskPrefectureFragment extends BaseFragment implements View.OnClick
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.contains("timeout")||message.contains("Read time out")){
|
||||
if (message.contains("timeout") || message.contains("Read time out")) {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}else {
|
||||
} else {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
}
|
||||
|
@ -126,7 +126,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
private CheckBox cbMapType;
|
||||
private ImageView ivZoomAdd, ivZoomDel, ivLocation, ivSubmit, ivRaffish, ivFilter, ivMessage, ivMassNotification;
|
||||
private MyLocationStyle locationStyle;
|
||||
|
||||
private SlidingUpPanelLayout sliding_layout;
|
||||
private FrameLayout frameLayout;
|
||||
private GatherGetFragment gatherGetFragment;
|
||||
@ -263,9 +262,8 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
tencentMap.animateCamera(cameraSigma, new TencentMap.CancelableCallback() {
|
||||
@Override
|
||||
public void onFinish() {
|
||||
|
||||
dismissLoadingDialog();
|
||||
treasureBuilder.append(TimestampUtil.time()).append(",").append("onFinish-获取到当前位置,");
|
||||
dismissLoadingDialog();
|
||||
refreshFilterData();
|
||||
//上传用户位置金纬度
|
||||
iniUserLocation();
|
||||
@ -335,8 +333,9 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
/**
|
||||
* 给时间加上几个小时
|
||||
*
|
||||
* @param day 当前时间 格式:yyyy-MM-dd HH:mm:ss
|
||||
* @param hour 需要加的时间
|
||||
*/
|
||||
@ -362,95 +361,81 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
|
||||
private void initMessageNotice() {
|
||||
if (Constant.USHERED == null) {
|
||||
return;
|
||||
} else {
|
||||
if (HttpInterface.MESSAGE_INFO_PUSH == null) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
HttpParams httpParams = new HttpParams("type", messageType + "");
|
||||
OkGoBuilder.getInstance()
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder.getInstance()
|
||||
.Builder(getActivity())
|
||||
.time(30)
|
||||
.url(HttpInterface.MESSAGE_INFO_PUSH)
|
||||
.params(httpParams)
|
||||
.cls(MessageNoticeBean.class)
|
||||
.token(Constant.ACCESS_TOKEN)
|
||||
.getRequest(new Callback<MessageNoticeBean>() {
|
||||
@Override
|
||||
public void onSuccess(MessageNoticeBean messageNoticeBean, int id) {
|
||||
dismissLoadingDialog();
|
||||
if (messageNoticeBean.getCode() == 200) {
|
||||
List<MessageNoticeBean.BodyBean> noticeBeanBody = messageNoticeBean.getBody();
|
||||
if (noticeBeanBody != null) {
|
||||
ivMassNotification.setVisibility(View.VISIBLE);
|
||||
messageType = 1;
|
||||
} else {
|
||||
ivMassNotification.setVisibility(View.GONE);
|
||||
messageType = 0;
|
||||
}
|
||||
//获取当前时间
|
||||
DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
calendar.setTimeInMillis(System.currentTimeMillis());
|
||||
String format = formatter.format(calendar.getTime());
|
||||
Log.d("TAG", "onSuccess: " + format);
|
||||
sharedEdit.putInt("type", messageType);
|
||||
sharedEdit.putString("dataTime", format);
|
||||
sharedEdit.commit();
|
||||
} else if (messageNoticeBean.getCode() == 230) {
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
} else {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
Toast.makeText(getActivity(), messageNoticeBean.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
.token(Constant.ACCESS_TOKEN);
|
||||
okGoBuilder.getRequest(new Callback<MessageNoticeBean>() {
|
||||
@Override
|
||||
public void onSuccess(MessageNoticeBean messageNoticeBean, int id) {
|
||||
dismissLoadingDialog();
|
||||
if (messageNoticeBean.getCode() == 200) {
|
||||
List<MessageNoticeBean.BodyBean> noticeBeanBody = messageNoticeBean.getBody();
|
||||
if (noticeBeanBody != null) {
|
||||
ivMassNotification.setVisibility(View.VISIBLE);
|
||||
messageType = 1;
|
||||
} else {
|
||||
ivMassNotification.setVisibility(View.GONE);
|
||||
messageType = 0;
|
||||
}
|
||||
//获取当前时间
|
||||
DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
calendar.setTimeInMillis(System.currentTimeMillis());
|
||||
String format = formatter.format(calendar.getTime());
|
||||
Log.d("TAG", "onSuccess: " + format);
|
||||
sharedEdit.putInt("type", messageType);
|
||||
sharedEdit.putString("dataTime", format);
|
||||
sharedEdit.commit();
|
||||
} else if (messageNoticeBean.getCode() == 230) {
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
} else {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
Toast.makeText(getActivity(), messageNoticeBean.getMessage(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.equals("timeout") || message.equals("Read time out")) {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
@Override
|
||||
public void onError(Throwable e, int id) {
|
||||
dismissLoadingDialog();
|
||||
String message = e.getMessage();
|
||||
assert message != null;
|
||||
if (message.equals("timeout") || message.equals("Read time out")) {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
Toast.makeText(getActivity(), "请求超时", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
if (getActivity() != null) {
|
||||
getActivity().runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
Toast.makeText(getActivity(), message, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
Log.d("TAG", "onError: " + e.getMessage());
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/* 得到电话区号,电话位数*/
|
||||
private void initPhone() {
|
||||
if (Constant.USHERED == null) {
|
||||
return;
|
||||
} else {
|
||||
if (HttpInterface.GET_PHONES == null) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
String encode = Geohash.getInstance().encode(Constant.currentLocation.getLatitude(), Constant.currentLocation.getLongitude());
|
||||
if (encode == null) {
|
||||
Toast.makeText(getActivity(), "没有确定经纬度", Toast.LENGTH_SHORT).show();
|
||||
@ -477,7 +462,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
if (telLength != null) {
|
||||
Constant.TelLength = telLength;
|
||||
}
|
||||
|
||||
} else if (getPhoneBean.getCode() == 230) {
|
||||
FlushTokenUtil.flushToken(getActivity());
|
||||
} else {
|
||||
@ -545,23 +529,19 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 上传用户位置
|
||||
*/
|
||||
/*上传用户位置*/
|
||||
private void iniUserLocation() {
|
||||
if (Constant.USHERED == null) {
|
||||
return;
|
||||
} else {
|
||||
if (HttpInterface.USER_LOCATION == null) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
String encode = Geohash.getInstance().encode(Constant.currentLocation.getLatitude(), Constant.currentLocation.getLongitude());
|
||||
HttpParams httpParams = new HttpParams();
|
||||
httpParams.put("geom", encode);
|
||||
long time = System.currentTimeMillis();
|
||||
httpParams.put("datetime", time);
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder.getInstance()
|
||||
/* httpParams.put("appkey",Constant.UM_APP_KEY);
|
||||
if (Constant.DEVICE_TOKEN!=null){
|
||||
httpParams.put("device_tokens", Constant.DEVICE_TOKEN);
|
||||
}*/
|
||||
OkGoBuilder okGoBuilder = OkGoBuilder
|
||||
.getInstance()
|
||||
.Builder(getActivity())
|
||||
.time(30)
|
||||
.url(HttpInterface.USER_LOCATION)
|
||||
@ -631,16 +611,9 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
/**
|
||||
* 网络删选接口
|
||||
*
|
||||
* @param tencentLocation
|
||||
* @param tencentLocation location
|
||||
*/
|
||||
private void initList(TencentLocation tencentLocation) {
|
||||
if (Constant.USHERED == null) {
|
||||
return;
|
||||
} else {
|
||||
if (HttpInterface.TASK_LIST == null) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
int task_type = Constant.TASK_TYPE;
|
||||
int limit_type = Constant.LIMIT_TYPE;
|
||||
int taskStatus = Constant.TASK_STARTUP;
|
||||
@ -656,7 +629,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
if (mapCenterPoint != null) {
|
||||
centerEncode = Geohash.getInstance().encode(mapCenterPoint.latitude, mapCenterPoint.longitude);
|
||||
}
|
||||
|
||||
String userEncode = Geohash.getInstance().encode(tencentLocation.getLatitude(), tencentLocation.getLongitude());
|
||||
OkGo.getInstance().cancelTag(this);
|
||||
Log.d("TAG", "initList: " + Constant.USHERED);
|
||||
@ -803,7 +775,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
String stationGeo = initGeo(latLng);
|
||||
geoMarker(stationGeo, stationMarker);
|
||||
stationMarker.setClickable(true);
|
||||
|
||||
break;
|
||||
case 3://poi录像
|
||||
BitmapDescriptor poiVideoDescriptor = BitmapDescriptorFactory.fromResource(R.drawable.marker_poi_video);
|
||||
@ -919,17 +890,15 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 坐标点转成geo
|
||||
* geo 坐标点转成
|
||||
*
|
||||
* @param latLng
|
||||
* @return
|
||||
* @param latLng lat
|
||||
*/
|
||||
public String initGeo(LatLng latLng) {
|
||||
return GeometryTools.createGeometry(latLng).toString();
|
||||
@ -951,8 +920,8 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
/**
|
||||
* marker 选中的状态
|
||||
*
|
||||
* @param poiEntity
|
||||
* @param aBoolean
|
||||
* @param poiEntity PoiEntity
|
||||
* @param aBoolean boolean
|
||||
*/
|
||||
public void initMarker(PoiEntity poiEntity, boolean aBoolean) {
|
||||
String geoWkt = poiEntity.getGeoWkt();
|
||||
@ -1084,9 +1053,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 本地数据库数据
|
||||
*/
|
||||
/*本地数据库数据*/
|
||||
private void initThread() {
|
||||
int taskStatus = Constant.TASK_STARTUP;
|
||||
int type = Constant.TASK_TYPE;
|
||||
@ -1373,7 +1340,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
EventBus.getDefault().post(obtain);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
}).start();
|
||||
@ -1382,7 +1348,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
@Subscribe
|
||||
public void onEvent(Message data) {
|
||||
if (data.what == Constant.FILTER_LIST_ITEM) { // 点击筛选的item
|
||||
// 如果当前fragment是筛选,则移除该fragment
|
||||
// 如果当前fragment是筛选,则移除该frag
|
||||
FilterFragment filterFragment = (FilterFragment) supportFragmentManager.findFragmentByTag(FilterFragment.class.getName());
|
||||
if (filterFragment != null) {
|
||||
FragmentTransaction fragmentTransaction = supportFragmentManager.beginTransaction();
|
||||
@ -1555,7 +1521,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void initData() {
|
||||
super.initData();
|
||||
@ -1583,9 +1548,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 奔溃后的数据
|
||||
*/
|
||||
/*奔溃后的数据*/
|
||||
private void initSharePre() {
|
||||
//根据保存时所用的name属性,获取SharedPreferences对象
|
||||
SharedPreferences dataFile = Objects.requireNonNull(getActivity()).getSharedPreferences(Constant.DATA_FILE, 0);
|
||||
@ -1678,9 +1641,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 当选择后将sp中数据删除
|
||||
*/
|
||||
/*当选择后将sp中数据删除*/
|
||||
public void initRemovePoiSharePre() {
|
||||
//获取SharedPreferences对象,方法中两个参数的意思为:第一个name
|
||||
//表示文件名,系统将会在/dada/dada/包名/shared_prefs目录下生成
|
||||
@ -1731,9 +1692,12 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
EventBus.getDefault().unregister(this);
|
||||
}
|
||||
super.onDestroy();
|
||||
mapView.onDestroy();
|
||||
if (mapView != null) {
|
||||
mapView.onDestroy();
|
||||
}
|
||||
treasureBuilder.append(TimestampUtil.time()).append(",").append("onDestroy");
|
||||
treasureBuilder.append("\r\n");
|
||||
//initLocation();
|
||||
FileUtils.writeFile(logFile.getAbsolutePath(), treasureBuilder.toString(), true);
|
||||
if (bigMarker != null) {
|
||||
bigMarker.remove();
|
||||
@ -1801,9 +1765,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 弹窗
|
||||
*/
|
||||
/*弹窗*/
|
||||
private void initSubmit() {
|
||||
debounce(ivSubmit);
|
||||
if (upload == null) {
|
||||
@ -1843,10 +1805,9 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
ToastUtil.showShort(getContext(), "无法获取当前位置,请检查GPS是否打开!");
|
||||
return;
|
||||
}
|
||||
//LatLng mapCenterPoint = getMapCenterPoint();
|
||||
LatLng newPoiLatLng = new LatLng(Constant.currentLocation.getLatitude(), Constant.currentLocation.getLongitude());
|
||||
poiEntity.setX(newPoiLatLng.getLongitude() + "");
|
||||
poiEntity.setY(newPoiLatLng.getLatitude() + "");
|
||||
poiEntity.setX(String.valueOf(newPoiLatLng.getLongitude()));
|
||||
poiEntity.setY(String.valueOf(newPoiLatLng.getLatitude()));
|
||||
bundle.putSerializable("poiEntity", poiEntity);
|
||||
ShareDialog.show((AppCompatActivity) Objects.requireNonNull(getActivity()), itemList, new ShareDialog.OnItemClickListener() {
|
||||
@Override
|
||||
@ -1860,7 +1821,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
showSlidingFragment(chargingStationFragment);
|
||||
treasureBuilder.append(TimestampUtil.time()).append("点击弹窗上的充电站,");
|
||||
} else if (item.getText().equals("POI录像")) {
|
||||
bundle.putSerializable("poiEntity", poiEntity);
|
||||
PoiVideoFragment poiVideoFragment = PoiVideoFragment.newInstance(bundle);
|
||||
showSlidingFragment(poiVideoFragment);
|
||||
treasureBuilder.append(TimestampUtil.time()).append("点击弹窗上的poi录像,");
|
||||
@ -1878,9 +1838,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}).setTitle(title);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将fragment显示到抽屉内
|
||||
*/
|
||||
/*将fragment显示到抽屉内*/
|
||||
private void showSlidingFragment(BaseDrawerFragment fragment) {
|
||||
FragmentTransaction fragmentTransaction = supportFragmentManager.beginTransaction();
|
||||
int[] deviceInfo = DensityUtil.getDeviceInfo(getActivity());
|
||||
@ -1929,9 +1887,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
fragmentTransaction.commit();
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查网络状态
|
||||
*/
|
||||
/*检查网络状态*/
|
||||
private void checkNetWork() {
|
||||
showLoadingDialog();
|
||||
if (NetWorkUtils.iConnected(Objects.requireNonNull(getContext()))) { // 当前网络可用
|
||||
@ -1942,17 +1898,15 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查所需权限
|
||||
*/
|
||||
/*检查所需权限*/
|
||||
private void checkMyLocation() {
|
||||
// 1.判断是否拥有定位的权限
|
||||
// 1.1 拥有权限进行相应操作
|
||||
// 1.2 没有权限申请权限
|
||||
// 1.2.1 Android 6.0 动态申请权限
|
||||
// 1.2.1.1 用户给予权限进行相应操作
|
||||
// 1.2.1.2 用户没有给予权限 作出相应提示
|
||||
// 1.2.2 某些5.0权限的手机执行相应操作
|
||||
// 1 判断是否拥有定位的权限
|
||||
// 2 拥有权限进行相应操作
|
||||
// 3 没有权限申请权限
|
||||
// 4 Android 6.0 动态申请权限
|
||||
// 5 用户给予权限进行相应操作
|
||||
// 6 用户没有给予权限 作出相应提示
|
||||
// 7 某些5.0权限的手机执行相应操作
|
||||
XXPermissions.with(this)
|
||||
// 位置权限
|
||||
.permission(Permission.ACCESS_COARSE_LOCATION)
|
||||
@ -2042,7 +1996,6 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
ivSubmit.setVisibility(visitable);
|
||||
ivFilter.setVisibility(visitable);
|
||||
ivMessage.setVisibility(visitable);
|
||||
//tvGps.setVisibility(visitable);
|
||||
tvTenantGaps.setVisibility(visitable);
|
||||
}
|
||||
|
||||
@ -2102,6 +2055,10 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @param marker marker
|
||||
* @param isBack isBack
|
||||
*/
|
||||
private void initEntity(Marker marker, boolean isBack) {
|
||||
FragmentTransaction fragmentTransaction = supportFragmentManager.beginTransaction();
|
||||
if (marker.getTitle() != null && !marker.getTitle().equals("")) {//是本地数据直接跳转到采集页面
|
||||
@ -2354,4 +2311,5 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
||||
mapView.onSizeChanged(measuredHeight, measuredWidth, measuredWidth, measuredHeight);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -58,18 +58,9 @@ import static android.app.Activity.RESULT_OK;
|
||||
*/
|
||||
public class UserAttestationFragment extends BaseFragment implements View.OnClickListener {
|
||||
|
||||
private ImageView ivAttestation2;
|
||||
private ImageView ivAttestation1;
|
||||
private EditText etAttestationName;
|
||||
private EditText etNamePhone;
|
||||
private ImageView ivAttestation3;
|
||||
private ImageView ivHera1;
|
||||
private TextView tvCard1;
|
||||
private ImageView ivHera2;
|
||||
private TextView tvCard2;
|
||||
private ImageView ivHera3;
|
||||
private TextView tvCard3;
|
||||
private ImageView useCamera;
|
||||
private ImageView ivAttestation2, ivAttestation1,ivAttestation3, ivHera1,ivHera2,ivHera3,useCamera;
|
||||
private EditText etAttestationName, etNamePhone;
|
||||
private TextView tvCard1, tvCard2, tvCard3;
|
||||
private File logFile;
|
||||
private StringBuilder userAttestationBuilder;
|
||||
private SharedPreferences.Editor sharedPreEditor;
|
||||
|
@ -1,8 +1,8 @@
|
||||
package com.navinfo.outdoor.http;
|
||||
|
||||
public class HttpInterface {
|
||||
public static final String IP_ = "http://dtxbmaps.navinfo.com/dtxb/m4";//正式接口
|
||||
public static final String IP = "http://dtxbmaps.navinfo.com/dtxb_test/m4";//测试接口
|
||||
public static final String IP = "http://dtxbmaps.navinfo.com/dtxb/m4";//正式接口
|
||||
public static final String IP_ = "http://dtxbmaps.navinfo.com/dtxb_test/m4";//测试接口
|
||||
public static final String USER_PATH = "/user/";//我的
|
||||
public static final String MSG_LIST_PATH = "/msgList/";//发现
|
||||
public static final String USER_LOGIN_PATH = "/userlogin/";//登录
|
||||
@ -16,7 +16,9 @@ public class HttpInterface {
|
||||
public static final String DATA_IP = "http://172.23.139.4:9999/m4";//接口
|
||||
*/
|
||||
|
||||
/*用户版本升级*/
|
||||
/*
|
||||
用户版本升级
|
||||
*/
|
||||
// dtxbmaps.navinfo.com/dtxb/m4/user/appVersion/checkVersion?version=155&operationType=android
|
||||
// 172.23.139.4:8001/appVersion/checkVersion?version=155&operationType=android //version是版本 operationType固定值 安卓 get
|
||||
public static String APP_CHECK_VERSION = null; //版本升级
|
||||
@ -78,6 +80,7 @@ public class HttpInterface {
|
||||
/*任务
|
||||
* Path=/m4/task/**
|
||||
*/
|
||||
|
||||
///m4/task/task/10/receiveTasks 参数:taskIds
|
||||
public static String RECEIVE_TASK = null;//批量领取
|
||||
//172.23.139.4:8003/m4/task/1/getList
|
||||
@ -130,6 +133,11 @@ public class HttpInterface {
|
||||
//dtxbmaps.navinfo.com/dtxb_test/m4/msgList/InfoPush/28/push?type=0
|
||||
public static String MESSAGE_INFO_PUSH = null;//消息通知
|
||||
|
||||
public static String CONTACT_US = "";//联系我们
|
||||
public static String ABOUT_MAP = "";//关于 -关于地图寻宝
|
||||
public static String MAP_AGREEMENT = "";//地图寻宝服务协议
|
||||
public static String MAP_PRIVACY = "";//地图寻宝隐私
|
||||
|
||||
public static void initHttpInter(String USERID) {
|
||||
/* 我的
|
||||
* Path=/m4/user/*
|
||||
@ -222,175 +230,4 @@ public class HttpInterface {
|
||||
COMPLETE = IP + TASK_PATH + "polygonTask/" + USERID + "/complete";//面状任务结束领取
|
||||
SUBMIT_POLYGON_TASK = IP + TASK_PATH + "polygonTask/" + USERID + "/submitPolygontask";//面状任务开始采集
|
||||
}
|
||||
|
||||
public static String CONTACT_US = "";//联系我们
|
||||
public static String ABOUT_MAP = "";//关于 -关于地图寻宝
|
||||
public static String MAP_AGREEMENT = "";//地图寻宝服务协议
|
||||
public static String MAP_PRIVACY = "";//地图寻宝隐私
|
||||
|
||||
/*
|
||||
* public static String IPm8 = "http://172.23.139.4:8003/m4/";
|
||||
* http://172.23.139.4:8003/m4/task/1/unReceivedTask?taskIds=&auditIds=214,278
|
||||
* public static String UN_RECEIVED_TASK = + "task/1/unReceivedTask";//所以类型的结束领取
|
||||
* //http://172.21.91.160:8000/api/user/list
|
||||
* //发现接口
|
||||
* //http://172.23.139.4:8002/m4/findAndMessage/1/msg_list?fid=1&pageNum=1&pageSize=2
|
||||
* //能力测评接口
|
||||
* //http://172.23.139.4:8002/m4/findAndMessage/1/exam_content?id=11
|
||||
* //http://172.23.139.4:8002/m4/findAndMessage/1/submitExam
|
||||
* public static String IP1 = "http://dtxbmaps.navinfo.com/dtxb/msg/m4/findAndMessage/1/";
|
||||
* //发现:测试接口
|
||||
* public static String listTask = IP1 + "msg_list";//任务专区
|
||||
* public static String listEvent = IP1 + "msg_list";//活动专区
|
||||
* public static String listTaskExplain = IP1 + "msg_list";//任务说明
|
||||
* public static String MSG_LISt = IP1 + "msg_list";//发现查询接口
|
||||
* public static String EXAM_CONTENT = IP1 + "exam_content";//发现 -能力测评获取试题接口
|
||||
* public static String EXAM_SUBMIT = IP1 + "submitExam";//发现 -能力测评提交试卷 post
|
||||
* public static String IPm4 = "http://dtxbmaps.navinfo.com/dtxb/user/m4";
|
||||
* public static String MSG_CONTENT = IPm4 + "/1/msg_content";//发现 -富文本详情页请求
|
||||
* //172.23.139.4:8001/m4/user/update
|
||||
* public static String USER_UPDATE = IPm4 + "/user/update";//用户资料
|
||||
* //172.23.139.4:8001/m4/userBankcard/update
|
||||
* public static String USER_BANKCARD_UP_DATA = IPm4 + "/userBankcard/update"; //绑定银行卡
|
||||
* public static String IPm5 = "http://dtxbmaps.navinfo.com/dtxb/price/";
|
||||
* //http://172.23.139.4:8004/userPrice/1/getPrice
|
||||
* public static String GET_PRICE = IPm5 + "userPrice/1/getPrice";//我的-总资产
|
||||
* //http://172.23.139.4:8004/userPrice/1/userPriceExchange?exchangeMoney=10&payType=1
|
||||
* public static String USER_PRICE_EXCHANGE = IPm5 + "userPrice/1/userPriceExchange";//我的-财务信息-提现
|
||||
* public static String IPm6 = "http://dtxbmaps.navinfo.com/dtxb/task/";
|
||||
* //172.23.139.4:8003/m4/task/1/getList
|
||||
* public static String TASK_LIST = IPm6 + "m4/task/1/getList"; //任务搜索
|
||||
* //172.23.139.4:8003/othertask/1/receivedOthertask
|
||||
* public static String RECEIVED_OTHER_TASK = IPm6 + "othertask/1/receivedOthertask";//其他-领取任务
|
||||
* //172.23.139.4:8003/poitask/1/receivedPoitask/1
|
||||
* public static String RECEIVED_POI_TASK = IPm6 + "poitask/1/receivedPoitask";//poi-领取任务
|
||||
* //172.23.139.4:8003/poitask/1/submitPoitask?taskId=5001&name=测试修改名称&address=测试修改地址&existence=1&geo=1rn7exd5uhxy&memo=测试备注
|
||||
* public static String SUBMIT_POI_TASK = IPm6 + "poitask/1/submitPoitask";//poi-保存本地
|
||||
* //172.23.139.4:8003/othertask/1/submitOhtertask?taskId=5001&name=测试修改名称&address=测试修改地址&existence=1&geo=1rn7exd5uhxy&memo=测试备注
|
||||
* public static String SUBMIT_OTHER_TASK = IPm6 + "othertask/1/submitOthertask";//其他-保存本地
|
||||
* //172.23.139.4:8003/othertask/1/uploadpic
|
||||
* public static String OTHER_TASK_UPLOAD_PIC = IPm6 + "othertask/1/uploadpic";//其他-上传
|
||||
* //172.23.139.4:8003/ctask/1/receivedCtask/8608
|
||||
* public static String RECEIVED_CTASK = IPm6 + "ctask/1/receivedCtask";//充电站-领取任务
|
||||
* //172.23.139.4:8003/ctask/1/submitCtask?id=8608&name=充电站&address=地址&telephone=18812345678|14712345678&geo=1rn7exd5uhxy&memo=测试备注&sptype=1
|
||||
* public static String SUBMIT_CTASK = IPm6 + "ctask/1/submitCtask";//充电站-保存本地
|
||||
* //172.23.139.4:8003/cstask/1/submitCstask?taskId=0&name=充电站&geo=1rn7exd5uhxy&memo=测试备注&sptype=1&ffid=104&existence=1&detail={"cp_openType":"1,2","cp_floor":1,"cp_availableState":0,"sign_exist":0}
|
||||
* public static String SUBMIT_CSTASK = IPm6 + "cstask/1/submitCstask";//充电桩保存
|
||||
* //172.23.139.4:8003/poitask/1/uploadpic
|
||||
* public static String POI_TASK_UPLOAD_PIC = IPm6 + "poitask/1/uploadpic";//poi-上传
|
||||
* //172.23.139.4:8003/roadtask/1/receivedRoadtask/8569
|
||||
* public static String RECEIVED_ROAD_TASK = IPm6 + "roadtask/1/receivedRoadtask";//道路任务获取
|
||||
* //172.23.139.4:8003/poivideotask/1/receivedPoivideotask/8569
|
||||
* public static String RECEIVED_POI_VIDEO_TASK = IPm6 + "poivideotask/1/receivedPoivideotask";//poi录像任务获取
|
||||
* // 172.23.139.4:8003/poivideotask/1/submitPoivideotask
|
||||
* public static String INSIDE_API_LIST = IPm6 + "poivideotask/1/submitPoivideotask";//poi录像 保存
|
||||
* //172.23.139.4:8003/poivideotask/1/uploadpic
|
||||
* public static String POI_VIDEO_UPLOAD_PIC = IPm6 + "poivideotask/1/uploadpic";//poi录像-上传
|
||||
* //172.23.139.4:8003/roadtask/1/submitRoadtask?taskId=0&name=段哥&address=二娃&memo=1rn7exd5uhxy&workType=2
|
||||
* public static String ROAD_TASK_SUBMIT = IPm6+"roadtask/1/submitRoadtask";//道路录像-保存本地
|
||||
* //172.23.139.4:8003/roadtask/1/uploadpic
|
||||
* public static String ROAD_TASK_UPLOAD_PIC=IPm6+"roadtask/1/uploadpic";//道路录像—上传
|
||||
* //http://172.23.139.4:8003/m4/task/1/getPhone?geo=1rn7exd5uhxy
|
||||
* public static String GET_PHONE = IPm6 + "m4/task/1/getPhone"; //任务搜索
|
||||
* //http://172.23.139.4:8003/m4/task/1/getPhone?geo=1rn7exd5uhxy
|
||||
* public static String GET_PHONES = IPm6 + "m4/task/1/getPhone";//电话区号和电话位数
|
||||
* //172.23.139.4:8003/cstask/1/uploadpic
|
||||
* public static String CS_TASK_UP_LOAD_PIC = IPm6 + "cstask/1/uploadpic";//充电桩-上传
|
||||
* //172.23.139.4:8003/ctask/1/uploadpic
|
||||
* public static String C_TASK_UP_LOAD_PIC= IPm6+"ctask/1/uploadpic";//充电站-上传
|
||||
* //172.23.139.4:8003/m4/task/1/taskName?geo=1rn7exd5uhxy&name=四维
|
||||
* public static String TASK_NAME = IPm6+"m4/task/1/taskName";//poi-查重
|
||||
* //172.23.139.4:8003/m4/task/1/getCommitList?type=2&pageSize=10&pageNum=1
|
||||
* public static String GET_COMMIT_LIST = IPm6+"m4/task/1/getCommitList";
|
||||
* public static String IPm7 = "http://dtxbmaps.navinfo.com/dtxb/user";
|
||||
* //172.23.139.4:8001/m4/userAuth/add
|
||||
* public static String USER_AUTH_ADD = IPm7 + "/userAuth/add"; //实名认证
|
||||
* public static String IPm8 = "http://172.23.139.4:9999/m4/";
|
||||
* //http://172.23.139.4:9999/m4/userlogin/oauth/token
|
||||
* public static String USER_LOGIN_OAUTH_TOKEN = IPm8 + "userlogin/oauth/token"; //登录
|
||||
* //http://172.21.91.160:8000/api/user/list
|
||||
* //发现接口
|
||||
* //http://172.23.139.4:8002/m4/findAndMessage/1/msg_list?fid=1&pageNum=1&pageSize=2
|
||||
* //能力测评接口
|
||||
* //http://172.23.139.4:8002/m4/findAndMessage/1/exam_content?id=11
|
||||
* //http://172.23.139.4:8002/m4/findAndMessage/1/submitExam
|
||||
* public static String IP1 = "http://dtxbmaps.navinfo.com/dtxb/msg/m4/findAndMessage/1/";
|
||||
* //发现:测试接口
|
||||
* public static String listTask = IP1 + "msg_list";//任务专区
|
||||
* public static String listEvent = IP1 + "msg_list";//活动专区
|
||||
* public static String listTaskExplain = IP1 + "msg_list";//任务说明
|
||||
* public static String MSG_LISt = IP1 + "msg_list";//发现查询接口
|
||||
* public static String EXAM_CONTENT = IP1 + "exam_content";//发现 -能力测评获取试题接口
|
||||
* public static String EXAM_SUBMIT = IP1 + "submitExam";//发现 -能力测评提交试卷 post
|
||||
* public static String IPm4 = "http://dtxbmaps.navinfo.com/dtxb/user/m4";
|
||||
* public static String MSG_CONTENT = IPm4 + "/1/msg_content";//发现 -富文本详情页请求
|
||||
* //172.23.139.4:8001/m4/user/update
|
||||
* public static String USER_UPDATE = IPm4 + "/user/update";//用户资料
|
||||
* //172.23.139.4:8001/m4/userBankcard/update
|
||||
* public static String USER_BANKCARD_UP_DATA = IPm4 + "/userBankcard/update"; //绑定银行卡
|
||||
* public static String IPm5 = "http://dtxbmaps.navinfo.com/dtxb/price/";
|
||||
* //http://172.23.139.4:8004/userPrice/1/getPrice
|
||||
* public static String GET_PRICE = IPm5 + "userPrice/1/getPrice";//我的-总资产
|
||||
* //http://172.23.139.4:8004/userPrice/1/userPriceExchange?exchangeMoney=10&payType=1
|
||||
* public static String USER_PRICE_EXCHANGE = IPm5 + "userPrice/1/userPriceExchange";//我的-财务信息-提现
|
||||
* public static String IPm6 = "http://dtxbmaps.navinfo.com/dtxb/task/";
|
||||
* //172.23.139.4:8003/m4/task/1/getList
|
||||
* public static String TASK_LIST = IPm6 + "m4/task/1/getList"; //任务搜索
|
||||
* //172.23.139.4:8003/othertask/1/receivedOthertask
|
||||
* public static String RECEIVED_OTHER_TASK = IPm6 + "othertask/1/receivedOthertask";//其他-领取任务
|
||||
* //172.23.139.4:8003/poitask/1/receivedPoitask/1
|
||||
* public static String RECEIVED_POI_TASK = IPm6 + "poitask/1/receivedPoitask";//poi-领取任务
|
||||
* //172.23.139.4:8003/poitask/1/submitPoitask?taskId=5001&name=测试修改名称&address=测试修改地址&existence=1&geo=1rn7exd5uhxy&memo=测试备注
|
||||
* public static String SUBMIT_POI_TASK = IPm6 + "poitask/1/submitPoitask";//poi-保存本地
|
||||
* //172.23.139.4:8003/othertask/1/submitOhtertask?taskId=5001&name=测试修改名称&address=测试修改地址&existence=1&geo=1rn7exd5uhxy&memo=测试备注
|
||||
* public static String SUBMIT_OTHER_TASK = IPm6 + "othertask/1/submitOthertask";//其他-保存本地
|
||||
* //172.23.139.4:8003/othertask/1/uploadpic
|
||||
* public static String OTHER_TASK_UPLOAD_PIC = IPm6 + "othertask/1/uploadpic";//其他-上传
|
||||
* //172.23.139.4:8003/ctask/1/receivedCtask/8608
|
||||
* public static String RECEIVED_CTASK = IPm6 + "ctask/1/receivedCtask";//充电站-领取任务
|
||||
* //172.23.139.4:8003/ctask/1/submitCtask?id=8608&name=充电站&address=地址&telephone=18812345678|14712345678&geo=1rn7exd5uhxy&memo=测试备注&sptype=1
|
||||
* public static String SUBMIT_CTASK = IPm6 + "ctask/1/submitCtask";//充电站-保存本地
|
||||
* //172.23.139.4:8003/cstask/1/submitCstask?taskId=0&name=充电站&geo=1rn7exd5uhxy&memo=测试备注&sptype=1&ffid=104&existence=1&detail={"cp_openType":"1,2","cp_floor":1,"cp_availableState":0,"sign_exist":0}
|
||||
* public static String SUBMIT_CSTASK = IPm6 + "cstask/1/submitCstask";//充电桩保存
|
||||
* //172.23.139.4:8003/poitask/1/uploadpic
|
||||
* public static String POI_TASK_UPLOAD_PIC = IPm6 + "poitask/1/uploadpic";//poi-上传
|
||||
* //172.23.139.4:8003/roadtask/1/receivedRoadtask/8569
|
||||
* public static String RECEIVED_ROAD_TASK = IPm6 + "roadtask/1/receivedRoadtask";//道路任务获取
|
||||
* //172.23.139.4:8003/poivideotask/1/receivedPoivideotask/8569
|
||||
* public static String RECEIVED_POI_VIDEO_TASK = IPm6 + "poivideotask/1/receivedPoivideotask";//poi录像任务获取
|
||||
* // 172.23.139.4:8003/poivideotask/1/submitPoivideotask
|
||||
* public static String INSIDE_API_LIST = IPm6 + "poivideotask/1/submitPoivideotask";//poi录像 保存
|
||||
* //172.23.139.4:8003/poivideotask/1/uploadpic
|
||||
* public static String POI_VIDEO_UPLOAD_PIC = IPm6 + "poivideotask/1/uploadpic";//poi录像-上传
|
||||
* //172.23.139.4:8003/roadtask/1/submitRoadtask?taskId=0&name=段哥&address=二娃&memo=1rn7exd5uhxy&workType=2
|
||||
* public static String ROAD_TASK_SUBMIT = IPm6+"roadtask/1/submitRoadtask";//道路录像-保存本地
|
||||
* //172.23.139.4:8003/roadtask/1/uploadpic
|
||||
* public static String ROAD_TASK_UPLOAD_PIC=IPm6+"roadtask/1/uploadpic";//道路录像—上传
|
||||
* //http://172.23.139.4:8003/m4/task/1/getPhone?geo=1rn7exd5uhxy
|
||||
* public static String GET_PHONE = IPm6 + "m4/task/1/getPhone"; //任务搜索
|
||||
* //http://172.23.139.4:8003/m4/task/1/getPhone?geo=1rn7exd5uhxy
|
||||
* public static String GET_PHONES = IPm6 + "m4/task/1/getPhone";//电话区号和电话位数
|
||||
* //172.23.139.4:8003/cstask/1/uploadpic
|
||||
* public static String CS_TASK_UP_LOAD_PIC = IPm6 + "cstask/1/uploadpic";//充电桩-上传
|
||||
* //172.23.139.4:8003/ctask/1/uploadpic
|
||||
* public static String C_TASK_UP_LOAD_PIC= IPm6+"ctask/1/uploadpic";//充电站-上传
|
||||
* //172.23.139.4:8003/m4/task/1/taskName?geo=1rn7exd5uhxy&name=四维
|
||||
* public static String TASK_NAME = IPm6+"m4/task/1/taskName";//poi-查重
|
||||
* //172.23.139.4:8003/m4/task/1/getCommitList?type=2&pageSize=10&pageNum=1
|
||||
* public static String GET_COMMIT_LIST = IPm6+"m4/task/1/getCommitList";
|
||||
* public static String IPm7 = "http://dtxbmaps.navinfo.com/dtxb/user";
|
||||
* //172.23.139.4:8001/m4/userAuth/add
|
||||
* public static String USER_AUTH_ADD = IPm7 + "/userAuth/add"; //实名认证
|
||||
* public static String IPm8 = "http://172.23.139.4:9999/m4/";
|
||||
* //http://172.23.139.4:9999/m4/userlogin/oauth/token
|
||||
* public static String USER_LOGIN_OAUTH_TOKEN = IPm8 + "userlogin/oauth/token"; //登录
|
||||
* 面状任务
|
||||
* public static String RECEIVED_POLYGON_TASK = IPm6 + "polygonTask/1/receivedPolygontask"; //任务领取
|
||||
* public static String UNRECEIVED_POLYGON_TASK = IPm6 + "polygonTask/1/unReceivedPolygontask";//结束领取
|
||||
* public static String COMPLETE = IPm6 + "polygonTask/1/complete";//任务采集
|
||||
* public static String SUBMIT_POLYGON_TASK = IPm6 + "polygonTask/1/submitPolygontask";//结束采集
|
||||
* public static String RECEIVED_POLYGON_TASK = IPm6 + "polygonTask/1/receivedPolygontask"; //任务领取
|
||||
* public static String COMPLETE = IPm6 + "polygonTask/1/complete";//任务采集
|
||||
* public static String SUBMIT_POLYGON_TASK = IPm6 + "polygonTask/1/submitPolygontask";//结束采集
|
||||
*/
|
||||
}
|
||||
|
@ -430,5 +430,4 @@ public class AWMp4ParserHelper {
|
||||
}
|
||||
return latLags;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -25,18 +25,18 @@ import java.util.Locale;
|
||||
@SuppressLint("MissingPermission")
|
||||
public class GPSUtils {
|
||||
|
||||
private static LocationManager mLocationManager;
|
||||
private LocationManager mLocationManager;
|
||||
|
||||
private static final String TAG = "GPSUtils";
|
||||
|
||||
private static Location mLocation = null;
|
||||
private Location mLocation = null;
|
||||
|
||||
@SuppressLint("StaticFieldLeak")
|
||||
private static Activity mContext;
|
||||
private Activity mContext;
|
||||
|
||||
public GPSUtils(Activity context) {
|
||||
mContext = context;
|
||||
this.mContext = context;
|
||||
mLocationManager = (LocationManager) context.getSystemService(Context.LOCATION_SERVICE);
|
||||
|
||||
// 判断GPS是否正常启动
|
||||
if (!mLocationManager.isProviderEnabled(LocationManager.GPS_PROVIDER)) {
|
||||
Toast.makeText(context, "请开启GPS导航...", Toast.LENGTH_SHORT).show();
|
||||
@ -49,8 +49,7 @@ public class GPSUtils {
|
||||
String bestProvider = mLocationManager.getBestProvider(getCriteria(), true);
|
||||
// 获取位置信息
|
||||
// 如果不设置查询要求,getLastKnownLocation方法传人的参数为LocationManager.GPS_PROVIDER
|
||||
assert bestProvider != null;
|
||||
// getLocationData(location);
|
||||
// getLocationData(location);
|
||||
mLocation = mLocationManager.getLastKnownLocation(bestProvider);
|
||||
// 监听状态
|
||||
mLocationManager.addGpsStatusListener(listener);
|
||||
@ -60,12 +59,13 @@ public class GPSUtils {
|
||||
// 参数3,位置变化最小距离:当位置距离变化超过此值时,将更新位置信息
|
||||
// 参数4,监听
|
||||
// 备注:参数2和3,如果参数3不为0,则以参数3为准;参数3为0,则通过时间来定时更新;两者为0,则随时刷新
|
||||
|
||||
// 1秒更新一次,或最小位移变化超过1米更新一次;
|
||||
// 注意:此处更新准确度非常低,推荐在service里面启动一个Thread,在run中sleep(10000);然后执行handler.sendMessage(),更新位置
|
||||
mLocationManager.requestLocationUpdates(LocationManager.GPS_PROVIDER, 1000, 1, locationListener);
|
||||
}
|
||||
|
||||
/**
|
||||
/*
|
||||
* 返回查询条件
|
||||
*/
|
||||
private static Criteria getCriteria() {
|
||||
@ -89,7 +89,7 @@ public class GPSUtils {
|
||||
/**
|
||||
* @return Location--->getLongitude()获取经度/getLatitude()获取纬度
|
||||
*/
|
||||
public static Location getLocation() {
|
||||
public Location getLocation() {
|
||||
if (mLocation == null) {
|
||||
Log.e("GPSUtils", "setLocationData: 获取当前位置信息为空");
|
||||
return null;
|
||||
@ -97,7 +97,7 @@ public class GPSUtils {
|
||||
return mLocation;
|
||||
}
|
||||
|
||||
public static String getLocalCity() {
|
||||
public String getLocalCity() {
|
||||
if (mLocation == null) {
|
||||
Log.e("GPSUtils", "getLocalCity: 获取城市信息为空");
|
||||
return "";
|
||||
@ -111,7 +111,7 @@ public class GPSUtils {
|
||||
return city;
|
||||
}
|
||||
|
||||
public static String getAddressStr() {
|
||||
public String getAddressStr() {
|
||||
if (mLocation == null) {
|
||||
Log.e("GPSUtils", "getAddressStr: 获取详细地址信息为空");
|
||||
return "";
|
||||
@ -126,7 +126,7 @@ public class GPSUtils {
|
||||
}
|
||||
|
||||
// 位置监听
|
||||
private LocationListener locationListener = new LocationListener() {
|
||||
private LocationListener locationListener = new LocationListener() {
|
||||
|
||||
//位置信息变化时触发
|
||||
public void onLocationChanged(Location location) {
|
||||
@ -167,7 +167,7 @@ public class GPSUtils {
|
||||
};
|
||||
|
||||
// 获取地址信息
|
||||
private static List<Address> getAddress(Location location) {
|
||||
private List<Address> getAddress(Location location) {
|
||||
List<Address> result = null;
|
||||
try {
|
||||
if (location != null) {
|
||||
@ -195,13 +195,13 @@ public class GPSUtils {
|
||||
Log.i(TAG, "卫星状态改变");
|
||||
GpsStatus gpsStatus = mLocationManager.getGpsStatus(null);
|
||||
// 获取卫星颗数的默认最大值
|
||||
assert gpsStatus != null;
|
||||
int maxSatellites = gpsStatus.getMaxSatellites();
|
||||
// 创建一个迭代器保存所有卫星
|
||||
Iterator<GpsSatellite> inters = gpsStatus.getSatellites().iterator();
|
||||
Iterator<GpsSatellite> iters = gpsStatus.getSatellites()
|
||||
.iterator();
|
||||
int count = 0;
|
||||
while (inters.hasNext() && count <= maxSatellites) {
|
||||
GpsSatellite s = inters.next();
|
||||
while (iters.hasNext() && count <= maxSatellites) {
|
||||
GpsSatellite s = iters.next();
|
||||
count++;
|
||||
}
|
||||
if (onClickGPSStatus != null) {
|
||||
@ -219,12 +219,6 @@ public class GPSUtils {
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public void Remove() {
|
||||
mLocationManager.removeUpdates(locationListener);
|
||||
mLocationManager.removeGpsStatusListener(listener);
|
||||
}
|
||||
|
||||
public OnClickGPSStatus onClickGPSStatus;
|
||||
|
||||
public void setOnClickGPSStatus(OnClickGPSStatus onClickGPSStatus) {
|
||||
|
@ -73,8 +73,20 @@ public class PoiSaveUtils {
|
||||
// 开始上传流程
|
||||
if (saveChargingPileUploadChargingStation(poiEntity)) {
|
||||
uploadPoiNet(poiEntity);
|
||||
}else {
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setWork_type(0);
|
||||
PoiDatabase.getInstance(mContext).getPoiDao().updatePoiEntity(poiEntity);
|
||||
}
|
||||
}else {
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setWork_type(0);
|
||||
PoiDatabase.getInstance(mContext).getPoiDao().updatePoiEntity(poiEntity);
|
||||
}
|
||||
}else {
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setWork_type(0);
|
||||
PoiDatabase.getInstance(mContext).getPoiDao().updatePoiEntity(poiEntity);
|
||||
}
|
||||
} else {//其他类型
|
||||
if (savePoiNet(poiEntity) == 200) { // 网络保存成功
|
||||
@ -96,7 +108,10 @@ public class PoiSaveUtils {
|
||||
obtain1.obj = "批量提交 成功:" + anInt + ", 失败:" + bInt;
|
||||
EventBus.getDefault().post(obtain1);
|
||||
} else {
|
||||
Constant.isPresent = true;
|
||||
Message obtain1 = Message.obtain();
|
||||
obtain1.what = Constant.NEST_WORD_SUBMIT;
|
||||
obtain1.obj = "批量提交 失败";
|
||||
EventBus.getDefault().post(obtain1);
|
||||
}
|
||||
|
||||
}
|
||||
@ -285,17 +300,26 @@ public class PoiSaveUtils {
|
||||
.postFileSynchronization();
|
||||
if (execute == null) {
|
||||
Log.d("TAGSS", "execute: 失败" + bInt);
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setWork_type(0);
|
||||
PoiDatabase.getInstance(mContext).getPoiDao().updatePoiEntity(poiEntity);
|
||||
bInt++;
|
||||
return;
|
||||
}
|
||||
if (execute.code() != 200) {
|
||||
Log.d("TAGSS", "code: 失败" + bInt);
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setWork_type(0);
|
||||
PoiDatabase.getInstance(mContext).getPoiDao().updatePoiEntity(poiEntity);
|
||||
bInt++;
|
||||
return;
|
||||
}
|
||||
String bodyStr = execute.body().string();
|
||||
if (bodyStr == null) {
|
||||
Log.d("TAGSS", "bodyStr: 失败" + bInt);
|
||||
poiEntity.setChecked(false);
|
||||
poiEntity.setWork_type(0);
|
||||
PoiDatabase.getInstance(mContext).getPoiDao().updatePoiEntity(poiEntity);
|
||||
bInt++;
|
||||
return;
|
||||
}
|
||||
@ -365,7 +389,8 @@ public class PoiSaveUtils {
|
||||
hashMap.put("cp_floor", chargingPileEntity.getCp_floor());
|
||||
hashMap.put("cp_availableState", chargingPileEntity.getCp_availableState());
|
||||
hashMap.put("sign_exist", chargingPileEntity.getSign_exist());
|
||||
httpParams.put("detail", String.valueOf(hashMap));
|
||||
String s = new Gson().toJson(hashMap);
|
||||
httpParams.put("detail", s);
|
||||
try {
|
||||
Response execute = OkGoBuilder.getInstance()
|
||||
.time(30)
|
||||
|
@ -98,6 +98,7 @@ public class PreserveUtils {
|
||||
|
||||
/**
|
||||
* poi
|
||||
*
|
||||
* @param mContext
|
||||
*/
|
||||
public Callback getPoiPreserveCallback(Activity mContext, PoiEntity poiEntity) {
|
||||
@ -138,7 +139,6 @@ public class PreserveUtils {
|
||||
obtain1.obj = "Poi:" + poiEntity.getName() + "保存本地失败";
|
||||
EventBus.getDefault().post(obtain1);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -153,6 +153,7 @@ public class PreserveUtils {
|
||||
|
||||
/**
|
||||
* PoiVideo
|
||||
*
|
||||
* @param mContext
|
||||
*/
|
||||
public Callback getPoiVideoPreserveCallback(Activity mContext, PoiEntity poiEntity) {
|
||||
@ -263,7 +264,8 @@ public class PreserveUtils {
|
||||
|
||||
/**
|
||||
* charging
|
||||
* @param mContext
|
||||
*
|
||||
* @param mContext context
|
||||
*/
|
||||
public Callback getChargingPreserveCallback(Activity mContext, PoiEntity poiEntity) {
|
||||
return new Callback<ChargingStationBean>() {
|
||||
@ -279,7 +281,7 @@ public class PreserveUtils {
|
||||
public void run() {
|
||||
InsertAndUpdateUtils.getInstance().insertOrUpdate(mContext, poiEntity);
|
||||
// 充电站数据已经保存在服务上,批量保存充电桩数据
|
||||
saveChargingPileByChargingStation(mContext,poiEntity);
|
||||
saveChargingPileByChargingStation(mContext, poiEntity);
|
||||
mContext.runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
@ -313,7 +315,6 @@ public class PreserveUtils {
|
||||
obtain1.what = Constant.NEST_WORD_REGISTER;
|
||||
obtain1.obj = "充电站:" + poiEntity.getName() + " 保存本地失败";
|
||||
EventBus.getDefault().post(obtain1);
|
||||
Log.d("TAG", "onError: " + e.getMessage() + "");
|
||||
}
|
||||
};
|
||||
}
|
||||
@ -321,13 +322,13 @@ public class PreserveUtils {
|
||||
/*
|
||||
* 根据充电站数据检查充电桩数据,如果没有网络保存,则批量网络保存
|
||||
*/
|
||||
private void saveChargingPileByChargingStation(Activity mContext,PoiEntity chargingStationPoiEntity) {
|
||||
private void saveChargingPileByChargingStation(Activity mContext, PoiEntity chargingStationPoiEntity) {
|
||||
if (chargingStationPoiEntity != null) {
|
||||
List<ChargingPileEntity> chargingPileEntityList = PoiDatabase.getInstance(mContext).getChargingPileDao().getChargingPileByStationId(chargingStationPoiEntity.getId());
|
||||
if (chargingPileEntityList != null && !chargingPileEntityList.isEmpty()) {
|
||||
for (ChargingPileEntity pileEntity : chargingPileEntityList) {
|
||||
if (pileEntity.getBodyId() == 0) {
|
||||
saveChargingPileByWork(mContext,pileEntity, chargingStationPoiEntity.getBodyId());
|
||||
saveChargingPileByWork(mContext, pileEntity, chargingStationPoiEntity.getBodyId());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -337,7 +338,7 @@ public class PreserveUtils {
|
||||
/**
|
||||
* 保存充电桩数据到服务端
|
||||
*/
|
||||
private void saveChargingPileByWork(Activity mContext,ChargingPileEntity chargingPileEntity, int bodyId) {
|
||||
private void saveChargingPileByWork(Activity mContext, ChargingPileEntity chargingPileEntity, int bodyId) {
|
||||
HttpParams httpParams = new HttpParams();
|
||||
httpParams.put("taskId", chargingPileEntity.getTaskId());
|
||||
httpParams.put("name", chargingPileEntity.getName());
|
||||
@ -350,7 +351,8 @@ public class PreserveUtils {
|
||||
hashMap.put("cp_floor", chargingPileEntity.getCp_floor());
|
||||
hashMap.put("cp_availableState", chargingPileEntity.getCp_availableState());
|
||||
hashMap.put("sign_exist", chargingPileEntity.getSign_exist());
|
||||
httpParams.put("detail", String.valueOf(hashMap));
|
||||
String s = new Gson().toJson(hashMap);
|
||||
httpParams.put("detail", s);
|
||||
try {
|
||||
Response execute = OkGoBuilder
|
||||
.getInstance()
|
||||
@ -363,12 +365,9 @@ public class PreserveUtils {
|
||||
String responseBodyStr = execute.body().string();
|
||||
Gson gson = new Gson();
|
||||
ChargingPileSaveBean chargingPileSaveBean = gson.fromJson(responseBodyStr, ChargingPileSaveBean.class);
|
||||
if (chargingPileSaveBean.getCode() != 200) {
|
||||
return;
|
||||
}else {
|
||||
if (chargingPileSaveBean.getCode() == 200) {
|
||||
chargingPileEntity.setBodyId(chargingPileSaveBean.getBody());
|
||||
InsertAndUpdateUtils.getInstance().insertOrUpdateChargingPile(mContext, chargingPileEntity); // 更新当前充电桩的bodyId
|
||||
Log.d("TAGSS", "saveChargingPileByWork: "+chargingPileEntity.getName()+"保存成功");
|
||||
}
|
||||
}
|
||||
} catch (IOException e) {
|
||||
|
@ -44,9 +44,9 @@ public class UploadUtils {
|
||||
/**
|
||||
* road
|
||||
*
|
||||
* @param mContext
|
||||
* @param showPoiEntity
|
||||
* @param fileZip
|
||||
* @param mContext context
|
||||
* @param showPoiEntity poiEntity
|
||||
* @param fileZip file
|
||||
*/
|
||||
public UploadCallBack getRoadUploadCallback(Activity mContext, PoiEntity showPoiEntity, File fileZip) {
|
||||
return new UploadCallBack<OtherUploadPicBean>() {
|
||||
@ -112,11 +112,9 @@ public class UploadUtils {
|
||||
|
||||
/**
|
||||
* poi
|
||||
*
|
||||
* @param mContext
|
||||
* @param showPoiEntity
|
||||
* @param poiPicList
|
||||
* @return
|
||||
* @param mContext context
|
||||
* @param showPoiEntity poiEntity
|
||||
* @param poiPicList picList
|
||||
*/
|
||||
public UploadCallBack getPoiUploadCallback(Activity mContext, PoiEntity showPoiEntity, ArrayList<File> poiPicList) {
|
||||
return new UploadCallBack<OtherUploadPicBean>() {
|
||||
@ -151,7 +149,6 @@ public class UploadUtils {
|
||||
obtain1.obj = "Poi:" + showPoiEntity.getName() + " 上传失败";
|
||||
EventBus.getDefault().post(obtain1);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -176,11 +173,9 @@ public class UploadUtils {
|
||||
|
||||
/**
|
||||
* PoiVideo
|
||||
*
|
||||
* @param mContext
|
||||
* @param showPoiEntity
|
||||
* @param fileZip
|
||||
* @return
|
||||
* @param mContext context
|
||||
* @param showPoiEntity poiEntity
|
||||
* @param fileZip file
|
||||
*/
|
||||
public UploadCallBack getPoiVideoUploadCallback(Activity mContext, PoiEntity showPoiEntity, File fileZip) {
|
||||
return new UploadCallBack<OtherUploadPicBean>() {
|
||||
@ -246,11 +241,9 @@ public class UploadUtils {
|
||||
|
||||
/**
|
||||
* other
|
||||
*
|
||||
* @param mContext
|
||||
* @param showPoiEntity
|
||||
* @param otherUploadList
|
||||
* @return
|
||||
* @param mContext context
|
||||
* @param showPoiEntity poiEntity
|
||||
* @param otherUploadList list
|
||||
*/
|
||||
public UploadCallBack getOtherUploadCallback(Activity mContext, PoiEntity showPoiEntity, List<File> otherUploadList) {
|
||||
return new UploadCallBack<PoiUploadBean>() {
|
||||
|
@ -38,7 +38,7 @@
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.tencent.tencentmap.mapsdk.maps.TextureMapView
|
||||
android:id="@+id/iv_map"
|
||||
android:id="@+id/text_map_view"
|
||||
android:layout_width="200dp"
|
||||
android:layout_height="157dp"
|
||||
app:layout_constraintHeight_default="percent"
|
||||
|
@ -3,16 +3,16 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:background="?android:attr/selectableItemBackground"
|
||||
android:layout_height="wrap_content">
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackground">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_tas_capacity"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginStart="10dp"
|
||||
android:layout_marginTop="30dp"
|
||||
android:layout_marginBottom="30dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:scaleType="fitCenter"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
@ -28,16 +28,16 @@
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_tas_capacity"
|
||||
app:layout_constraintLeft_toRightOf="@id/iv_tas_capacity"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_tas_capacity"
|
||||
/>
|
||||
app:layout_constraintTop_toTopOf="@id/iv_tas_capacity" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_results"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/iv_tas_capacity"
|
||||
android:layout_marginRight="20dp"
|
||||
app:layout_constraintBottom_toTopOf="@+id/textView"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/iv_tas_capacity">
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_results"
|
||||
@ -53,20 +53,24 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="10dp"
|
||||
android:text="通过"
|
||||
android:text=""
|
||||
app:layout_constraintBottom_toBottomOf="@id/tv_results"
|
||||
app:layout_constraintLeft_toRightOf="@id/tv_results"
|
||||
app:layout_constraintTop_toTopOf="@id/tv_results" />
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="5dp"
|
||||
android:text="去测评>"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/ll_results" />
|
||||
app:layout_constraintBottom_toTopOf="@+id/view"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ll_results"
|
||||
app:layout_constraintStart_toStartOf="@+id/ll_results"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ll_results" />
|
||||
|
||||
<View
|
||||
android:id="@+id/view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="@color/colormap"
|
||||
|
@ -20,15 +20,15 @@
|
||||
android:id="@+id/iv_measurement_finish"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="45dp"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginStart="15dp"
|
||||
android:src="@drawable/ic_baseline_arrow" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_event"
|
||||
android:layout_width="wrap_content"
|
||||
style="@style/text_style_toolbar_title"
|
||||
android:layout_toRightOf="@id/iv_find_task"
|
||||
android:text="试题测试" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.core.widget.NestedScrollView
|
||||
@ -38,16 +38,16 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/rl_capacity_measurement">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
>
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_capacity_measurement"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="任务测试"
|
||||
android:text=""
|
||||
android:textColor="@color/colorGray"
|
||||
android:textSize="30sp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
@ -60,6 +60,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="20dp"
|
||||
android:background="@drawable/shape_login"
|
||||
android:visibility="gone"
|
||||
android:text="提交"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
@ -78,6 +79,7 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_capacity_measurement" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
@ -12,7 +12,6 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginTop="20dp"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
@ -20,12 +19,12 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="10dp"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:background="@drawable/marker_poi"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/tv_poi"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_poi"
|
||||
@ -35,7 +34,8 @@
|
||||
android:text="POI任务列表"
|
||||
android:textColor="@color/black"
|
||||
app:layout_constraintLeft_toRightOf="@id/iv_poi"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poi" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poi"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
@ -50,13 +50,15 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="审核中:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/audit_process"
|
||||
android:id="@+id/poi_audit_process"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -64,13 +66,15 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/audit_through"
|
||||
android:id="@+id/poi_audit_through"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -78,13 +82,15 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核未通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/audit_not_through"
|
||||
android:id="@+id/poi_audit_not_through"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
@ -95,7 +101,8 @@
|
||||
android:src="@drawable/icon_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_poi"
|
||||
app:layout_constraintRight_toRightOf="@id/has_submit_view"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poi" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poi"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<View
|
||||
android:id="@+id/has_submit_view"
|
||||
@ -109,12 +116,12 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/iv_poi" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/cl_poiVideo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginTop="20dp"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<ImageView
|
||||
@ -122,11 +129,11 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="10dp"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:background="@drawable/marker_poi_video"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_poiVideo"
|
||||
@ -136,7 +143,8 @@
|
||||
android:text="POI录像任务列表"
|
||||
android:textColor="@color/black"
|
||||
app:layout_constraintLeft_toRightOf="@id/iv_poiVideo"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poiVideo" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poiVideo"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
@ -151,6 +159,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="审核中:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -158,6 +167,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -165,6 +175,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -172,6 +183,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -179,6 +191,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核未通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -186,6 +199,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
@ -196,7 +210,8 @@
|
||||
android:src="@drawable/icon_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_poiVideo"
|
||||
app:layout_constraintRight_toRightOf="@id/poiVideo_has_submit_view"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poiVideo" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_poiVideo"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<View
|
||||
android:id="@+id/poiVideo_has_submit_view"
|
||||
@ -223,10 +238,10 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/marker_road"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="@id/view4"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
/>
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_road"
|
||||
@ -236,7 +251,8 @@
|
||||
android:text="道路任务列表"
|
||||
android:textColor="@color/black"
|
||||
app:layout_constraintLeft_toRightOf="@id/iv_road"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_road" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_road"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
@ -250,6 +266,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:text="审核中:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -258,6 +275,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -265,6 +283,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -272,6 +291,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -279,6 +299,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核未通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -286,6 +307,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
@ -296,7 +318,8 @@
|
||||
android:src="@drawable/icon_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_road"
|
||||
app:layout_constraintRight_toRightOf="@id/view4"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_road" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_road"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<View
|
||||
android:id="@+id/view4"
|
||||
@ -312,8 +335,7 @@
|
||||
android:id="@+id/cl_charging"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="20dp"
|
||||
>
|
||||
android:layout_marginStart="20dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_charging"
|
||||
@ -322,7 +344,8 @@
|
||||
android:background="@drawable/marker_charge"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="@id/view5"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_charging"
|
||||
@ -332,7 +355,8 @@
|
||||
android:text="充电站任务列表"
|
||||
android:textColor="@color/black"
|
||||
app:layout_constraintLeft_toRightOf="@id/iv_charging"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_charging" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_charging"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
@ -346,6 +370,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="审核中:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -353,6 +378,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -360,6 +386,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -367,6 +394,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -374,6 +402,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核未通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -381,6 +410,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
@ -391,7 +421,8 @@
|
||||
android:src="@drawable/icon_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_charging"
|
||||
app:layout_constraintRight_toRightOf="@id/view5"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_charging" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_charging"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<View
|
||||
android:id="@+id/view5"
|
||||
@ -417,8 +448,8 @@
|
||||
android:background="@drawable/marker_other"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="@id/other_audit_view"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
/>
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_other"
|
||||
@ -428,8 +459,9 @@
|
||||
android:layout_marginEnd="245dp"
|
||||
android:text="其他任务列表"
|
||||
android:textColor="@color/black"
|
||||
app:layout_constraintLeft_toRightOf="@+id/iv_other"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_other" />
|
||||
app:layout_constraintLeft_toRightOf="@+id/iv_other"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_other"
|
||||
tools:ignore="HardcodedText" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
@ -443,6 +475,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="审核中:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -450,6 +483,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -457,6 +491,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -464,6 +499,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -471,6 +507,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="30dp"
|
||||
android:text="审核未通过:"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
@ -478,6 +515,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"
|
||||
android:textColor="#333"
|
||||
android:textSize="12sp" />
|
||||
</LinearLayout>
|
||||
|
||||
@ -488,7 +526,8 @@
|
||||
android:src="@drawable/icon_arrow_right"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_other"
|
||||
app:layout_constraintRight_toRightOf="@id/other_audit_view"
|
||||
app:layout_constraintTop_toTopOf="@id/iv_other" />
|
||||
app:layout_constraintTop_toTopOf="@id/iv_other"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<View
|
||||
android:id="@+id/other_audit_view"
|
||||
|
@ -44,6 +44,4 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/rl_poiTask" />
|
||||
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
@ -26,9 +26,10 @@
|
||||
android:layout_marginTop="18dp"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:text="类型"
|
||||
android:textColor="#333"
|
||||
app:layout_constraintBottom_toTopOf="@+id/tv_stay_type"
|
||||
app:layout_constraintStart_toStartOf="@+id/tv_stay_type"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_stay_type"
|
||||
@ -39,11 +40,12 @@
|
||||
android:layout_marginBottom="20dp"
|
||||
android:text="全部"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="10dp"
|
||||
android:background="@drawable/ic_baseline_arrow_forward"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
@ -64,28 +66,35 @@
|
||||
android:id="@+id/tv_result"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_margin="20dp"
|
||||
android:layout_marginStart="10dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:text="筛选结果"
|
||||
android:textColor="#333"
|
||||
android:textSize="20sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_number"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="10dp"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_margin="10dp"
|
||||
android:text="全选"
|
||||
android:textSize="17sp"
|
||||
/>
|
||||
|
||||
android:textColor="#333"
|
||||
android:textSize="17sp" />
|
||||
</RelativeLayout>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/stay_xrv"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ll_results"
|
||||
/>
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ll_results" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_del"
|
||||
android:layout_width="match_parent"
|
||||
|
@ -29,6 +29,7 @@
|
||||
android:ellipsize="end"
|
||||
android:singleLine="true"
|
||||
android:text="测试1"
|
||||
android:textColor="#333"
|
||||
android:textSize="15sp" />
|
||||
|
||||
<TextView
|
||||
@ -37,6 +38,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="10dp"
|
||||
android:text="2021-05-08 13:24:36"
|
||||
android:textColor="#333"
|
||||
app:layout_constraintTop_toBottomOf="@id/tv_road_name" />
|
||||
</LinearLayout>
|
||||
|
||||
@ -46,6 +48,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:visibility="visible"
|
||||
android:textColor="#333"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/cb_unSubmit"
|
||||
app:layout_constraintEnd_toStartOf="@+id/cb_unSubmit"
|
||||
app:layout_constraintTop_toTopOf="@+id/cb_unSubmit" />
|
||||
|
@ -23,7 +23,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="10dp"
|
||||
android:text="111111111"
|
||||
android:text=""
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="@id/iv_tas_explain"
|
||||
|
@ -10,7 +10,7 @@
|
||||
style="@style/text_style_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="标题"
|
||||
android:text=""
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
@ -19,7 +19,7 @@
|
||||
style="@style/text_style"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="标题"
|
||||
android:text=""
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="@+id/tv_title"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_title" />
|
||||
@ -29,8 +29,8 @@
|
||||
style="@style/text_style_time"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginRight="15dp"
|
||||
android:text="少时诵诗书所所"
|
||||
android:layout_marginEnd="15dp"
|
||||
android:text=""
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_title"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_title" />
|
||||
@ -43,5 +43,5 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/tv_createTime" />
|
||||
/>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
@ -14,9 +14,8 @@
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:background="@color/white"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/white">
|
||||
<com.tencent.tencentmap.mapsdk.maps.TextureMapView
|
||||
android:id="@+id/treasure_map"
|
||||
android:layout_width="match_parent"
|
||||
@ -31,16 +30,16 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_message"
|
||||
android:layout_width="25dp"
|
||||
android:layout_height="25dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginTop="80dp"
|
||||
android:background="@drawable/iv_message"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
</ImageView>
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_mas_notification"
|
||||
@ -48,17 +47,16 @@
|
||||
android:layout_height="10dp"
|
||||
android:src="@drawable/ic_red_point"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintTop_toTopOf="@+id/iv_message"
|
||||
app:layout_constraintRight_toRightOf="@+id/iv_message"
|
||||
/>
|
||||
app:layout_constraintTop_toTopOf="@+id/iv_message" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_GPS"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="15dp"
|
||||
android:visibility="gone"
|
||||
android:textColor="#F44336"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/iv_message"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/iv_message" />
|
||||
@ -89,7 +87,7 @@
|
||||
android:id="@+id/cb_map_type"
|
||||
android:layout_width="50dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginRight="15dp"
|
||||
android:layout_marginEnd="15dp"
|
||||
android:background="@drawable/atlas_selector"
|
||||
android:button="@null"
|
||||
android:checked="false"
|
||||
@ -121,7 +119,7 @@
|
||||
android:id="@+id/iv_zoom_add"
|
||||
android:layout_width="50dp"
|
||||
android:layout_height="50dp"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginStart="15dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:src="@mipmap/zoom_add"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
@ -179,6 +177,7 @@
|
||||
android:id="@+id/scroll_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
</FrameLayout>
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
Loading…
x
Reference in New Issue
Block a user