添加‘我的’页面的我的等级的接口调试
This commit is contained in:
parent
6f8b730b40
commit
6c39e1f13e
@ -3,7 +3,7 @@ apply plugin: 'com.android.application'
|
||||
android {
|
||||
compileSdkVersion 29
|
||||
buildToolsVersion '29.0.2'
|
||||
// ndkVersion '23.0.7123448'
|
||||
ndkVersion '23.0.7123448'
|
||||
|
||||
defaultConfig {
|
||||
applicationId "com.navinfo.outdoor"
|
||||
|
@ -47,6 +47,7 @@
|
||||
android:supportsRtl="true"
|
||||
android:theme="@style/Theme.WhiteScreen"
|
||||
tools:targetApi="n">
|
||||
<activity android:name=".activity.PoiPictureActivity"></activity>
|
||||
<activity android:name=".activity.LinkActivity" />
|
||||
<activity android:name=".activity.RegardMapActivity" />
|
||||
<activity android:name=".activity.StatementActivity" />
|
||||
@ -96,16 +97,19 @@
|
||||
<activity
|
||||
android:name=".activity.ImageShowActivity"
|
||||
android:screenOrientation="portrait" />
|
||||
<activity android:name=".activity.VideoActivity"
|
||||
android:screenOrientation="portrait"/>
|
||||
<activity
|
||||
android:name=".activity.VideoActivity"
|
||||
android:screenOrientation="portrait" />
|
||||
<activity
|
||||
android:name=".activity.UserActivity"
|
||||
android:screenOrientation="portrait" />
|
||||
<activity
|
||||
android:name=".activity.GuidanceActivity"
|
||||
android:screenOrientation="portrait" />
|
||||
<activity android:name=".activity.TestActivity"
|
||||
android:screenOrientation="portrait"/>
|
||||
<activity
|
||||
android:name=".activity.TestActivity"
|
||||
android:screenOrientation="portrait" />
|
||||
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="com.navinfo.outdoor.fileprovider"
|
||||
|
@ -230,6 +230,8 @@ public class LoginActivity extends BaseActivity implements View.OnClickListener
|
||||
Constant.QQ=body.getQq();
|
||||
navInfoEditor.putString("wechat",body.getWechat());
|
||||
Constant.WCHAR =body.getWechat();
|
||||
navInfoEditor.putInt("level",body.getLevel());
|
||||
Constant.LEVEL=body.getLevel();
|
||||
UserDetailBean.BodyBean.UserBankcardBean userBankcard = body.getUserBankcard();
|
||||
if (userBankcard!=null){//存储银行卡信息
|
||||
navInfoEditor.putString("bankAccount",userBankcard.getBankAccount());//银行卡编号
|
||||
|
@ -0,0 +1,103 @@
|
||||
package com.navinfo.outdoor.activity;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.os.Message;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.CheckBox;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.navinfo.outdoor.R;
|
||||
import com.navinfo.outdoor.base.BaseActivity;
|
||||
import com.otaliastudios.cameraview.CameraException;
|
||||
import com.otaliastudios.cameraview.CameraListener;
|
||||
import com.otaliastudios.cameraview.CameraView;
|
||||
import com.otaliastudios.cameraview.FileCallback;
|
||||
import com.otaliastudios.cameraview.PictureResult;
|
||||
import com.otaliastudios.cameraview.VideoResult;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.Objects;
|
||||
|
||||
public class PoiPictureActivity extends BaseActivity implements View.OnClickListener {
|
||||
|
||||
|
||||
private CameraView poiPictureCamera;
|
||||
private android.widget.CheckBox capturePoiPicture;
|
||||
private android.widget.Button btnStopPoiPicture;
|
||||
|
||||
@Override
|
||||
protected int getLayout() {
|
||||
return R.layout.activity_poi_picture;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initView() {
|
||||
super.initView();
|
||||
poiPictureCamera = (CameraView) findViewById(R.id.poi_picture_camera);
|
||||
capturePoiPicture = (CheckBox) findViewById(R.id.capture_poi_picture);
|
||||
capturePoiPicture.setOnClickListener(this::onClick);
|
||||
btnStopPoiPicture = (Button) findViewById(R.id.btn_stop_poi_picture);
|
||||
btnStopPoiPicture.setOnClickListener(this::onClick);
|
||||
poiPictureCamera.setLifecycleOwner(this);
|
||||
poiPictureCamera.addCameraListener(new CameraListener() {//相机预览监听
|
||||
@Override
|
||||
public void onPictureTaken(@NonNull @NotNull PictureResult result) {
|
||||
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void onCameraError(@NonNull @NotNull CameraException exception) {
|
||||
super.onCameraError(exception);
|
||||
Toast.makeText(PoiPictureActivity.this, exception.toString(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initData() {
|
||||
super.initData();
|
||||
poiPictureCamera.takePicture();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
switch (v.getId()) {
|
||||
case R.id.capture_poi_picture:
|
||||
|
||||
break;
|
||||
|
||||
case R.id.btn_stop_poi_picture:
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
poiPictureCamera.open();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPause() {
|
||||
super.onPause();
|
||||
poiPictureCamera.close();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
poiPictureCamera.destroy();
|
||||
}
|
||||
}
|
@ -99,6 +99,10 @@ public class Constant {
|
||||
public static String WCHAR = null;
|
||||
public static String MOBILE = null;//手机号
|
||||
public static String FILE_PATH = null;//银行卡图片途径
|
||||
public static int LEVEL = 0;//用户等级
|
||||
|
||||
|
||||
public static String YOU_MENG_APP_KEY="6139d82c5f798a55cafc51d6";//友盟appkey
|
||||
|
||||
|
||||
|
||||
|
@ -28,7 +28,7 @@ public class UserApplication extends Application {
|
||||
super.onCreate();
|
||||
userApplication=this;
|
||||
//友盟 检测bug
|
||||
UMConfigure.init(this, "60b885bd6c421a3d97db55e6", "navinfo", UMConfigure.DEVICE_TYPE_PHONE, "");
|
||||
UMConfigure.init(this, Constant.YOU_MENG_APP_KEY, "navinfo", UMConfigure.DEVICE_TYPE_PHONE, "");
|
||||
/**
|
||||
*设置组件化的Log开关
|
||||
*参数: boolean 默认为false,如需查看LOG设置为true
|
||||
|
@ -60,7 +60,6 @@ public class UserDetailBean {
|
||||
* userAuth : {"userid":1,"name":"我得","idnum":"411381200010265236","certorg":null,"idtimelimit":null,"p1":null,"p2":null,"p3":null,"modifytime":"2021-06-28T07:22:12.160+0000","audituid":null,"audittime":null,"reaudituid":null,"reaudittime":null,"auditstatus":1,"reaudited":0,"auditmsg":null}
|
||||
* role : [{"id":3,"name":"admin","description":"众包管理员"}]
|
||||
*/
|
||||
|
||||
private int pid;
|
||||
private String username;
|
||||
private String password;
|
||||
@ -70,6 +69,7 @@ public class UserDetailBean {
|
||||
private int regionId;
|
||||
private String mobile;
|
||||
private Object fatherid;
|
||||
private Object fatherusername;
|
||||
private Object registerTime;
|
||||
private Object photoName;
|
||||
private Object alipayAccountName;
|
||||
@ -79,16 +79,9 @@ public class UserDetailBean {
|
||||
private int locked;
|
||||
private UserBankcardBean userBankcard;
|
||||
private UserAuthBean userAuth;
|
||||
private int level;
|
||||
private List<RoleBean> role;
|
||||
private int needGuide;
|
||||
|
||||
public int getNeedGuide() {
|
||||
return needGuide;
|
||||
}
|
||||
|
||||
public void setNeedGuide(int needGuide) {
|
||||
this.needGuide = needGuide;
|
||||
}
|
||||
private Integer needGuide;
|
||||
|
||||
public int getPid() {
|
||||
return pid;
|
||||
@ -162,6 +155,14 @@ public class UserDetailBean {
|
||||
this.fatherid = fatherid;
|
||||
}
|
||||
|
||||
public Object getFatherusername() {
|
||||
return fatherusername;
|
||||
}
|
||||
|
||||
public void setFatherusername(Object fatherusername) {
|
||||
this.fatherusername = fatherusername;
|
||||
}
|
||||
|
||||
public Object getRegisterTime() {
|
||||
return registerTime;
|
||||
}
|
||||
@ -234,6 +235,14 @@ public class UserDetailBean {
|
||||
this.userAuth = userAuth;
|
||||
}
|
||||
|
||||
public int getLevel() {
|
||||
return level;
|
||||
}
|
||||
|
||||
public void setLevel(int level) {
|
||||
this.level = level;
|
||||
}
|
||||
|
||||
public List<RoleBean> getRole() {
|
||||
return role;
|
||||
}
|
||||
@ -242,6 +251,14 @@ public class UserDetailBean {
|
||||
this.role = role;
|
||||
}
|
||||
|
||||
public Integer getNeedGuide() {
|
||||
return needGuide;
|
||||
}
|
||||
|
||||
public void setNeedGuide(Integer needGuide) {
|
||||
this.needGuide = needGuide;
|
||||
}
|
||||
|
||||
public static class UserBankcardBean {
|
||||
/**
|
||||
* userid : 1
|
||||
@ -514,6 +531,10 @@ public class UserDetailBean {
|
||||
private int id;
|
||||
private String name;
|
||||
private String description;
|
||||
private Object createId;
|
||||
private Object createTime;
|
||||
private Object updateId;
|
||||
private Object updateTime;
|
||||
|
||||
public int getId() {
|
||||
return id;
|
||||
@ -538,6 +559,38 @@ public class UserDetailBean {
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public Object getCreateId() {
|
||||
return createId;
|
||||
}
|
||||
|
||||
public void setCreateId(Object createId) {
|
||||
this.createId = createId;
|
||||
}
|
||||
|
||||
public Object getCreateTime() {
|
||||
return createTime;
|
||||
}
|
||||
|
||||
public void setCreateTime(Object createTime) {
|
||||
this.createTime = createTime;
|
||||
}
|
||||
|
||||
public Object getUpdateId() {
|
||||
return updateId;
|
||||
}
|
||||
|
||||
public void setUpdateId(Object updateId) {
|
||||
this.updateId = updateId;
|
||||
}
|
||||
|
||||
public Object getUpdateTime() {
|
||||
return updateTime;
|
||||
}
|
||||
|
||||
public void setUpdateTime(Object updateTime) {
|
||||
this.updateTime = updateTime;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -39,6 +39,7 @@ public class MineFragment extends BaseFragment implements View.OnClickListener {
|
||||
|
||||
private TextView tvMoney;
|
||||
private TextView mainGrade;
|
||||
private TextView tvMainGrade;
|
||||
|
||||
public static MineFragment newInstance(Bundle bundle) {
|
||||
MineFragment fragment = new MineFragment();
|
||||
@ -93,6 +94,10 @@ public class MineFragment extends BaseFragment implements View.OnClickListener {
|
||||
Button btnQuit = findViewById(R.id.btn_quit);
|
||||
btnQuit.setOnClickListener(this);
|
||||
mainGrade = (TextView) findViewById(R.id.main_grade);
|
||||
tvMainGrade = findViewById(R.id.tv_main_grade);
|
||||
if (Constant.LEVEL != 0) {
|
||||
tvMainGrade.setText(Constant.LEVEL);
|
||||
}
|
||||
initNetWork();
|
||||
|
||||
}
|
||||
|
@ -287,7 +287,7 @@ public class PoiFragment extends BaseDrawerFragment implements View.OnClickListe
|
||||
|
||||
//拍照长按删除
|
||||
private void onLongDel() {
|
||||
if (ivPanorama.getTag() != null || ivName.getTag() != null || ivElse.getTag() != null || ivInternal.getTag() != null || ivCard.getTag() != null) {
|
||||
|
||||
rlPanorama.setOnLongClickListener(new View.OnLongClickListener() {
|
||||
@Override
|
||||
public boolean onLongClick(View v) {
|
||||
@ -361,7 +361,7 @@ public class PoiFragment extends BaseDrawerFragment implements View.OnClickListe
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private void initShowPoi() {
|
||||
// 添加信息:
|
||||
@ -650,7 +650,6 @@ public class PoiFragment extends BaseDrawerFragment implements View.OnClickListe
|
||||
case R.id.rl_panorama:
|
||||
Intent intentPanorama = new Intent("android.media.action.IMAGE_CAPTURE");
|
||||
file = PhotoUtils.showPhotoFile("a", latLng);
|
||||
;
|
||||
intentPanorama.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile(file));
|
||||
startActivityForResult(intentPanorama, 101);
|
||||
break;
|
||||
|
46
app/src/main/res/layout/activity_poi_picture.xml
Normal file
46
app/src/main/res/layout/activity_poi_picture.xml
Normal file
@ -0,0 +1,46 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".activity.PoiPictureActivity">
|
||||
<com.otaliastudios.cameraview.CameraView
|
||||
android:id="@+id/poi_picture_camera"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:cameraPictureSizeMaxArea="3200000"
|
||||
app:cameraPictureSizeMaxHeight="2000"
|
||||
app:cameraPictureSizeMinHeight="1000"
|
||||
app:cameraPictureSizeMaxWidth="2000"
|
||||
app:cameraPictureSizeMinWidth="1000"
|
||||
app:cameraPictureSizeAspectRatio="1920:1080"
|
||||
android:keepScreenOn="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
<CheckBox
|
||||
android:id="@+id/capture_poi_picture"
|
||||
style="@style/user_data_style"
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:background="@drawable/user_style"
|
||||
android:button="@null"
|
||||
android:gravity="center"
|
||||
android:padding="@dimen/fab_margin"
|
||||
android:text="开始采集"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/btn_stop_poi_picture" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_stop_poi_picture"
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/uploding_shape"
|
||||
android:text="结束采集"
|
||||
android:textColor="@color/colorBlue"
|
||||
app:layout_constraintBottom_toBottomOf="@id/capture_poi_picture"
|
||||
app:layout_constraintLeft_toRightOf="@id/capture_poi_picture"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
@ -158,14 +158,25 @@
|
||||
|
||||
<TextView
|
||||
android:id="@+id/main_grade"
|
||||
android:layout_width="60dp"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginRight="40dp"
|
||||
android:gravity="center"
|
||||
android:text="LV."
|
||||
|
||||
android:textSize="16sp" />
|
||||
<TextView
|
||||
android:id="@+id/tv_main_grade"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginRight="0dp"
|
||||
android:drawableRight="@drawable/ic_baseline_navigate"
|
||||
android:gravity="center"
|
||||
android:text="LV.1"
|
||||
android:textSize="16sp" />
|
||||
android:text="0"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
|
Loading…
x
Reference in New Issue
Block a user