上周问题收尾
This commit is contained in:
parent
a66e28efdb
commit
191242b9b3
app
@ -3,7 +3,7 @@ apply plugin: 'com.android.application'
|
|||||||
android {
|
android {
|
||||||
compileSdkVersion 29
|
compileSdkVersion 29
|
||||||
buildToolsVersion "29.0.0"
|
buildToolsVersion "29.0.0"
|
||||||
ndkVersion '23.0.7123448'
|
// ndkVersion '23.0.7123448'
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "com.navinfo.outdoor"
|
applicationId "com.navinfo.outdoor"
|
||||||
|
@ -22,7 +22,6 @@ import java.util.List;
|
|||||||
public class CapacityEvaluationAdapter extends RecyclerView.Adapter<CapacityEvaluationAdapter.ViewHolder> {
|
public class CapacityEvaluationAdapter extends RecyclerView.Adapter<CapacityEvaluationAdapter.ViewHolder> {
|
||||||
private List<CapacityMeasureBean.BodyBean.DataBean> capacityList = new ArrayList<>();
|
private List<CapacityMeasureBean.BodyBean.DataBean> capacityList = new ArrayList<>();
|
||||||
private Context context;
|
private Context context;
|
||||||
|
|
||||||
public CapacityEvaluationAdapter(Context context) {
|
public CapacityEvaluationAdapter(Context context) {
|
||||||
this.context = context;
|
this.context = context;
|
||||||
}
|
}
|
||||||
|
@ -36,19 +36,19 @@ public class Constant {
|
|||||||
|
|
||||||
|
|
||||||
//message word 值
|
//message word 值
|
||||||
public static final int TREASURE_FRAGMENT = 100;
|
public static final int TREASURE_FRAGMENT = 100;//抽屉界面的展示和隐藏
|
||||||
public static final int TREASURE_WORD_0 = 0;
|
public static final int TREASURE_WORD = 0;//poi 对地图页面marker 的一个展示
|
||||||
public static final int TREASURE_WORD_1 = 1;
|
public static final int POI_WORD = 2;//地图页面marker 的经纬都回传
|
||||||
public static final int POI_WORD_2 = 2;
|
public static final int FILTER_LIST = 4;//筛选列表所有数据地图显示
|
||||||
public static final int POI_WORD_3 = 3;
|
public static final int FILTER_LIST_ITEM = 5;//点击筛选的item
|
||||||
public static final int FILTER_LIST = 4;
|
public static final int GATHER_GET = 6;//点击开始采集
|
||||||
public static final int FILTER_LIST_ITEM = 5;
|
public static final int TREASURE_GATHER_GET_WORD = 7;//领取采集页面其他marker 的回传
|
||||||
public static final int GATHER_GET = 6;
|
|
||||||
public static final int TREASURE_GATHER_GET_WORD = 7;
|
|
||||||
public static final int MAIN_BUTTON_VISIABLE = 8; // 控制主界面各个按钮显隐状态的what值
|
public static final int MAIN_BUTTON_VISIABLE = 8; // 控制主界面各个按钮显隐状态的what值
|
||||||
public static final int MAIN_HEADER = 9; // 控制主界面各个header
|
public static final int MAIN_HEADER = 9; // 控制主界面各个header
|
||||||
public static final int MAIN_REMOVE = 10; // 控制主界面各个header移除
|
public static final int MAIN_REMOVE = 10; // 控制主界面各个header移除
|
||||||
public static final int GATHER_GET_WORD = 11;
|
public static final int GATHER_GET_RETURN = 11;//参加领取的返回
|
||||||
|
public static final int MAIN_CHARGING_STATION = 13;//充电站的Fragment 对地图页面marker 的一个展示
|
||||||
|
public static final int CHARGING_STATION_WORD = 15;//地图页面marker 的经纬都回传
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 用户当前位置
|
* 用户当前位置
|
||||||
|
@ -84,8 +84,6 @@ public class CapacityEvaluationFragment extends BaseFragment implements View.OnC
|
|||||||
startActivity(capacityEvaWeb);
|
startActivity(capacityEvaWeb);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -0,0 +1,357 @@
|
|||||||
|
package com.navinfo.outdoor.fragment;
|
||||||
|
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.os.Message;
|
||||||
|
import android.util.Log;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.AdapterView;
|
||||||
|
import android.widget.ArrayAdapter;
|
||||||
|
import android.widget.Button;
|
||||||
|
import android.widget.CheckBox;
|
||||||
|
import android.widget.CompoundButton;
|
||||||
|
import android.widget.EditText;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.RelativeLayout;
|
||||||
|
import android.widget.Spinner;
|
||||||
|
import android.widget.TextView;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import androidx.annotation.Nullable;
|
||||||
|
import androidx.appcompat.app.AppCompatActivity;
|
||||||
|
import androidx.recyclerview.widget.DividerItemDecoration;
|
||||||
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
|
import androidx.recyclerview.widget.RecyclerView;
|
||||||
|
|
||||||
|
import com.bumptech.glide.Glide;
|
||||||
|
import com.hjq.permissions.OnPermissionCallback;
|
||||||
|
import com.hjq.permissions.Permission;
|
||||||
|
import com.hjq.permissions.XXPermissions;
|
||||||
|
import com.kongzue.dialog.interfaces.OnDialogButtonClickListener;
|
||||||
|
import com.kongzue.dialog.util.BaseDialog;
|
||||||
|
import com.kongzue.dialog.util.DialogSettings;
|
||||||
|
import com.kongzue.dialog.v3.MessageDialog;
|
||||||
|
import com.navinfo.outdoor.R;
|
||||||
|
import com.navinfo.outdoor.adapter.PoiRecycleAdapter;
|
||||||
|
import com.navinfo.outdoor.api.Constant;
|
||||||
|
import com.navinfo.outdoor.base.BaseDrawerFragment;
|
||||||
|
import com.navinfo.outdoor.bean.Info;
|
||||||
|
import com.navinfo.outdoor.bean.PoiBean;
|
||||||
|
import com.navinfo.outdoor.room.PoiDao;
|
||||||
|
import com.navinfo.outdoor.room.PoiDatabase;
|
||||||
|
import com.navinfo.outdoor.room.PoiEntity;
|
||||||
|
import com.navinfo.outdoor.util.PhotoPathUtil;
|
||||||
|
|
||||||
|
import org.greenrobot.eventbus.EventBus;
|
||||||
|
import org.greenrobot.eventbus.Subscribe;
|
||||||
|
|
||||||
|
import java.text.DateFormat;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Calendar;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import static android.app.Activity.RESULT_OK;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 充电站的Fragment
|
||||||
|
* 2021-5-25
|
||||||
|
*/
|
||||||
|
public class ChargingStationFragment extends BaseDrawerFragment implements View.OnClickListener {
|
||||||
|
|
||||||
|
private EditText editDescribe;
|
||||||
|
private RelativeLayout rlPanorama, rlName, rlInternalPhotos, rlCard, rlElse;
|
||||||
|
private ImageView ivPanorama, ivName, ivInternal, ivCard, ivElse;
|
||||||
|
private TextView tvExamine;
|
||||||
|
private EditText editNameContent, editSiteContent;
|
||||||
|
private RecyclerView recyclerPhone;
|
||||||
|
private PoiRecycleAdapter poiRecycleAdapter;
|
||||||
|
private ArrayList<String> phoneData;
|
||||||
|
private ArrayList<PoiBean> poiBeans;
|
||||||
|
private Button btnSaveLocal;
|
||||||
|
private Button btnUploading;
|
||||||
|
private PoiDatabase poiDatabase;
|
||||||
|
private PoiDao poiDao;
|
||||||
|
private String inode;
|
||||||
|
private List<Info> photoBean;
|
||||||
|
private CheckBox checkBoxLife;
|
||||||
|
private CheckBox checkBoxRight;
|
||||||
|
private String phone;
|
||||||
|
private Spinner spinnerType;
|
||||||
|
String[] ctype = new String[]{"全部", "poi", "道路", "充电站", "其他"};
|
||||||
|
private ArrayAdapter<String> adapter;
|
||||||
|
|
||||||
|
public static ChargingStationFragment newInstance(Bundle bundle) {
|
||||||
|
ChargingStationFragment fragment = new ChargingStationFragment();
|
||||||
|
fragment.setArguments(bundle);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected int getLayout() {
|
||||||
|
return R.layout.charging_station_fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onStart() {
|
||||||
|
super.onStart();
|
||||||
|
if (!EventBus.getDefault().isRegistered(this)) {//加上判断
|
||||||
|
EventBus.getDefault().register(this);
|
||||||
|
}
|
||||||
|
View header = LayoutInflater.from(getActivity()).inflate(R.layout.charging_station_header, null);
|
||||||
|
Message obtain = Message.obtain();
|
||||||
|
obtain.what = Constant.MAIN_HEADER;
|
||||||
|
obtain.obj = header;
|
||||||
|
EventBus.getDefault().post(obtain);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void initView() {
|
||||||
|
super.initView();
|
||||||
|
poiDatabase = PoiDatabase.getInstance(getContext());
|
||||||
|
poiDao = poiDatabase.getPoiDao();
|
||||||
|
checkBoxLife = findViewById(R.id.check_pot_life);
|
||||||
|
checkBoxRight = findViewById(R.id.check_pot_right);
|
||||||
|
checkBoxLife.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
||||||
|
@Override
|
||||||
|
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||||
|
Message obtain = Message.obtain();
|
||||||
|
obtain.what = Constant.MAIN_CHARGING_STATION;
|
||||||
|
obtain.obj = isChecked;
|
||||||
|
EventBus.getDefault().post(obtain);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
checkBoxRight.setVisibility(View.GONE);
|
||||||
|
spinnerType = findViewById(R.id.spinner_type);
|
||||||
|
adapter = new ArrayAdapter<String>(getContext(), android.R.layout.simple_spinner_item, ctype);
|
||||||
|
adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item); //设置下拉列表框的下拉选项样式
|
||||||
|
spinnerType.setAdapter(adapter);
|
||||||
|
spinnerType.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
|
||||||
|
@Override
|
||||||
|
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onNothingSelected(AdapterView<?> parent) {
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
btnSaveLocal = findViewById(R.id.btn_save_local);
|
||||||
|
btnSaveLocal.setOnClickListener(this::onClick);
|
||||||
|
btnUploading = findViewById(R.id.btn_uploading);
|
||||||
|
btnUploading.setOnClickListener(this::onClick);
|
||||||
|
editNameContent = findViewById(R.id.tv_name_content);
|
||||||
|
editSiteContent = findViewById(R.id.tv_site_content);
|
||||||
|
tvExamine = findViewById(R.id.tv_examine);
|
||||||
|
tvExamine.setOnClickListener(this::onClick);
|
||||||
|
editDescribe = findViewById(R.id.edit_describe);
|
||||||
|
ivPanorama = findViewById(R.id.iv_panorama);
|
||||||
|
ivName = findViewById(R.id.iv_name);
|
||||||
|
ivInternal = findViewById(R.id.iv_internal);
|
||||||
|
ivCard = findViewById(R.id.iv_card);
|
||||||
|
ivElse = findViewById(R.id.iv_else);
|
||||||
|
rlPanorama = findViewById(R.id.rl_panorama);
|
||||||
|
rlPanorama.setOnClickListener(this::onClick);
|
||||||
|
rlName = findViewById(R.id.rl_name);
|
||||||
|
rlName.setOnClickListener(this::onClick);
|
||||||
|
rlInternalPhotos = findViewById(R.id.rl_internal_photos);
|
||||||
|
rlInternalPhotos.setOnClickListener(this::onClick);
|
||||||
|
rlCard = findViewById(R.id.rl_card);
|
||||||
|
rlCard.setOnClickListener(this::onClick);
|
||||||
|
rlElse = findViewById(R.id.rl_else);
|
||||||
|
rlElse.setOnClickListener(this::onClick);
|
||||||
|
recyclerPhone = findViewById(R.id.recycler_phone);
|
||||||
|
recyclerPhone.setLayoutManager(new LinearLayoutManager(getContext()));
|
||||||
|
recyclerPhone.addItemDecoration(new DividerItemDecoration(getContext(), DividerItemDecoration.VERTICAL));
|
||||||
|
poiBeans.add(new PoiBean("电话*", phone, R.drawable.icon_add_bg));
|
||||||
|
poiRecycleAdapter = new PoiRecycleAdapter(getContext(), poiBeans);
|
||||||
|
recyclerPhone.setAdapter(poiRecycleAdapter);
|
||||||
|
poiRecycleAdapter.setInitPoiClick(new PoiRecycleAdapter.initPoiClick() {
|
||||||
|
@Override
|
||||||
|
public void item(int aInt) {
|
||||||
|
if (aInt == 0) {
|
||||||
|
poiRecycleAdapter.addData(new PoiBean("", null, R.drawable.icon_del_bg));
|
||||||
|
} else {
|
||||||
|
poiRecycleAdapter.removeData(aInt);
|
||||||
|
if (phoneData.size() > 0) {
|
||||||
|
phoneData.remove(aInt);
|
||||||
|
Log.d("TAG", "initView: " + phoneData.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
poiRecycleAdapter.setInitPoiEditClick(new PoiRecycleAdapter.initPoiEditClick() {
|
||||||
|
@Override
|
||||||
|
public void item(String a, String data, int aInt) {
|
||||||
|
if (data.length() == 11) {
|
||||||
|
if (a != null) {
|
||||||
|
phoneData.add(aInt, a + "," + data);
|
||||||
|
} else {
|
||||||
|
phoneData.add(aInt, data);
|
||||||
|
}
|
||||||
|
Log.d("TAG", "initView: " + phoneData.toString());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
//禁用所有可操作控件
|
||||||
|
//disables();
|
||||||
|
|
||||||
|
}
|
||||||
|
//禁用所有可操作性控件
|
||||||
|
private void disables() {
|
||||||
|
checkBoxLife.setEnabled(false);
|
||||||
|
editNameContent.setEnabled(false);
|
||||||
|
tvExamine.setEnabled(false);
|
||||||
|
editSiteContent.setEnabled(false);
|
||||||
|
recyclerPhone.setEnabled(false);
|
||||||
|
ivPanorama.setEnabled(false);
|
||||||
|
ivName.setEnabled(false);
|
||||||
|
ivInternal.setEnabled(false);
|
||||||
|
ivCard.setEnabled(false);
|
||||||
|
ivElse.setEnabled(false);
|
||||||
|
editDescribe.setEnabled(false);
|
||||||
|
btnSaveLocal.setEnabled(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void initData() {
|
||||||
|
super.initData();
|
||||||
|
//存储对象
|
||||||
|
poiBeans = new ArrayList<>();
|
||||||
|
//存储手机号
|
||||||
|
phoneData = new ArrayList<>();
|
||||||
|
//存储图片地址
|
||||||
|
photoBean = new ArrayList<>();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Subscribe
|
||||||
|
public void onEvent(Message data) {
|
||||||
|
if (data.what == Constant.CHARGING_STATION_WORD) {
|
||||||
|
inode = data.obj.toString();
|
||||||
|
Toast.makeText(getContext(), inode, Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
switch (v.getId()) {
|
||||||
|
case R.id.btn_save_local:
|
||||||
|
XXPermissions.with(this)
|
||||||
|
//读写权限
|
||||||
|
.permission(Permission.MANAGE_EXTERNAL_STORAGE)
|
||||||
|
.request(new OnPermissionCallback() {
|
||||||
|
@Override
|
||||||
|
public void onGranted(List<String> permissions, boolean all) {
|
||||||
|
if (all) {
|
||||||
|
//保存数据库:
|
||||||
|
PoiEntity poiEntity = new PoiEntity();
|
||||||
|
String name = editNameContent.getText().toString().trim();//名称
|
||||||
|
if (name == null || name.equals("")) {
|
||||||
|
Toast.makeText(getActivity(), "请输入充电站 名称", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
poiEntity.setName(name);
|
||||||
|
}
|
||||||
|
String site = editSiteContent.getText().toString().trim();
|
||||||
|
if (site == null || site.equals("")) {
|
||||||
|
Toast.makeText(getActivity(), "请输入充电站 地址", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
poiEntity.setAddress(site);
|
||||||
|
}
|
||||||
|
if (inode == null || inode.equals("")) {
|
||||||
|
Toast.makeText(getActivity(), "请确定点位", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
String[] split = inode.split(",");
|
||||||
|
poiEntity.setX(split[0]);
|
||||||
|
poiEntity.setY(split[1]);
|
||||||
|
}
|
||||||
|
String describe = editDescribe.getText().toString().trim();
|
||||||
|
if (describe == null || describe.equals("")) {
|
||||||
|
Toast.makeText(getActivity(), "请输入任务描述", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
poiEntity.setDescribe(describe);
|
||||||
|
}
|
||||||
|
if (phoneData.size() <= 0) {
|
||||||
|
Toast.makeText(getActivity(), "请输入手机号", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
poiEntity.setTelPhone(phoneData.get(0));
|
||||||
|
}
|
||||||
|
if (photoBean.size() < 0) {
|
||||||
|
Toast.makeText(getActivity(), "请拍照", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
poiEntity.setPhotoInfo(photoBean);
|
||||||
|
}
|
||||||
|
DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||||
|
Calendar calendar = Calendar.getInstance();
|
||||||
|
calendar.setTimeInMillis(System.currentTimeMillis());
|
||||||
|
String format = formatter.format(calendar.getTime());
|
||||||
|
poiEntity.setCreateTime(format);
|
||||||
|
poiEntity.setType(2);
|
||||||
|
poiEntity.setTaskStatus(0);
|
||||||
|
new Thread(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
poiDao.insertPoiEntity(poiEntity);
|
||||||
|
}
|
||||||
|
}).start();
|
||||||
|
Message obtains = Message.obtain();
|
||||||
|
obtains.what = Constant.TREASURE_FRAGMENT;
|
||||||
|
obtains.obj = false;
|
||||||
|
EventBus.getDefault().post(obtains);
|
||||||
|
onBackPressed();
|
||||||
|
} else {
|
||||||
|
Toast.makeText(getActivity(), "没有申请权限,请手动申请", Toast.LENGTH_SHORT).show();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onDenied(List<String> permissions, boolean never) {
|
||||||
|
if (never) {
|
||||||
|
Toast.makeText(getActivity(), "被永久拒绝授权,请手动授予权限", Toast.LENGTH_SHORT).show();
|
||||||
|
// 如果是被永久拒绝就跳转到应用权限系统设置页面
|
||||||
|
XXPermissions.startPermissionActivity(getActivity(), permissions);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
break;
|
||||||
|
case R.id.btn_uploading:
|
||||||
|
Message obtain = Message.obtain();
|
||||||
|
obtain.what = Constant.TREASURE_FRAGMENT;
|
||||||
|
obtain.obj = false;
|
||||||
|
EventBus.getDefault().post(obtain);
|
||||||
|
break;
|
||||||
|
case R.id.tv_examine:
|
||||||
|
Toast.makeText(getContext(), editNameContent.getText().toString(), Toast.LENGTH_SHORT).show();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
|
||||||
|
super.onActivityResult(requestCode, resultCode, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onDestroy() {
|
||||||
|
if (EventBus.getDefault().isRegistered(this))//加上判断
|
||||||
|
EventBus.getDefault().unregister(this);
|
||||||
|
super.onDestroy();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
@ -65,14 +65,12 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
|||||||
EventBus.getDefault().post(obtain);
|
EventBus.getDefault().post(obtain);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected int getLayout() {
|
protected int getLayout() {
|
||||||
return R.layout.fragment_filter;
|
return R.layout.fragment_filter;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void initView() {
|
protected void initView() {
|
||||||
super.initView();
|
super.initView();
|
||||||
@ -190,7 +188,6 @@ public class FilterFragment extends BaseDrawerFragment implements View.OnClickLi
|
|||||||
tvType.setText(text);
|
tvType.setText(text);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@ -47,6 +47,7 @@ public class FindFragment extends BaseFragment implements View.OnClickListener{
|
|||||||
@Override
|
@Override
|
||||||
protected void initData() {
|
protected void initData() {
|
||||||
super.initData();
|
super.initData();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -2,6 +2,7 @@ package com.navinfo.outdoor.fragment;
|
|||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.os.Message;
|
import android.os.Message;
|
||||||
|
import android.view.KeyEvent;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
@ -38,6 +39,29 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@Override
|
||||||
|
public void onResume() {
|
||||||
|
super.onResume();
|
||||||
|
getFocus();
|
||||||
|
}
|
||||||
|
//主界面获取焦点
|
||||||
|
private void getFocus() {
|
||||||
|
getView().setFocusableInTouchMode(true);
|
||||||
|
getView().requestFocus();
|
||||||
|
getView().setOnKeyListener(new View.OnKeyListener() {
|
||||||
|
@Override
|
||||||
|
public boolean onKey(View v, int keyCode, KeyEvent event) {
|
||||||
|
if (event.getAction() == KeyEvent.ACTION_UP && keyCode == KeyEvent.KEYCODE_BACK) {
|
||||||
|
Message obtain = Message.obtain();
|
||||||
|
obtain.what = Constant.GATHER_GET_RETURN;
|
||||||
|
obtain.obj = true;
|
||||||
|
EventBus.getDefault().post(obtain);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
@Subscribe
|
@Subscribe
|
||||||
public void onEvent(Message data) {
|
public void onEvent(Message data) {
|
||||||
@ -69,6 +93,7 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
|||||||
btnBank = findViewById(R.id.btn_bank);
|
btnBank = findViewById(R.id.btn_bank);
|
||||||
btnBank.setOnClickListener(this);
|
btnBank.setOnClickListener(this);
|
||||||
Bundle arguments = getArguments();
|
Bundle arguments = getArguments();
|
||||||
|
|
||||||
if (arguments!=null) {
|
if (arguments!=null) {
|
||||||
poiEntity = (PoiEntity) arguments.getSerializable("PoiEntity");
|
poiEntity = (PoiEntity) arguments.getSerializable("PoiEntity");
|
||||||
tvTitle.setText(poiEntity.getName());
|
tvTitle.setText(poiEntity.getName());
|
||||||
@ -79,6 +104,8 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
|||||||
tvDistance.setText("距离:" );
|
tvDistance.setText("距离:" );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -97,10 +124,12 @@ public class GatherGetFragment extends BaseFragment implements View.OnClickListe
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onDestroy() {
|
public void onDestroy() {
|
||||||
if (EventBus.getDefault().isRegistered(this))//加上判断
|
if (EventBus.getDefault().isRegistered(this))//加上判断
|
||||||
EventBus.getDefault().unregister(this);
|
EventBus.getDefault().unregister(this);
|
||||||
super.onDestroy();
|
super.onDestroy();
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -31,9 +31,10 @@ public class GradeFragment extends BaseFragment implements View.OnClickListener{
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void initView() {
|
protected void initView() {
|
||||||
super.initView();
|
|
||||||
ivGrade = findViewById(R.id.iv_grade);
|
ivGrade = findViewById(R.id.iv_grade);super.initView();
|
||||||
ivGrade.setOnClickListener(this);
|
ivGrade.setOnClickListener(this);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -41,7 +42,6 @@ public class GradeFragment extends BaseFragment implements View.OnClickListener{
|
|||||||
switch (v.getId()){
|
switch (v.getId()){
|
||||||
case R.id.iv_grade:
|
case R.id.iv_grade:
|
||||||
getActivity().finish();
|
getActivity().finish();
|
||||||
break;
|
break; }
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -80,8 +80,6 @@ public class IssueFragment extends BaseFragment implements View.OnClickListener
|
|||||||
@Override
|
@Override
|
||||||
protected void initView() {
|
protected void initView() {
|
||||||
super.initView();
|
super.initView();
|
||||||
|
|
||||||
|
|
||||||
ivIssueFinish =findViewById(R.id.iv_issue_finish);
|
ivIssueFinish =findViewById(R.id.iv_issue_finish);
|
||||||
mainIssueRecycler =findViewById(R.id.main_issue_recycler);
|
mainIssueRecycler =findViewById(R.id.main_issue_recycler);
|
||||||
ivIssueFinish.setOnClickListener(this::onClick);
|
ivIssueFinish.setOnClickListener(this::onClick);
|
||||||
|
@ -64,7 +64,7 @@ import java.util.List;
|
|||||||
import static android.app.Activity.RESULT_OK;
|
import static android.app.Activity.RESULT_OK;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 记录的Fragment
|
* poi记录的Fragment
|
||||||
* 2021-5-25
|
* 2021-5-25
|
||||||
*/
|
*/
|
||||||
public class PoiFragment extends BaseDrawerFragment implements View.OnClickListener {
|
public class PoiFragment extends BaseDrawerFragment implements View.OnClickListener {
|
||||||
@ -128,7 +128,7 @@ public class PoiFragment extends BaseDrawerFragment implements View.OnClickListe
|
|||||||
@Override
|
@Override
|
||||||
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||||
Message obtain = Message.obtain();
|
Message obtain = Message.obtain();
|
||||||
obtain.what = Constant.TREASURE_WORD_0;
|
obtain.what = Constant.TREASURE_WORD;
|
||||||
obtain.obj = isChecked;
|
obtain.obj = isChecked;
|
||||||
EventBus.getDefault().post(obtain);
|
EventBus.getDefault().post(obtain);
|
||||||
}
|
}
|
||||||
@ -246,7 +246,7 @@ public class PoiFragment extends BaseDrawerFragment implements View.OnClickListe
|
|||||||
|
|
||||||
@Subscribe
|
@Subscribe
|
||||||
public void onEvent(Message data) {
|
public void onEvent(Message data) {
|
||||||
if (data.what == Constant.POI_WORD_2) {
|
if (data.what == Constant.POI_WORD) {
|
||||||
inode = data.obj.toString();
|
inode = data.obj.toString();
|
||||||
Toast.makeText(getContext(), inode, Toast.LENGTH_SHORT).show();
|
Toast.makeText(getContext(), inode, Toast.LENGTH_SHORT).show();
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,220 @@
|
|||||||
|
package com.navinfo.outdoor.fragment;
|
||||||
|
|
||||||
|
import android.content.Intent;
|
||||||
|
import android.graphics.Bitmap;
|
||||||
|
import android.media.MediaMetadataRetriever;
|
||||||
|
import android.os.Bundle;
|
||||||
|
import android.os.Message;
|
||||||
|
import android.view.LayoutInflater;
|
||||||
|
import android.view.View;
|
||||||
|
import android.widget.Button;
|
||||||
|
import android.widget.EditText;
|
||||||
|
import android.widget.ImageView;
|
||||||
|
import android.widget.RadioButton;
|
||||||
|
import android.widget.RadioGroup;
|
||||||
|
import android.widget.TextView;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import com.google.gson.Gson;
|
||||||
|
import com.hjq.permissions.OnPermissionCallback;
|
||||||
|
import com.hjq.permissions.Permission;
|
||||||
|
import com.hjq.permissions.XXPermissions;
|
||||||
|
import com.navinfo.outdoor.R;
|
||||||
|
import com.navinfo.outdoor.activity.PictureActivity;
|
||||||
|
import com.navinfo.outdoor.api.Constant;
|
||||||
|
import com.navinfo.outdoor.base.BaseDrawerFragment;
|
||||||
|
import com.navinfo.outdoor.bean.RoadExtend;
|
||||||
|
import com.navinfo.outdoor.room.PoiDao;
|
||||||
|
import com.navinfo.outdoor.room.PoiDatabase;
|
||||||
|
import com.navinfo.outdoor.room.PoiEntity;
|
||||||
|
|
||||||
|
import org.greenrobot.eventbus.EventBus;
|
||||||
|
|
||||||
|
import java.text.DateFormat;
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.Calendar;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 寻宝-点击上传弹窗-poi录像
|
||||||
|
*/
|
||||||
|
|
||||||
|
public class PoiVideoFragment extends BaseDrawerFragment implements View.OnClickListener {
|
||||||
|
private TextView tvPictures;
|
||||||
|
private EditText etRoadName;
|
||||||
|
private ImageView ivRoadPicture;
|
||||||
|
private RadioButton rbCar;
|
||||||
|
private RadioButton rbBicycle;
|
||||||
|
private RadioButton rbWalking;
|
||||||
|
private RadioButton rbManual;
|
||||||
|
private EditText etDesc;
|
||||||
|
private Button btnRoadSave;
|
||||||
|
private RadioGroup rgType;
|
||||||
|
private PoiDatabase poiDatabase;
|
||||||
|
private PoiDao poiDao;
|
||||||
|
|
||||||
|
public static PoiVideoFragment newInstance(Bundle bundle) {
|
||||||
|
PoiVideoFragment fragment = new PoiVideoFragment();
|
||||||
|
fragment.setArguments(bundle);
|
||||||
|
return fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected int getLayout() {
|
||||||
|
return R.layout.poi_video_fragment;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onStart() {
|
||||||
|
super.onStart();
|
||||||
|
View header = LayoutInflater.from(getActivity()).inflate(R.layout.poi_video_header, null);
|
||||||
|
Message obtain = Message.obtain();
|
||||||
|
obtain.what = Constant.MAIN_HEADER;
|
||||||
|
obtain.obj = header;
|
||||||
|
EventBus.getDefault().post(obtain);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void initView() {
|
||||||
|
super.initView();
|
||||||
|
poiDatabase = PoiDatabase.getInstance(getContext());
|
||||||
|
poiDao = poiDatabase.getPoiDao();
|
||||||
|
tvPictures = (TextView) findViewById(R.id.tv_pictures);
|
||||||
|
tvPictures.setOnClickListener(this::onClick);
|
||||||
|
etRoadName = (EditText) findViewById(R.id.et_road_name);
|
||||||
|
ivRoadPicture = (ImageView) findViewById(R.id.iv_road_picture);
|
||||||
|
// Glide.with(getContext()).load(getLocalVideoBitmap(String.valueOf(R.drawable.bg_01))).into(ivRoadPicture);
|
||||||
|
rbCar = (RadioButton) findViewById(R.id.rb_car);
|
||||||
|
rbBicycle = (RadioButton) findViewById(R.id.rb_bicycle);
|
||||||
|
rbWalking = (RadioButton) findViewById(R.id.rb_walking);
|
||||||
|
rbManual = (RadioButton) findViewById(R.id.rb_manual);
|
||||||
|
etDesc = (EditText) findViewById(R.id.et_desc);
|
||||||
|
btnRoadSave = (Button) findViewById(R.id.btn_road_save);
|
||||||
|
btnRoadSave.setOnClickListener(this::onClick);
|
||||||
|
rgType = (RadioGroup) findViewById(R.id.rg_type);
|
||||||
|
|
||||||
|
//禁用可操作性控件
|
||||||
|
// disables();
|
||||||
|
//获取
|
||||||
|
}
|
||||||
|
|
||||||
|
private void disables() {
|
||||||
|
etRoadName.setEnabled(false);
|
||||||
|
rgType.setEnabled(false);
|
||||||
|
ivRoadPicture.setEnabled(false);
|
||||||
|
tvPictures.setEnabled(false);
|
||||||
|
etDesc.setEnabled(false);
|
||||||
|
btnRoadSave.setEnabled(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected void initData() {
|
||||||
|
super.initData();
|
||||||
|
// infos = new ArrayList<>();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取本地视频的第一帧
|
||||||
|
*
|
||||||
|
* @param localPath
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Bitmap getLocalVideoBitmap(String localPath) {
|
||||||
|
Bitmap bitmap = null;
|
||||||
|
MediaMetadataRetriever retriever = new MediaMetadataRetriever();
|
||||||
|
try {
|
||||||
|
//根据文件路径获取缩略图
|
||||||
|
retriever.setDataSource(localPath);
|
||||||
|
//获得第一帧图片
|
||||||
|
bitmap = retriever.getFrameAtTime();
|
||||||
|
} catch (IllegalArgumentException e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
} finally {
|
||||||
|
retriever.release();
|
||||||
|
}
|
||||||
|
return bitmap;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onClick(View v) {
|
||||||
|
switch (v.getId()) {
|
||||||
|
case R.id.btn_road_save:
|
||||||
|
XXPermissions.with(getContext())
|
||||||
|
.permission(Permission.MANAGE_EXTERNAL_STORAGE)
|
||||||
|
.request(new OnPermissionCallback() {
|
||||||
|
@Override
|
||||||
|
public void onGranted(List<String> permissions, boolean all) {
|
||||||
|
if (all) {
|
||||||
|
PoiEntity poiEntity = new PoiEntity();
|
||||||
|
String roadName = etRoadName.getText().toString().trim();
|
||||||
|
if (roadName == null || roadName.equals("")) {
|
||||||
|
Toast.makeText(getContext(), "请输入poi录像 名称", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
poiEntity.setName(roadName);
|
||||||
|
}
|
||||||
|
RoadExtend roadExtend = new RoadExtend();
|
||||||
|
int type = getPictureType();
|
||||||
|
if (type== -1){
|
||||||
|
Toast.makeText(getContext(), "请选择拍照方式", Toast.LENGTH_SHORT).show();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
roadExtend.setType(type);
|
||||||
|
Gson gson = new Gson();
|
||||||
|
String roadExtendJson = gson.toJson(roadExtend);
|
||||||
|
poiEntity.setExtend(roadExtendJson);
|
||||||
|
String desc = etDesc.getText().toString().trim();
|
||||||
|
if (desc == null || desc.equals("")) {
|
||||||
|
Toast.makeText(getContext(), "请输入你的任务描述", Toast.LENGTH_SHORT).show();
|
||||||
|
} else {
|
||||||
|
poiEntity.setDescribe(desc);
|
||||||
|
}
|
||||||
|
DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||||
|
Calendar calendar = Calendar.getInstance();
|
||||||
|
calendar.setTimeInMillis(System.currentTimeMillis());
|
||||||
|
String format = formatter.format(calendar.getTime());
|
||||||
|
poiEntity.setCreateTime(format);
|
||||||
|
new Thread(new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
poiDao.insertPoiEntity(poiEntity);
|
||||||
|
}
|
||||||
|
}).start();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onDenied(List<String> permissions, boolean never) {
|
||||||
|
if (never) {
|
||||||
|
Toast.makeText(getActivity(), "被永久拒绝授权,请手动授予权限", Toast.LENGTH_SHORT).show();
|
||||||
|
// 如果是被永久拒绝就跳转到应用权限系统设置页面
|
||||||
|
XXPermissions.startPermissionActivity(getActivity(), permissions);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
break;
|
||||||
|
|
||||||
|
case R.id.tv_pictures:
|
||||||
|
Intent intent = new Intent(getContext(), PictureActivity.class);
|
||||||
|
startActivity(intent);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//获取拍照类型
|
||||||
|
private int getPictureType() {
|
||||||
|
if (rbCar != null && rbCar.isChecked()) {
|
||||||
|
return 0;
|
||||||
|
} else if (rbBicycle != null && rbBicycle.isChecked()) {
|
||||||
|
return 1;
|
||||||
|
} else if (rbWalking != null && rbWalking.isChecked()) {
|
||||||
|
return 2;
|
||||||
|
}else if (rbManual != null && rbManual.isChecked()) {
|
||||||
|
return 3;
|
||||||
|
}
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
}
|
@ -190,6 +190,8 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
showSlidingFragment(roadFragment);
|
showSlidingFragment(roadFragment);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
|
ChargingStationFragment chargingStationFragment = ChargingStationFragment.newInstance(new Bundle());
|
||||||
|
showSlidingFragment(chargingStationFragment);
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
break;
|
break;
|
||||||
@ -197,10 +199,13 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
} else if (data.what == Constant.FILTER_LIST) { // 筛选列表所有数据地图显示
|
} else if (data.what == Constant.FILTER_LIST) { // 筛选列表所有数据地图显示
|
||||||
List<PoiEntity> poiEntities = (List<PoiEntity>) data.obj;
|
List<PoiEntity> poiEntities = (List<PoiEntity>) data.obj;
|
||||||
initFilterMarker(poiEntities);
|
initFilterMarker(poiEntities);
|
||||||
} else if (data.what == Constant.TREASURE_WORD_0) { // POI采集-移动位置
|
} else if (data.what == Constant.TREASURE_WORD) { // POI采集-移动位置
|
||||||
initPoiMarker(Boolean.valueOf((Boolean) data.obj));
|
initPoiMarker(Boolean.valueOf((Boolean) data.obj),Constant.POI_WORD);
|
||||||
|
|
||||||
} else if (data.what == Constant.TREASURE_FRAGMENT) {
|
}else if (data.what==Constant.MAIN_CHARGING_STATION){//道路采集-移动位置
|
||||||
|
initPoiMarker(Boolean.valueOf((Boolean) data.obj),Constant.CHARGING_STATION_WORD);
|
||||||
|
}
|
||||||
|
else if (data.what == Constant.TREASURE_FRAGMENT) {
|
||||||
if ((boolean) data.obj == true) {
|
if ((boolean) data.obj == true) {
|
||||||
frameLayout.setVisibility(View.GONE);
|
frameLayout.setVisibility(View.GONE);
|
||||||
sliding_layout.setPanelHeight(0);
|
sliding_layout.setPanelHeight(0);
|
||||||
@ -219,6 +224,12 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
dragView.removeAllViews();
|
dragView.removeAllViews();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}else if (data.what==Constant.GATHER_GET_RETURN){//item 点击页面的返回事件的处理
|
||||||
|
if ((boolean)data.obj){
|
||||||
|
frameLayout.setVisibility(View.GONE);
|
||||||
|
sliding_layout.setPanelHeight(1000);
|
||||||
|
sliding_layout.setPanelState(SlidingUpPanelLayout.PanelState.COLLAPSED);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -248,7 +259,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void initPoiMarker(Boolean t) {
|
private void initPoiMarker(Boolean t,int aInt) {
|
||||||
if (t == true) {
|
if (t == true) {
|
||||||
//移动地图
|
//移动地图
|
||||||
CameraUpdate cameraSigma =
|
CameraUpdate cameraSigma =
|
||||||
@ -282,7 +293,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
Constant.markerLatitude = latLng.latitude;
|
Constant.markerLatitude = latLng.latitude;
|
||||||
Constant.markerLongitude = latLng.longitude;
|
Constant.markerLongitude = latLng.longitude;
|
||||||
Message obtain = Message.obtain();
|
Message obtain = Message.obtain();
|
||||||
obtain.what = Constant.POI_WORD_2;
|
obtain.what =aInt;
|
||||||
obtain.obj = Constant.markerLatitude + "," + Constant.markerLongitude;
|
obtain.obj = Constant.markerLatitude + "," + Constant.markerLongitude;
|
||||||
EventBus.getDefault().post(obtain);
|
EventBus.getDefault().post(obtain);
|
||||||
|
|
||||||
@ -410,6 +421,7 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
DialogSettings.style = DialogSettings.STYLE.STYLE_MIUI;
|
DialogSettings.style = DialogSettings.STYLE.STYLE_MIUI;
|
||||||
List<ShareDialog.Item> itemList = new ArrayList<>();
|
List<ShareDialog.Item> itemList = new ArrayList<>();
|
||||||
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_poi, "POI"));
|
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_poi, "POI"));
|
||||||
|
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_poi, "POI录像"));
|
||||||
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_road, "道路"));
|
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_road, "道路"));
|
||||||
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_chongdianzhuang, "充电站"));
|
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_chongdianzhuang, "充电站"));
|
||||||
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_qingbao, "其他"));
|
itemList.add(new ShareDialog.Item(getContext(), R.drawable.push_qingbao, "其他"));
|
||||||
@ -422,11 +434,19 @@ public class TreasureFragment extends BaseFragment implements View.OnClickListen
|
|||||||
showSlidingFragment(poiFragment);
|
showSlidingFragment(poiFragment);
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
|
PoiVideoFragment poiVideoFragment = PoiVideoFragment.newInstance(new Bundle());
|
||||||
|
showSlidingFragment(poiVideoFragment);
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
RoadFragment roadFragment = RoadFragment.newInstance(new Bundle());
|
RoadFragment roadFragment = RoadFragment.newInstance(new Bundle());
|
||||||
showSlidingFragment(roadFragment);
|
showSlidingFragment(roadFragment);
|
||||||
break;
|
break;
|
||||||
case 2:
|
|
||||||
case 3:
|
case 3:
|
||||||
|
ChargingStationFragment chargingStationFragment = ChargingStationFragment.newInstance(new Bundle());
|
||||||
|
showSlidingFragment(chargingStationFragment);
|
||||||
|
break;
|
||||||
|
case 4:
|
||||||
|
Toast.makeText(getContext(), "其他", Toast.LENGTH_SHORT).show();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
5
app/src/main/res/drawable/ic_baseline_arrow_drop.xml
Normal file
5
app/src/main/res/drawable/ic_baseline_arrow_drop.xml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<vector android:alpha="0.91" android:height="24dp"
|
||||||
|
android:tint="#919191" android:viewportHeight="24"
|
||||||
|
android:viewportWidth="24" android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<path android:fillColor="@android:color/white" android:pathData="M7,10l5,5 5,-5z"/>
|
||||||
|
</vector>
|
500
app/src/main/res/layout/charging_station_fragment.xml
Normal file
500
app/src/main/res/layout/charging_station_fragment.xml
Normal file
@ -0,0 +1,500 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ScrollView
|
||||||
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:id="@+id/scroller_view"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_01"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="01.基本资料填写"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/linear_pot"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:background="@drawable/underline"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="1.0"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/tv_01">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_pot"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginBottom="10dp"
|
||||||
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:text="点位*"
|
||||||
|
android:textColor="#333" />
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/check_pot_life"
|
||||||
|
android:layout_width="50dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_toRightOf="@id/tv_pot"
|
||||||
|
android:background="@drawable/selector_change_bg"
|
||||||
|
android:button="@null"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="编辑"
|
||||||
|
android:textSize="8sp" />
|
||||||
|
|
||||||
|
<CheckBox
|
||||||
|
android:id="@+id/check_pot_right"
|
||||||
|
android:layout_width="50dp"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_toRightOf="@id/check_pot_life"
|
||||||
|
android:background="@drawable/selector_change_bg"
|
||||||
|
android:button="@null"
|
||||||
|
android:visibility="gone"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="保存"
|
||||||
|
android:textSize="8sp" />
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/linear_name"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:background="@drawable/underline"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_pot"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent">
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_name"
|
||||||
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:text="名称*"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginBottom="10dp"
|
||||||
|
android:textColor="#333"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/tv_name_content"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:layout_toRightOf="@id/tv_name"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:hint="名称"
|
||||||
|
android:layout_toEndOf="@id/tv_name"
|
||||||
|
android:layout_toStartOf="@id/tv_examine"
|
||||||
|
android:textSize="15sp"
|
||||||
|
android:textColor="#333" />
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_examine"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="查看"
|
||||||
|
android:layout_margin="4dp"
|
||||||
|
android:textColor="@color/design_default_color_primary"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/linear_site"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:background="@drawable/underline"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_name"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent">
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_site"
|
||||||
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:text="地址*"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginBottom="10dp"
|
||||||
|
android:textColor="#333"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/tv_site_content"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:layout_toRightOf="@id/tv_site"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:hint="地址"
|
||||||
|
android:textSize="15sp"
|
||||||
|
android:textColor="#333" />
|
||||||
|
</RelativeLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/linear_phone"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:background="@drawable/underline"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_site"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent">
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/recycler_phone"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/linear_type"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:background="@drawable/underline"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_phone"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent">
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_type"
|
||||||
|
android:layout_alignParentLeft="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:text="类型*"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginBottom="10dp"
|
||||||
|
android:textColor="#333"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<Spinner
|
||||||
|
android:id="@+id/spinner_type"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="18dp"
|
||||||
|
android:layout_toRightOf="@id/tv_type"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_toEndOf="@id/tv_type"
|
||||||
|
android:textSize="15sp"
|
||||||
|
android:textColor="#333" />
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_alignParentRight="true"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:background="@drawable/ic_baseline_arrow_drop"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_02"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="02.拍照"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_type" />
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/linear_photograph"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="200dp"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:layout_marginStart="10dp"
|
||||||
|
android:layout_marginEnd="10dp"
|
||||||
|
android:orientation="vertical"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/tv_02"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent">
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/rl_panorama"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="#03A9F4"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="10dp">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/image_panorama"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:background="@drawable/quanjing"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
/>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:text="*全景图"
|
||||||
|
android:textSize="8sp"
|
||||||
|
android:layout_margin="5dp"
|
||||||
|
android:textColor="@color/pickerview_wheelview_textcolor_divider"
|
||||||
|
android:layout_below="@id/image_panorama"
|
||||||
|
/>
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_panorama"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/rl_name"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="#03A9F4"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="10dp">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/image_name"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:background="@drawable/mingcheng"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
/>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:text="*名称"
|
||||||
|
android:textSize="8sp"
|
||||||
|
android:layout_margin="5dp"
|
||||||
|
android:textColor="@color/pickerview_wheelview_textcolor_divider"
|
||||||
|
android:layout_below="@id/image_name"
|
||||||
|
/>
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_name"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/rl_internal_photos"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="#03A9F4"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="10dp">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/image_internal"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:background="@drawable/mingcheng"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
/>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:text="内部照片"
|
||||||
|
android:textSize="8sp"
|
||||||
|
android:layout_margin="5dp"
|
||||||
|
android:textColor="@color/pickerview_wheelview_textcolor_divider"
|
||||||
|
android:layout_below="@id/image_internal"
|
||||||
|
/>
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_internal"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/rl_card"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="#EFEDED"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="10dp">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/image_card"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:background="@drawable/mingpian"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
/>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:text="名片"
|
||||||
|
android:textSize="8sp"
|
||||||
|
android:layout_margin="5dp"
|
||||||
|
android:textColor="@color/pickerview_wheelview_textcolor_divider"
|
||||||
|
android:layout_below="@id/image_card"
|
||||||
|
/>
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_card"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/rl_else"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="#EFEDED"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_marginBottom="10dp">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/image_else"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_width="20dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:background="@drawable/qita"
|
||||||
|
android:layout_height="20dp"
|
||||||
|
/>
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:text="其他"
|
||||||
|
android:textSize="8sp"
|
||||||
|
android:layout_margin="5dp"
|
||||||
|
android:textColor="@color/pickerview_wheelview_textcolor_divider"
|
||||||
|
android:layout_below="@id/image_else"
|
||||||
|
/>
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_else"
|
||||||
|
android:layout_centerInParent="true"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
/>
|
||||||
|
</RelativeLayout>
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginBottom="10dp"
|
||||||
|
android:layout_marginRight="5dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
/>
|
||||||
|
</LinearLayout>
|
||||||
|
</LinearLayout>
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_03"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="03.描述"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_photograph" />
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/linear_describe"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:layout_marginStart="10dp"
|
||||||
|
android:layout_marginEnd="10dp"
|
||||||
|
android:background="@drawable/underline"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/tv_03"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent">
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/edit_describe"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:paddingBottom="30dp"
|
||||||
|
android:layout_margin="2dp"
|
||||||
|
android:gravity="top"
|
||||||
|
android:focusable="true"
|
||||||
|
android:focusableInTouchMode="true"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:hint="任务描述"
|
||||||
|
android:textSize="15sp"
|
||||||
|
|
||||||
|
/>
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:layout_marginRight="10dp"
|
||||||
|
android:layout_marginBottom="20dp"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/linear_describe">
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_save_local"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/shape_red_radius_bg"
|
||||||
|
android:text="保存本地"
|
||||||
|
android:textColor="@color/white" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_uploading"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="10dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/shape_transparent_pink_radius_bg"
|
||||||
|
android:text="上传" />
|
||||||
|
</LinearLayout>
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
</ScrollView>
|
58
app/src/main/res/layout/charging_station_header.xml
Normal file
58
app/src/main/res/layout/charging_station_header.xml
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/road_bg"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="150dp"
|
||||||
|
android:background="@drawable/top_bg"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintLeft_toLeftOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
app:layout_constraintVertical_bias="1.0" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv1"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="充电站"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="25sp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/road_bg"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/road_bg"
|
||||||
|
app:layout_constraintRight_toRightOf="@id/road_bg"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/road_bg" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginRight="15dp"
|
||||||
|
android:background="@drawable/top_bg_line_left"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/tv1"
|
||||||
|
app:layout_constraintRight_toLeftOf="@id/tv1"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/tv1" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="15dp"
|
||||||
|
android:background="@drawable/top_bg_line_right"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/tv1"
|
||||||
|
app:layout_constraintLeft_toRightOf="@id/tv1"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/tv1" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_explain"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:text="任务说明"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/tv1"
|
||||||
|
app:layout_constraintRight_toRightOf="@id/tv1"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/tv1" />
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
@ -1,20 +1,17 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:orientation="vertical"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/ll_filter"
|
android:id="@+id/ll_filter"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="100dp"
|
android:layout_height="80dp">
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/rl_filter">
|
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/cl_type"
|
android:id="@+id/cl_type"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
@ -36,8 +33,8 @@
|
|||||||
style="@style/main_about_text_style"
|
style="@style/main_about_text_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginBottom="20dp"
|
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginBottom="20dp"
|
||||||
android:text="全部"
|
android:text="全部"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
@ -74,8 +71,8 @@
|
|||||||
style="@style/main_about_text_style"
|
style="@style/main_about_text_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginBottom="20dp"
|
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginBottom="20dp"
|
||||||
android:text="全部"
|
android:text="全部"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
@ -89,6 +86,14 @@
|
|||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_filter_2"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="80dp">
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/cl_photograph"
|
android:id="@+id/cl_photograph"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
@ -113,8 +118,8 @@
|
|||||||
style="@style/main_about_text_style"
|
style="@style/main_about_text_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginBottom="20dp"
|
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginBottom="20dp"
|
||||||
android:text="全部"
|
android:text="全部"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
@ -128,6 +133,7 @@
|
|||||||
app:layout_constraintStart_toEndOf="@+id/textView2"
|
app:layout_constraintStart_toEndOf="@+id/textView2"
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:id="@+id/cl_number"
|
android:id="@+id/cl_number"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
@ -151,8 +157,8 @@
|
|||||||
style="@style/main_about_text_style"
|
style="@style/main_about_text_style"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginBottom="20dp"
|
|
||||||
android:layout_marginLeft="10dp"
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginBottom="20dp"
|
||||||
android:text="200"
|
android:text="200"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent" />
|
app:layout_constraintStart_toStartOf="parent" />
|
||||||
@ -187,17 +193,16 @@
|
|||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/btn_filter"
|
android:id="@+id/btn_filter"
|
||||||
|
style="@style/user_style"
|
||||||
android:layout_width="80dp"
|
android:layout_width="80dp"
|
||||||
android:layout_height="40dp"
|
android:layout_height="40dp"
|
||||||
android:layout_marginRight="20dp"
|
|
||||||
style="@style/user_style"
|
|
||||||
android:text="地图显示"
|
|
||||||
android:gravity="center"
|
|
||||||
android:textColor="@color/white"
|
|
||||||
android:layout_centerVertical="true"
|
|
||||||
android:layout_alignParentRight="true"
|
android:layout_alignParentRight="true"
|
||||||
android:textSize="15sp"
|
android:layout_centerVertical="true"
|
||||||
/>
|
android:layout_marginRight="20dp"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="地图显示"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="15sp" />
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<com.jcodecraeer.xrecyclerview.XRecyclerView
|
<com.jcodecraeer.xrecyclerview.XRecyclerView
|
||||||
|
@ -76,15 +76,30 @@
|
|||||||
app:layout_constraintStart_toStartOf="@+id/tv_time"
|
app:layout_constraintStart_toStartOf="@+id/tv_time"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_time" />
|
app:layout_constraintTop_toBottomOf="@+id/tv_time" />
|
||||||
|
|
||||||
<Button
|
<LinearLayout
|
||||||
android:id="@+id/btn_bank"
|
|
||||||
style="@style/user_data_style"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_margin="20dp"
|
|
||||||
android:text="立即采集"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tv_describe" />
|
app:layout_constraintTop_toBottomOf="@+id/tv_describe">
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_bank"
|
||||||
|
style="@style/user_data_style"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="20dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="立即采集" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_draw"
|
||||||
|
style="@style/user_data_style"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_margin="20dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="领取任务" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
222
app/src/main/res/layout/poi_video_fragment.xml
Normal file
222
app/src/main/res/layout/poi_video_fragment.xml
Normal file
@ -0,0 +1,222 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="16dp"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="0.0"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_message"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:text="01.基本信息"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="16sp"
|
||||||
|
app:layout_constraintLeft_toLeftOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_name"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="@drawable/road_shape"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/tv_message"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/tv_message">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:layout_marginLeft="15dp"
|
||||||
|
android:text="名称 "
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="15sp" />
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/et_road_name"
|
||||||
|
android:layout_width="200dp"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:background="@null" />
|
||||||
|
</LinearLayout>
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_mode"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="02.拍照方式"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/ll_name"
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/ll_name"
|
||||||
|
android:layout_marginTop="10dp"/>
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_mode"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:layout_marginTop="15dp"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/tv_mode">
|
||||||
|
<RadioGroup
|
||||||
|
android:id="@+id/rg_type"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:layout_gravity="center_horizontal"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
<RadioButton
|
||||||
|
android:id="@+id/rb_car"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="车行"/>
|
||||||
|
<RadioButton
|
||||||
|
android:id="@+id/rb_bicycle"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="自行车"/>
|
||||||
|
<RadioButton
|
||||||
|
android:id="@+id/rb_walking"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text="步行"/>
|
||||||
|
<RadioButton
|
||||||
|
android:id="@+id/rb_manual"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="手动"/>
|
||||||
|
</RadioGroup>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
<!--<LinearLayout-->
|
||||||
|
<!-- android:layout_width="match_parent"-->
|
||||||
|
<!-- android:layout_height="wrap_content"-->
|
||||||
|
<!-- app:layout_constraintTop_toBottomOf="@+id/ll_name"-->
|
||||||
|
<!-- android:orientation="horizontal">-->
|
||||||
|
<!-- <TextView-->
|
||||||
|
<!-- android:layout_width="wrap_content"-->
|
||||||
|
<!-- android:layout_height="wrap_content"-->
|
||||||
|
<!-- android:text="02.拍照方式"-->
|
||||||
|
<!-- -->
|
||||||
|
<!--</LinearLayout>-->
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_pictures"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/ll_mode"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/ll_mode">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="03.拍照 "
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_pictures"
|
||||||
|
style="@style/user_style"
|
||||||
|
android:layout_width="40dp"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:layout_marginLeft="5dp"
|
||||||
|
android:gravity="center"
|
||||||
|
android:text="拍照"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="15sp" />
|
||||||
|
|
||||||
|
<!-- <EditText-->
|
||||||
|
<!-- android:id="@+id/et_height"-->
|
||||||
|
<!-- android:layout_width="wrap_content"-->
|
||||||
|
<!-- android:layout_height="wrap_content"-->
|
||||||
|
<!-- android:layout_marginLeft="10dp"-->
|
||||||
|
<!-- android:hint="请输入高度"-->
|
||||||
|
<!-- android:inputType="number" />-->
|
||||||
|
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_road_picture"
|
||||||
|
android:layout_width="100dp"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="@drawable/bg_01"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/ll_pictures"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/ll_pictures" />
|
||||||
|
<!--<androidx.recyclerview.widget.RecyclerView-->
|
||||||
|
<!-- android:layout_width="match_parent"-->
|
||||||
|
<!-- android:layout_height="wrap_content"-->
|
||||||
|
<!-- android:id="@+id/rel_road"-->
|
||||||
|
<!-- app:layout_constraintTop_toBottomOf="@id/ll_pictures"/>-->
|
||||||
|
<!-- -->
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/ll_desc"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/iv_road_picture"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/iv_road_picture">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginTop="20dp"
|
||||||
|
android:text="04.描述"
|
||||||
|
android:textColor="@color/black"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<EditText
|
||||||
|
android:id="@+id/et_desc"
|
||||||
|
android:layout_width="320dp"
|
||||||
|
android:layout_height="100dp"
|
||||||
|
android:layout_gravity="center_horizontal"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:background="@drawable/road_shape"
|
||||||
|
android:hint=" 任务描述"
|
||||||
|
android:paddingBottom="50dp" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="100dp"
|
||||||
|
|
||||||
|
android:gravity="center_horizontal"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/ll_desc">
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/btn_road_save"
|
||||||
|
style="@style/user_data_style"
|
||||||
|
android:layout_width="150dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:text="保存本地" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/road_upload"
|
||||||
|
android:layout_width="150dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center_vertical"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:background="@drawable/uploding_shape"
|
||||||
|
android:text="上传" />
|
||||||
|
</LinearLayout>
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
54
app/src/main/res/layout/poi_video_header.xml
Normal file
54
app/src/main/res/layout/poi_video_header.xml
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/road_bg"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="150dp"
|
||||||
|
android:background="@drawable/top_bg"
|
||||||
|
app:layout_constraintLeft_toLeftOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv1"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="poi录像"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="25sp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/road_bg"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/road_bg"
|
||||||
|
app:layout_constraintRight_toRightOf="@id/road_bg"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/road_bg" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginRight="15dp"
|
||||||
|
android:background="@drawable/top_bg_line_left"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/tv1"
|
||||||
|
app:layout_constraintRight_toLeftOf="@id/tv1"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/tv1" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="15dp"
|
||||||
|
android:background="@drawable/top_bg_line_right"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/tv1"
|
||||||
|
app:layout_constraintLeft_toRightOf="@id/tv1"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/tv1" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:text="任务说明"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
app:layout_constraintLeft_toLeftOf="@id/tv1"
|
||||||
|
app:layout_constraintRight_toRightOf="@id/tv1"
|
||||||
|
app:layout_constraintTop_toBottomOf="@id/tv1" />
|
||||||
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
Loading…
x
Reference in New Issue
Block a user