再来一单

This commit is contained in:
lijia 2022-09-02 18:20:34 +08:00
parent 88be111e35
commit 683798229b
26 changed files with 2498 additions and 246 deletions

View File

@ -26,11 +26,34 @@
<entry key="..\:/2022work2/dhhy-cargo/app/src/main/res/layout/order_details_loading_all.xml" value="0.2171875" />
<entry key="..\:/2022work2/dhhy-cargo/app/src/main/res/layout/order_item.xml" value="0.2682291666666667" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_address_switch.xml" value="0.18125" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_anohter_order.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_choice_address.xml" value="0.25" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_dis_car.xml" value="0.19947916666666668" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_goods_add.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_main.xml" value="0.225" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_node_info.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_order_details_all.xml" value="0.2203125" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_order_list.xml" value="0.32916666666666666" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/activity_search_address.xml" value="0.159375" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/assembly_title_block.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/fragment_huoyuan.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/fragment_order_list.xml" value="0.1" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/fragment_wallet.xml" value="0.25416666666666665" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/fragment_waybill_list.xml" value="0.225" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/huoyuan_bottom.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/huoyuan_centent_loading_info.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/huoyuan_content.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/huoyuan_input_car.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/item_cargo.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/item_node_dis.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/item_node_pretend.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/item_null.xml" value="0.23385416666666667" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/my.xml" value="0.33" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/order_details_all.xml" value="0.23385416666666667" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/order_details_loading_all.xml" value="0.2203125" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/order_item.xml" value="0.36614583333333334" />
<entry key="..\:/goodluckapp/dhhy-cargo/app/src/main/res/layout/order_list_top.xml" value="0.25416666666666665" />
<entry key="..\:/goodluckapp/dhhy-cargo/mylibrary/src/main/res/layout/common_toolbar.xml" value="0.36614583333333334" />
</map>
</option>
</component>

View File

@ -1,5 +1,8 @@
plugins {
id 'com.android.application'
id 'kotlin-android'
id 'kotlin-kapt'
id 'kotlin-android-extensions'
}
android {
@ -90,6 +93,8 @@ dependencies {
//
implementation 'com.scwang.smart:refresh-layout-kernel:2.0.1'
implementation 'com.scwang.smart:refresh-header-material:2.0.1'
implementation 'com.scwang.smart:refresh-footer-ball:2.0.1' //
implementation 'com.scwang.smart:refresh-footer-classics:2.0.1' //
implementation 'com.alibaba:fastjson:1.2.61'
//
implementation 'com.github.jenly1314.AppUpdater:app-updater:1.1.0'

View File

@ -100,6 +100,13 @@
<activity android:name=".ui.home.ChoiceAddressActivity" android:screenOrientation="portrait"/>
<activity android:name=".ui.home.DisCarActivity" android:screenOrientation="portrait"/>
<activity android:name=".ui.news.NewsXActivity" android:screenOrientation="portrait"/>
<activity
android:name=".ui.waybill.activity.AnotherOrderActivity"
android:configChanges="keyboardHidden|orientation|locale"
android:launchMode="singleTask"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustPan|stateHidden"></activity>
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="com.oneclouds.cargo.fileprovider"

View File

@ -0,0 +1,955 @@
package com.oneclouds.cargo.bean;
import java.util.List;
/**
* @ClassName OrderBean2
* @Author 用户
* @Date 2022/9/1 17:06
* @Description TODO
*/
public class OrderBean2 {
private int alctGoodsType;
private String allowSplitting;
private int businessType;
private String carId;
private String carNumber;
private String contactName;
private String contactPhone;
private String contractTemplateUrl;
private String distance;
private String driverTax;
private String effectiveTime;
private String etcCost;
private String failedReason;
private int goodsBigCate;
private String goodsValue;
private long id;
private String insureAmount;
private String isInsure;
private String loadingAddress;
private String loadingDeadline;
private String loadingName;
private String loadingPhone;
private String loadingProvinceCityArea;
private String namedDrivers;
private String oliCost;
private String orderNum;
private String otherCost;
private String platformTotalFreight;
private List<PutInfoDTO> putInfo;
private String receiverAddress;
private String receiverDeadline;
private String receiverName;
private String receiverPhone;
private String receiverProvinceCityArea;
private String report;
private String requirement;
private List<SendInfoDTO> sendInfo;
private String sendPutString;
private String shipperId;
private long status;
private String statusOver;
private String totalFreight;
private int vehicleLength;
private String vehicleLengthName;
private int vehicleType;
private String vehicleTypeName;
private long waybillId;
public int getAlctGoodsType() {
return alctGoodsType;
}
public void setAlctGoodsType(int alctGoodsType) {
this.alctGoodsType = alctGoodsType;
}
public String getAllowSplitting() {
return allowSplitting;
}
public void setAllowSplitting(String allowSplitting) {
this.allowSplitting = allowSplitting;
}
public int getBusinessType() {
return businessType;
}
public void setBusinessType(int businessType) {
this.businessType = businessType;
}
public String getCarId() {
return carId;
}
public void setCarId(String carId) {
this.carId = carId;
}
public String getCarNumber() {
return carNumber;
}
public void setCarNumber(String carNumber) {
this.carNumber = carNumber;
}
public String getContactName() {
return contactName;
}
public void setContactName(String contactName) {
this.contactName = contactName;
}
public String getContactPhone() {
return contactPhone;
}
public void setContactPhone(String contactPhone) {
this.contactPhone = contactPhone;
}
public String getContractTemplateUrl() {
return contractTemplateUrl;
}
public void setContractTemplateUrl(String contractTemplateUrl) {
this.contractTemplateUrl = contractTemplateUrl;
}
public String getDistance() {
return distance;
}
public void setDistance(String distance) {
this.distance = distance;
}
public String getDriverTax() {
return driverTax;
}
public void setDriverTax(String driverTax) {
this.driverTax = driverTax;
}
public String getEffectiveTime() {
return effectiveTime;
}
public void setEffectiveTime(String effectiveTime) {
this.effectiveTime = effectiveTime;
}
public String getEtcCost() {
return etcCost;
}
public void setEtcCost(String etcCost) {
this.etcCost = etcCost;
}
public String getFailedReason() {
return failedReason;
}
public void setFailedReason(String failedReason) {
this.failedReason = failedReason;
}
public int getGoodsBigCate() {
return goodsBigCate;
}
public void setGoodsBigCate(int goodsBigCate) {
this.goodsBigCate = goodsBigCate;
}
public String getGoodsValue() {
return goodsValue;
}
public void setGoodsValue(String goodsValue) {
this.goodsValue = goodsValue;
}
public long getId() {
return id;
}
public void setId(long id) {
this.id = id;
}
public String getInsureAmount() {
return insureAmount;
}
public void setInsureAmount(String insureAmount) {
this.insureAmount = insureAmount;
}
public String getIsInsure() {
return isInsure;
}
public void setIsInsure(String isInsure) {
this.isInsure = isInsure;
}
public String getLoadingAddress() {
return loadingAddress;
}
public void setLoadingAddress(String loadingAddress) {
this.loadingAddress = loadingAddress;
}
public String getLoadingDeadline() {
return loadingDeadline;
}
public void setLoadingDeadline(String loadingDeadline) {
this.loadingDeadline = loadingDeadline;
}
public String getLoadingName() {
return loadingName;
}
public void setLoadingName(String loadingName) {
this.loadingName = loadingName;
}
public String getLoadingPhone() {
return loadingPhone;
}
public void setLoadingPhone(String loadingPhone) {
this.loadingPhone = loadingPhone;
}
public String getLoadingProvinceCityArea() {
return loadingProvinceCityArea;
}
public void setLoadingProvinceCityArea(String loadingProvinceCityArea) {
this.loadingProvinceCityArea = loadingProvinceCityArea;
}
public String getNamedDrivers() {
return namedDrivers;
}
public void setNamedDrivers(String namedDrivers) {
this.namedDrivers = namedDrivers;
}
public String getOliCost() {
return oliCost;
}
public void setOliCost(String oliCost) {
this.oliCost = oliCost;
}
public String getOrderNum() {
return orderNum;
}
public void setOrderNum(String orderNum) {
this.orderNum = orderNum;
}
public String getOtherCost() {
return otherCost;
}
public void setOtherCost(String otherCost) {
this.otherCost = otherCost;
}
public String getPlatformTotalFreight() {
return platformTotalFreight;
}
public void setPlatformTotalFreight(String platformTotalFreight) {
this.platformTotalFreight = platformTotalFreight;
}
public List<PutInfoDTO> getPutInfo() {
return putInfo;
}
public void setPutInfo(List<PutInfoDTO> putInfo) {
this.putInfo = putInfo;
}
public String getReceiverAddress() {
return receiverAddress;
}
public void setReceiverAddress(String receiverAddress) {
this.receiverAddress = receiverAddress;
}
public String getReceiverDeadline() {
return receiverDeadline;
}
public void setReceiverDeadline(String receiverDeadline) {
this.receiverDeadline = receiverDeadline;
}
public String getReceiverName() {
return receiverName;
}
public void setReceiverName(String receiverName) {
this.receiverName = receiverName;
}
public String getReceiverPhone() {
return receiverPhone;
}
public void setReceiverPhone(String receiverPhone) {
this.receiverPhone = receiverPhone;
}
public String getReceiverProvinceCityArea() {
return receiverProvinceCityArea;
}
public void setReceiverProvinceCityArea(String receiverProvinceCityArea) {
this.receiverProvinceCityArea = receiverProvinceCityArea;
}
public String getReport() {
return report;
}
public void setReport(String report) {
this.report = report;
}
public String getRequirement() {
return requirement;
}
public void setRequirement(String requirement) {
this.requirement = requirement;
}
public List<SendInfoDTO> getSendInfo() {
return sendInfo;
}
public void setSendInfo(List<SendInfoDTO> sendInfo) {
this.sendInfo = sendInfo;
}
public String getSendPutString() {
return sendPutString;
}
public void setSendPutString(String sendPutString) {
this.sendPutString = sendPutString;
}
public String getShipperId() {
return shipperId;
}
public void setShipperId(String shipperId) {
this.shipperId = shipperId;
}
public long getStatus() {
return status;
}
public void setStatus(long status) {
this.status = status;
}
public String getStatusOver() {
return statusOver;
}
public void setStatusOver(String statusOver) {
this.statusOver = statusOver;
}
public String getTotalFreight() {
return totalFreight;
}
public void setTotalFreight(String totalFreight) {
this.totalFreight = totalFreight;
}
public int getVehicleLength() {
return vehicleLength;
}
public void setVehicleLength(int vehicleLength) {
this.vehicleLength = vehicleLength;
}
public String getVehicleLengthName() {
return vehicleLengthName;
}
public void setVehicleLengthName(String vehicleLengthName) {
this.vehicleLengthName = vehicleLengthName;
}
public int getVehicleType() {
return vehicleType;
}
public void setVehicleType(int vehicleType) {
this.vehicleType = vehicleType;
}
public String getVehicleTypeName() {
return vehicleTypeName;
}
public void setVehicleTypeName(String vehicleTypeName) {
this.vehicleTypeName = vehicleTypeName;
}
public long getWaybillId() {
return waybillId;
}
public void setWaybillId(long waybillId) {
this.waybillId = waybillId;
}
public static class PutInfoDTO {
private String address;
private long area;
private String businessCode;
private String businessName;
private Long childNumber;
private long city;
private String createTime;
private String deadline;
private long displayOrder;
private List<GoodsDTO> goods;
private String latitude;
private String longitude;
private String name;
private String phone;
private long pid;
private long province;
private String provinceCityArea;
private long status;
private String totalAmount;
private long type;
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
public long getArea() {
return area;
}
public void setArea(long area) {
this.area = area;
}
public String getBusinessCode() {
return businessCode;
}
public void setBusinessCode(String businessCode) {
this.businessCode = businessCode;
}
public String getBusinessName() {
return businessName;
}
public void setBusinessName(String businessName) {
this.businessName = businessName;
}
public Long getChildNumber() {
return childNumber;
}
public void setChildNumber(Long childNumber) {
this.childNumber = childNumber;
}
public long getCity() {
return city;
}
public void setCity(long city) {
this.city = city;
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime;
}
public String getDeadline() {
return deadline;
}
public void setDeadline(String deadline) {
this.deadline = deadline;
}
public long getDisplayOrder() {
return displayOrder;
}
public void setDisplayOrder(long displayOrder) {
this.displayOrder = displayOrder;
}
public List<GoodsDTO> getGoods() {
return goods;
}
public void setGoods(List<GoodsDTO> goods) {
this.goods = goods;
}
public String getLatitude() {
return latitude;
}
public void setLatitude(String latitude) {
this.latitude = latitude;
}
public String getLongitude() {
return longitude;
}
public void setLongitude(String longitude) {
this.longitude = longitude;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone;
}
public long getPid() {
return pid;
}
public void setPid(long pid) {
this.pid = pid;
}
public long getProvince() {
return province;
}
public void setProvince(long province) {
this.province = province;
}
public String getProvinceCityArea() {
return provinceCityArea;
}
public void setProvinceCityArea(String provinceCityArea) {
this.provinceCityArea = provinceCityArea;
}
public long getStatus() {
return status;
}
public void setStatus(long status) {
this.status = status;
}
public String getTotalAmount() {
return totalAmount;
}
public void setTotalAmount(String totalAmount) {
this.totalAmount = totalAmount;
}
public long getType() {
return type;
}
public void setType(long type) {
this.type = type;
}
public static class GoodsDTO {
private Long childrenId;
private String createTime;
private String goodName;
private String goodNum;
private String goodPrice;
private String goodUnit;
private Long id;
private String packName;
public Long getChildrenId() {
return childrenId;
}
public void setChildrenId(Long childrenId) {
this.childrenId = childrenId;
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime;
}
public String getGoodName() {
return goodName;
}
public void setGoodName(String goodName) {
this.goodName = goodName;
}
public String getGoodNum() {
return goodNum;
}
public void setGoodNum(String goodNum) {
this.goodNum = goodNum;
}
public String getGoodPrice() {
return goodPrice;
}
public void setGoodPrice(String goodPrice) {
this.goodPrice = goodPrice;
}
public String getGoodUnit() {
return goodUnit;
}
public void setGoodUnit(String goodUnit) {
this.goodUnit = goodUnit;
}
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getPackName() {
return packName;
}
public void setPackName(String packName) {
this.packName = packName;
}
}
}
public static class SendInfoDTO {
private String address;
private long area;
private String businessCode;
private String businessName;
private Long childNumber;
private long city;
private String createTime;
private String deadline;
private long displayOrder;
private List<GoodsDTO> goods;
private String latitude;
private String longitude;
private String name;
private String phone;
private long pid;
private long province;
private String provinceCityArea;
private long status;
private String totalAmount;
private long type;
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
public long getArea() {
return area;
}
public void setArea(long area) {
this.area = area;
}
public String getBusinessCode() {
return businessCode;
}
public void setBusinessCode(String businessCode) {
this.businessCode = businessCode;
}
public String getBusinessName() {
return businessName;
}
public void setBusinessName(String businessName) {
this.businessName = businessName;
}
public Long getChildNumber() {
return childNumber;
}
public void setChildNumber(Long childNumber) {
this.childNumber = childNumber;
}
public long getCity() {
return city;
}
public void setCity(long city) {
this.city = city;
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime;
}
public String getDeadline() {
return deadline;
}
public void setDeadline(String deadline) {
this.deadline = deadline;
}
public long getDisplayOrder() {
return displayOrder;
}
public void setDisplayOrder(long displayOrder) {
this.displayOrder = displayOrder;
}
public List<GoodsDTO> getGoods() {
return goods;
}
public void setGoods(List<GoodsDTO> goods) {
this.goods = goods;
}
public String getLatitude() {
return latitude;
}
public void setLatitude(String latitude) {
this.latitude = latitude;
}
public String getLongitude() {
return longitude;
}
public void setLongitude(String longitude) {
this.longitude = longitude;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone;
}
public long getPid() {
return pid;
}
public void setPid(long pid) {
this.pid = pid;
}
public long getProvince() {
return province;
}
public void setProvince(long province) {
this.province = province;
}
public String getProvinceCityArea() {
return provinceCityArea;
}
public void setProvinceCityArea(String provinceCityArea) {
this.provinceCityArea = provinceCityArea;
}
public long getStatus() {
return status;
}
public void setStatus(long status) {
this.status = status;
}
public String getTotalAmount() {
return totalAmount;
}
public void setTotalAmount(String totalAmount) {
this.totalAmount = totalAmount;
}
public long getType() {
return type;
}
public void setType(long type) {
this.type = type;
}
public static class GoodsDTO {
private Long childrenId;
private String createTime;
private String goodName;
private String goodNum;
private String goodPrice;
private String goodUnit;
private Long id;
private String packName;
public Long getChildrenId() {
return childrenId;
}
public void setChildrenId(Long childrenId) {
this.childrenId = childrenId;
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime;
}
public String getGoodName() {
return goodName;
}
public void setGoodName(String goodName) {
this.goodName = goodName;
}
public String getGoodNum() {
return goodNum;
}
public void setGoodNum(String goodNum) {
this.goodNum = goodNum;
}
public String getGoodPrice() {
return goodPrice;
}
public void setGoodPrice(String goodPrice) {
this.goodPrice = goodPrice;
}
public String getGoodUnit() {
return goodUnit;
}
public void setGoodUnit(String goodUnit) {
this.goodUnit = goodUnit;
}
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getPackName() {
return packName;
}
public void setPackName(String packName) {
this.packName = packName;
}
}
}
}

View File

@ -73,7 +73,7 @@ public class WaybillRequest {
map.put("orderStatus",orderStatus);
}
Request re = OkHttpUtil.posts(new OkDate(UrlManager.getWaybillListV2(), "post", MapUtil.mapJson(map)),getToken(con),con);
RequestTest.test(1,WAYBILL_LIST_V2,re,con,hd);
RequestTest.test(1,WAYBILL_LIST_V2+orderStatus,re,con,hd);
}
//运单详情
public void orderDetail(int waybillId){

View File

@ -0,0 +1,19 @@
package com.oneclouds.cargo.request.bean;
/**
* @ClassName CommonBodyBean
* @Author 用户
* @Date 2022/9/1 11:42
* @Description TODO
*/
public class CommonBodyBean {
private String id;
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
}

View File

@ -16,6 +16,15 @@ public class OrderInputBean {
private List<PutTableDataDTO> putTableData;
private List<SendTableDataDTO> sendTableData;
public OrderInputBean() {
}
public OrderInputBean(FormDataDTO formData, List<PutTableDataDTO> putTableData, List<SendTableDataDTO> sendTableData) {
this.formData = formData;
this.putTableData = putTableData;
this.sendTableData = sendTableData;
}
public FormDataDTO getFormData() {
return formData;
}

View File

@ -2,11 +2,14 @@ package com.oneclouds.cargo.request.net;
import com.dahe.mylibrary.net.CommonResponseBean;
import com.oneclouds.cargo.request.bean.LoginRegInputBean;
import com.oneclouds.cargo.bean.OrderBean2;
import com.oneclouds.cargo.request.bean.CommonBodyBean;
import com.oneclouds.cargo.request.bean.OrderInputBean;
import io.reactivex.rxjava3.core.Observable;
import retrofit2.http.Body;
import retrofit2.http.POST;
import retrofit2.http.Query;
/**
* Created by Administrator on 2018/8/8 0008.
@ -20,8 +23,16 @@ public interface Api {
//获取版本
String VERSION = BASE_URL + "app/version";
//运单详情
// @HTTP(method = "post",path = BASE_URL+"app/shipper/waybill/getExecuteWaybill", hasBody = true) waybillId
// Observable<CommonResponseBean> waybillDetail(@Field("waybillId") String bean);
@POST(BASE_URL+"app/shipper/waybill/getOrderDetail")
Observable<CommonResponseBean<OrderBean2>> waybillDetail(@Body CommonBodyBean bean);
@POST(BASE_URL+"app/bank/getContracts")
Observable<CommonResponseBean> log(@Body String bean);
@POST(BASE_URL+"/app/shipper/waybill/app/getOrderDetail")
Observable<CommonResponseBean<OrderInputBean>> waybillDetail2(@Body CommonBodyBean bean);
@POST(BASE_URL+"app/shipper/order/publishOrder")
Observable<CommonResponseBean> againOrder(@Body OrderInputBean bean);
}

View File

@ -51,8 +51,8 @@ public class DataManager {
.connectTimeout(30, TimeUnit.SECONDS)
.readTimeout(30, TimeUnit.SECONDS)
.writeTimeout(30, TimeUnit.SECONDS)
.addInterceptor(new JsonInterceptor())
.addInterceptor(new RequestHeadInterceptor())
.addInterceptor(new JsonInterceptor())
.build())
// .addNetworkInterceptor(new TokenInterceptor())
.build().create(Api.class);

View File

@ -5,9 +5,11 @@ import android.util.Log;
import com.dahe.mylibrary.utils.AppUtils;
import com.dahe.mylibrary.utils.BaseUtils;
import com.oneclouds.cargo.constant.SPConstant;
import com.oneclouds.cargo.ui.App;
import com.oneclouds.cargo.ui.LoginActivity;
import com.oneclouds.cargo.util.SPUtil;
import com.oneclouds.cargo.util.http.GetUtil;
import java.io.IOException;
@ -25,16 +27,18 @@ public class RequestHeadInterceptor implements Interceptor {
@Override
public Response intercept(Chain chain) throws IOException {
Request.Builder builder = chain.request().newBuilder();
if (!TextUtils.isEmpty(SPUtil.getSP(App.getApp(), LoginActivity.USER,LoginActivity.USER_TOKEN))) {
if (!TextUtils.isEmpty(SPUtil.getSP(App.getApp(), SPConstant.DATA,SPConstant.DATA_TOKEN))) {
// builder.addHeader("Authorization", SPUtils.getUserInfo(App.getApp()).getToken());
builder.addHeader("Authorization", SPUtil.getSP(App.getApp(), LoginActivity.USER,LoginActivity.USER_TOKEN));
builder.addHeader("Authorization", SPUtil.getSP(App.getApp(), SPConstant.DATA,SPConstant.DATA_TOKEN));
}
Request request = builder
.addHeader("Content-Type", "application/json")
.addHeader("versionCode", AppUtils.getAppVersionCode() + "")
.addHeader("versionValue", AppUtils.getAppVersionName() + "")
.addHeader("deviceType", "ANDROID")
.addHeader("language", BaseUtils.getLanguage(App.getApp())+"")
.build();
// .addHeader("Content-Type", "application/json")
Log.i(TAG, "intercept: " + request.headers());
return chain.proceed(request);
}

View File

@ -15,8 +15,8 @@ import com.oneclouds.cargo.R;
import com.oneclouds.cargo.constant.SPConstant;
import com.oneclouds.cargo.ui.home.HomeFragment;
import com.oneclouds.cargo.ui.my.MyFragment;
import com.oneclouds.cargo.ui.news.NewsFragment;
import com.oneclouds.cargo.ui.wallet.WalletFragment;
import com.oneclouds.cargo.ui.waybill.WayBillsFragment;
import com.oneclouds.cargo.util.SPUtil;
import com.oneclouds.cargo.util.titleutil.StateStyleUtil;
import com.oneclouds.cargo.util.view.BaseAppCompatActivity;
@ -41,7 +41,7 @@ public class MainActivity extends BaseAppCompatActivity {
act=this;
fs[0]=new HomeFragment();
fs[1]=new WalletFragment();
fs[2]=new NewsFragment();
fs[2]=new WayBillsFragment();
fs[3]=new MyFragment();
initfindId();
initswitch();

View File

@ -188,9 +188,13 @@ public class GoodsDischargeActivity extends BaseActivity {
price.setText(o.getPrice() + "");
if (o.getUnit().equals("")) {
num1.setText(o.getNum());
num2.setText("");
num2.setEnabled(false);
num1.setEnabled(true);
} else {
num2.setText(o.getNum());
num1.setText("");
num2.setEnabled(true);
num1.setEnabled(false);
key = false;
}

View File

@ -23,10 +23,12 @@ import com.oneclouds.cargo.bean.BaseBean;
import com.oneclouds.cargo.bean.WaybillListBean;
import com.oneclouds.cargo.request.OrderRequest;
import com.oneclouds.cargo.request.WaybillRequest;
import com.oneclouds.cargo.ui.home.NodeInfoActivity;
import com.oneclouds.cargo.ui.home.OrderDetailsActivity;
import com.oneclouds.cargo.ui.home.OrderDetailsAllActivity;
import com.oneclouds.cargo.ui.my.invoice.InvoiceCreateActivity;
import com.oneclouds.cargo.ui.parts.TypeParts;
import com.oneclouds.cargo.ui.waybill.activity.AnotherOrderActivity;
import com.oneclouds.cargo.util.ToastUtil;
import com.oneclouds.cargo.util.adapter.AdapterAlls;
import com.oneclouds.cargo.util.adapter.ManyBean;
@ -74,9 +76,9 @@ public class OrderList1Fragment extends BaseFragment {
sr.finishRefresh();
sr.finishLoadMore();
//获取数据
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2),WaybillListBean.class);
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type),WaybillListBean.class);
if(olb.getCode()==200){
if(index==1){
initData();
@ -86,7 +88,7 @@ public class OrderList1Fragment extends BaseFragment {
}else{
ToastUtil.show(con,"加载失败");
}
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2);
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2+type);
}
//撤销
if (CacheGroup.cacheList.get(OrderRequest.ORDER_REVOKE)!=null) {
@ -121,7 +123,7 @@ public class OrderList1Fragment extends BaseFragment {
}
}
private Button submit;
// private Button submit;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@ -132,19 +134,6 @@ public class OrderList1Fragment extends BaseFragment {
wr=new WaybillRequest(con,hd);
or=new OrderRequest(con,hd);
order_brv=root.findViewById(R.id.order_brv);
submit=root.findViewById(R.id.submit);
submit.setOnClickListener(v -> {
if(submit_map.size()>0){
Intent in=new Intent(con, InvoiceCreateActivity.class);
in.putExtra("list",gson.toJson(submit_map));
startActivity(in);
}else{
Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
}
});
if(type==0 || type==102005){
submit.setVisibility(View.VISIBLE);
}
initRefreshLoad();
initView(null);
return root;
@ -162,6 +151,7 @@ public class OrderList1Fragment extends BaseFragment {
case R.layout.order_item:
WaybillListBean.DataDTO.ListDTO ld= (WaybillListBean.DataDTO.ListDTO) o;
Button btn=v.findViewById(R.id.btn);
Button btnAgain=v.findViewById(R.id.btnAgain);
ImageView state_img=v.findViewById(R.id.state_img);
ImageButton xuan=v.findViewById(R.id.xuan);
v.setOnClickListener(v12 -> {
@ -187,27 +177,33 @@ public class OrderList1Fragment extends BaseFragment {
}
}
btnAgain.setOnClickListener(v1->{
// Intent in=new Intent(con, NodeInfoActivity.class);
Intent in=new Intent(con, AnotherOrderActivity.class);
in.putExtra("id",ld.getOrderId());
startActivity(in);
});
xuan.setOnClickListener(v1 -> {
if(ld.getStatus()==102005){
if (keys.get(position)) {
xuan.setImageResource(R.mipmap.no_xuan);
keys.set(position,false);
num--;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.remove(position);
}else{
xuan.setImageResource(R.mipmap.xuan);
keys.set(position,true);
num++;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.put(position,gson.toJson(o));
}
}else{

View File

@ -76,9 +76,9 @@ public class OrderList2Fragment extends BaseFragment {
sr.finishRefresh();
sr.finishLoadMore();
//获取数据
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2),WaybillListBean.class);
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type),WaybillListBean.class);
if(olb.getCode()==200){
if(index==1){
initData();
@ -88,7 +88,7 @@ public class OrderList2Fragment extends BaseFragment {
}else{
ToastUtil.show(con,"加载失败");
}
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2);
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2+type);
}
//撤销
if (CacheGroup.cacheList.get(OrderRequest.ORDER_REVOKE)!=null) {
@ -123,7 +123,7 @@ public class OrderList2Fragment extends BaseFragment {
}
}
private Button submit;
// private Button submit;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@ -134,19 +134,19 @@ public class OrderList2Fragment extends BaseFragment {
wr=new WaybillRequest(con,hd);
or=new OrderRequest(con,hd);
order_brv=root.findViewById(R.id.order_brv);
submit=root.findViewById(R.id.submit);
submit.setOnClickListener(v -> {
if(submit_map.size()>0){
Intent in=new Intent(con, InvoiceCreateActivity.class);
in.putExtra("list",gson.toJson(submit_map));
startActivity(in);
}else{
Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
}
});
if(type==0 || type==102005){
submit.setVisibility(View.VISIBLE);
}
// submit=root.findViewById(R.id.submit);
// submit.setOnClickListener(v -> {
// if(submit_map.size()>0){
// Intent in=new Intent(con, InvoiceCreateActivity.class);
// in.putExtra("list",gson.toJson(submit_map));
// startActivity(in);
// }else{
// Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
// }
// });
// if(type==0 || type==102005){
// submit.setVisibility(View.VISIBLE);
// }
initRefreshLoad();
initView(null);
return root;
@ -195,21 +195,21 @@ public class OrderList2Fragment extends BaseFragment {
xuan.setImageResource(R.mipmap.no_xuan);
keys.set(position,false);
num--;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.remove(position);
}else{
xuan.setImageResource(R.mipmap.xuan);
keys.set(position,true);
num++;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.put(position,gson.toJson(o));
}
}else{

View File

@ -76,9 +76,9 @@ public class OrderList3Fragment extends BaseFragment {
sr.finishRefresh();
sr.finishLoadMore();
//获取数据
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2),WaybillListBean.class);
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type),WaybillListBean.class);
if(olb.getCode()==200){
if(index==1){
initData();
@ -88,7 +88,7 @@ public class OrderList3Fragment extends BaseFragment {
}else{
ToastUtil.show(con,"加载失败");
}
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2);
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2+type);
}
//撤销
if (CacheGroup.cacheList.get(OrderRequest.ORDER_REVOKE)!=null) {
@ -123,7 +123,7 @@ public class OrderList3Fragment extends BaseFragment {
}
}
private Button submit;
// private Button submit;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@ -134,19 +134,19 @@ public class OrderList3Fragment extends BaseFragment {
wr=new WaybillRequest(con,hd);
or=new OrderRequest(con,hd);
order_brv=root.findViewById(R.id.order_brv);
submit=root.findViewById(R.id.submit);
submit.setOnClickListener(v -> {
if(submit_map.size()>0){
Intent in=new Intent(con, InvoiceCreateActivity.class);
in.putExtra("list",gson.toJson(submit_map));
startActivity(in);
}else{
Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
}
});
if(type==0 || type==102005){
submit.setVisibility(View.VISIBLE);
}
// submit=root.findViewById(R.id.submit);
// submit.setOnClickListener(v -> {
// if(submit_map.size()>0){
// Intent in=new Intent(con, InvoiceCreateActivity.class);
// in.putExtra("list",gson.toJson(submit_map));
// startActivity(in);
// }else{
// Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
// }
// });
// if(type==0 || type==102005){
// submit.setVisibility(View.VISIBLE);
// }
initRefreshLoad();
initView(null);
return root;
@ -195,21 +195,21 @@ public class OrderList3Fragment extends BaseFragment {
xuan.setImageResource(R.mipmap.no_xuan);
keys.set(position,false);
num--;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.remove(position);
}else{
xuan.setImageResource(R.mipmap.xuan);
keys.set(position,true);
num++;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.put(position,gson.toJson(o));
}
}else{

View File

@ -76,9 +76,9 @@ public class OrderList4Fragment extends BaseFragment {
sr.finishRefresh();
sr.finishLoadMore();
//获取数据
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2),WaybillListBean.class);
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type),WaybillListBean.class);
if(olb.getCode()==200){
if(index==1){
initData();
@ -88,7 +88,7 @@ public class OrderList4Fragment extends BaseFragment {
}else{
ToastUtil.show(con,"加载失败");
}
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2);
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2+type);
}
//撤销
if (CacheGroup.cacheList.get(OrderRequest.ORDER_REVOKE)!=null) {
@ -123,7 +123,7 @@ public class OrderList4Fragment extends BaseFragment {
}
}
private Button submit;
// private Button submit;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@ -134,19 +134,19 @@ public class OrderList4Fragment extends BaseFragment {
wr=new WaybillRequest(con,hd);
or=new OrderRequest(con,hd);
order_brv=root.findViewById(R.id.order_brv);
submit=root.findViewById(R.id.submit);
submit.setOnClickListener(v -> {
if(submit_map.size()>0){
Intent in=new Intent(con, InvoiceCreateActivity.class);
in.putExtra("list",gson.toJson(submit_map));
startActivity(in);
}else{
Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
}
});
if(type==0 || type==102005){
submit.setVisibility(View.VISIBLE);
}
// submit=root.findViewById(R.id.submit);
// submit.setOnClickListener(v -> {
// if(submit_map.size()>0){
// Intent in=new Intent(con, InvoiceCreateActivity.class);
// in.putExtra("list",gson.toJson(submit_map));
// startActivity(in);
// }else{
// Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
// }
// });
// if(type==0 || type==102005){
// submit.setVisibility(View.VISIBLE);
// }
initRefreshLoad();
initView(null);
return root;
@ -195,21 +195,21 @@ public class OrderList4Fragment extends BaseFragment {
xuan.setImageResource(R.mipmap.no_xuan);
keys.set(position,false);
num--;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.remove(position);
}else{
xuan.setImageResource(R.mipmap.xuan);
keys.set(position,true);
num++;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.put(position,gson.toJson(o));
}
}else{

View File

@ -74,9 +74,9 @@ public class OrderList5Fragment extends BaseFragment {
sr.finishRefresh();
sr.finishLoadMore();
//获取数据
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2),WaybillListBean.class);
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type),WaybillListBean.class);
if(olb.getCode()==200){
if(index==1){
initData();
@ -86,7 +86,7 @@ public class OrderList5Fragment extends BaseFragment {
}else{
ToastUtil.show(con,"加载失败");
}
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2);
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2+type);
}
//撤销
if (CacheGroup.cacheList.get(OrderRequest.ORDER_REVOKE)!=null) {
@ -121,7 +121,7 @@ public class OrderList5Fragment extends BaseFragment {
}
}
private Button submit;
// private Button submit;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@ -132,19 +132,19 @@ public class OrderList5Fragment extends BaseFragment {
wr=new WaybillRequest(con,hd);
or=new OrderRequest(con,hd);
order_brv=root.findViewById(R.id.order_brv);
submit=root.findViewById(R.id.submit);
submit.setOnClickListener(v -> {
if(submit_map.size()>0){
Intent in=new Intent(con, InvoiceCreateActivity.class);
in.putExtra("list",gson.toJson(submit_map));
startActivity(in);
}else{
Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
}
});
if(type==0 || type==102005){
submit.setVisibility(View.VISIBLE);
}
// submit=root.findViewById(R.id.submit);
// submit.setOnClickListener(v -> {
// if(submit_map.size()>0){
// Intent in=new Intent(con, InvoiceCreateActivity.class);
// in.putExtra("list",gson.toJson(submit_map));
// startActivity(in);
// }else{
// Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
// }
// });
// if(type==0 || type==102005){
// submit.setVisibility(View.VISIBLE);
// }
initRefreshLoad();
initView(null);
return root;
@ -193,21 +193,21 @@ public class OrderList5Fragment extends BaseFragment {
xuan.setImageResource(R.mipmap.no_xuan);
keys.set(position,false);
num--;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.remove(position);
}else{
xuan.setImageResource(R.mipmap.xuan);
keys.set(position,true);
num++;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.put(position,gson.toJson(o));
}
}else{

View File

@ -76,9 +76,9 @@ public class OrderList6Fragment extends BaseFragment {
sr.finishRefresh();
sr.finishLoadMore();
//获取数据
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2),WaybillListBean.class);
if (CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type)!=null) {
Log.e("-list-",CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type));
olb=gson.fromJson(CacheGroup.cacheList.get(WaybillRequest.WAYBILL_LIST_V2+type),WaybillListBean.class);
if(olb.getCode()==200){
if(index==1){
initData();
@ -88,7 +88,7 @@ public class OrderList6Fragment extends BaseFragment {
}else{
ToastUtil.show(con,"加载失败");
}
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2);
CacheGroup.cacheList.remove(WaybillRequest.WAYBILL_LIST_V2+type);
}
//撤销
if (CacheGroup.cacheList.get(OrderRequest.ORDER_REVOKE)!=null) {
@ -123,7 +123,7 @@ public class OrderList6Fragment extends BaseFragment {
}
}
private Button submit;
// private Button submit;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
@ -134,19 +134,19 @@ public class OrderList6Fragment extends BaseFragment {
wr=new WaybillRequest(con,hd);
or=new OrderRequest(con,hd);
order_brv=root.findViewById(R.id.order_brv);
submit=root.findViewById(R.id.submit);
submit.setOnClickListener(v -> {
if(submit_map.size()>0){
Intent in=new Intent(con, InvoiceCreateActivity.class);
in.putExtra("list",gson.toJson(submit_map));
startActivity(in);
}else{
Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
}
});
if(type==0 || type==102005){
submit.setVisibility(View.VISIBLE);
}
// submit=root.findViewById(R.id.submit);
// submit.setOnClickListener(v -> {
// if(submit_map.size()>0){
// Intent in=new Intent(con, InvoiceCreateActivity.class);
// in.putExtra("list",gson.toJson(submit_map));
// startActivity(in);
// }else{
// Toast.makeText(con,"请先选择需要开票的订单",Toast.LENGTH_LONG).show();
// }
// });
// if(type==0 || type==102005){
// submit.setVisibility(View.VISIBLE);
// }
initRefreshLoad();
initView(null);
return root;
@ -195,21 +195,21 @@ public class OrderList6Fragment extends BaseFragment {
xuan.setImageResource(R.mipmap.no_xuan);
keys.set(position,false);
num--;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.remove(position);
}else{
xuan.setImageResource(R.mipmap.xuan);
keys.set(position,true);
num++;
if(num>0){
submit.setText("提交开票申请("+num+")");
}else{
submit.setText("提交开票申请");
}
// if(num>0){
// submit.setText("提交开票申请("+num+")");
// }else{
// submit.setText("提交开票申请");
// }
submit_map.put(position,gson.toJson(o));
}
}else{

View File

@ -0,0 +1,67 @@
package com.oneclouds.cargo.ui.waybill
import androidx.fragment.app.Fragment
import androidx.fragment.app.FragmentManager
import androidx.fragment.app.FragmentPagerAdapter
import com.dahe.mylibrary.base.BaseFragment
import com.oneclouds.cargo.R
import com.oneclouds.cargo.ui.home.OrderListActivity
import com.oneclouds.cargo.ui.home.typelist.*
import com.oneclouds.cargo.ui.parts.UserParts
import com.xuexiang.xui.widget.tabbar.TabSegment
import kotlinx.android.synthetic.main.fragment_waybill_list.*
import kotlinx.android.synthetic.main.order_list_top.*
/**
* @ClassName WayBillsFragment
* @Author 用户
* @Date 2022/9/1 9:26
* @Description TODO
*/
class WayBillsFragment : BaseFragment() {
var list = mutableListOf<Fragment>()
private val titles = arrayOf("全部", "待调度", "已装货", "已卸货", "已结算")
override fun getContentViewLayoutID() = R.layout.fragment_waybill_list
override fun onFragmentVisibleChange(isVisible: Boolean) {
}
override fun onFragmentFirstVisible() {
val user = UserParts.getUser(activity)
waybillNum.text = user.data.waybillNum.toString()
distance.text = user.data.distance.toString()
freight.text = user.data.freight.toString()
list.add(OrderList1Fragment())
list.add(OrderList2Fragment())
list.add(OrderList3Fragment())
list.add(OrderList4Fragment())
list.add(OrderList5Fragment())
for (page in titles) {
tabSegment.addTab(TabSegment.Tab(page))
}
vp.adapter = MyAdapter(this.fragmentManager)
tabSegment.setupWithViewPager(vp, false)
tabSegment.setMode(TabSegment.MODE_FIXED)
}
inner class MyAdapter(fm: FragmentManager?) :
FragmentPagerAdapter(fm!!) {
override fun getItem(position: Int): Fragment {
return list.get(position)
}
override fun getCount(): Int {
return list.size
}
//重写这个方法将设置每个Tab的标题
override fun getPageTitle(position: Int): CharSequence? {
return titles.get(position)
}
}
}

View File

@ -0,0 +1,632 @@
package com.oneclouds.cargo.ui.waybill.activity
import android.content.Intent
import android.os.Bundle
import android.text.TextUtils
import android.util.Log
import android.view.View
import android.widget.EditText
import android.widget.RelativeLayout
import android.widget.TextView
import android.widget.Toast
import com.dahe.mylibrary.base.BaseActivity
import com.dahe.mylibrary.net.CommonResponseBean
import com.github.gzuliyujiang.wheelpicker.DatimePicker
import com.github.gzuliyujiang.wheelpicker.OptionPicker
import com.github.gzuliyujiang.wheelpicker.annotation.DateMode
import com.github.gzuliyujiang.wheelpicker.annotation.TimeMode
import com.github.gzuliyujiang.wheelpicker.entity.DatimeEntity
import com.google.gson.Gson
import com.lxj.xpopup.XPopup
import com.oneclouds.cargo.R
import com.oneclouds.cargo.base.AppConfig
import com.oneclouds.cargo.bean.*
import com.oneclouds.cargo.event.AddressEvent
import com.oneclouds.cargo.event.BaseEvent
import com.oneclouds.cargo.event.GoodsEvent
import com.oneclouds.cargo.request.bean.CommonBodyBean
import com.oneclouds.cargo.request.bean.OrderInputBean
import com.oneclouds.cargo.request.bean.OrderInputBean.PutTableDataDTO
import com.oneclouds.cargo.request.bean.OrderInputBean.SendTableDataDTO
import com.oneclouds.cargo.request.net.BaseObserver
import com.oneclouds.cargo.request.net.DataManager
import com.oneclouds.cargo.request.net.RxHttpCallBack
import com.oneclouds.cargo.ui.LoginActivity
import com.oneclouds.cargo.ui.UiAuxiliary
import com.oneclouds.cargo.ui.home.DisCarActivity
import com.oneclouds.cargo.ui.home.GoodsActivity
import com.oneclouds.cargo.ui.home.GoodsDischargeActivity
import com.oneclouds.cargo.ui.my.AddressActivity
import com.oneclouds.cargo.ui.parts.TypeParts
import com.oneclouds.cargo.ui.parts.UserParts
import com.oneclouds.cargo.util.StringUtil
import com.oneclouds.cargo.util.adapter.AdapterAll
import com.oneclouds.cargo.util.adapter.AdapterAlls
import com.oneclouds.cargo.util.adapter.ManyBean
import com.oneclouds.cargo.util.view.BaseRecyclerView
import com.oneclouds.cargo.weight.RecyclerViewDecoration
import kotlinx.android.synthetic.main.activity_anohter_order.*
import kotlinx.android.synthetic.main.item_node_pretend.*
import org.greenrobot.eventbus.EventBus
import org.greenrobot.eventbus.Subscribe
/**
* @ClassName AnotherOrderActivity
* @Author 用户
* @Date 2022/9/1 10:34
* @Description TODO
*/
class AnotherOrderActivity : BaseActivity() {
lateinit var tvName: TextView
lateinit var tvNameDis: TextView
lateinit var tvPhone: TextView
lateinit var tvPhoneDis: TextView
lateinit var tvAddress: TextView
lateinit var tvAddressDis: TextView
lateinit var tvStartTime: TextView
lateinit var etMoney: EditText
lateinit var tvEndTimeDis: TextView
lateinit var ryPretend: BaseRecyclerView
lateinit var ryDis: BaseRecyclerView
private var goodsType = 0 //0装 1卸
private var updatePosGoods = -1
private var updatePosGoodsDis = -1
var gson = Gson()
private var oib = OrderInputBean(OrderInputBean.FormDataDTO(),
mutableListOf<PutTableDataDTO>(),
mutableListOf<SendTableDataDTO>())
override fun getLayout() = R.layout.activity_anohter_order
override fun initView(savedInstanceState: Bundle?) {
setStatusBarColor(R.color.color_theme)
setTitleBar("再来一单") { finish() }
EventBus.getDefault().register(this)
initRe()
initListener()
}
override fun initDate() {
val waybillId = getIntent().getExtras()?.getInt("id")
waybillId?.let {
DataManager.getInstance()
.waybillDetail2(CommonBodyBean().apply { id = waybillId.toString() })
.compose(DataManager.setThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<OrderInputBean>() {
override fun onSuccess(t: CommonResponseBean<OrderInputBean>) {
super.onSuccess(t)
oib = t.data
initRe()
}
}))
}
}
fun initRe() {
val list: MutableList<ManyBean> = ArrayList()
list.add(ManyBean(AddressBean(), R.layout.item_node_pretend))
list.add(ManyBean(AddressBean(), R.layout.item_node_dis))
rv.creates(this, list)
.setOnItemViewListener(AdapterAlls.onItemViewListenter { position: Int, o: Any, v: View, layout: Int ->
when (layout) {
R.layout.item_node_pretend -> initPretend(position, v)
R.layout.item_node_dis -> initDis(position, v)
}
})
if (!TextUtils.isEmpty(oib.formData.effectiveTime)) {
val ctb = TypeParts.getCarTypeLong(this)//车辆类型
val bb = TypeParts.getBusType(this)//车长
val nb = TypeParts.getNpType(this)//货物大类-交通厅
val ab = TypeParts.getAlType(this)//货物大类-安联
vehicle_type.text = ctb.data.type.find { it.value == oib.formData.vehicleType }?.name
vehicle_length.text =
ctb.data.length.find { it.value == oib.formData.vehicleLength }?.name
businessType.text = bb.data.find { it.value == oib.formData.businessType }?.name
tvHwdlJt.text = nb.data.find { it.id == oib.formData.goodsBigCate }?.cateName
tvHwdlAl.text = ab.data.find { it.id == oib.formData.alctGoodsType }?.name
effectiveTime.text = oib.formData.effectiveTime
}
}
/**
* 初始化卸货
*
* @param position
* @param o
* @param v
* @param layout
*/
private fun initDis(position: Int, v: View) {
if (oib.putTableData.size == 0) {
return
}
val rlTopDis = v.findViewById<RelativeLayout>(R.id.rlTopDis)
tvNameDis = v.findViewById<TextView>(R.id.tvName)
tvPhoneDis = v.findViewById<TextView>(R.id.tvPhone)
tvAddressDis = v.findViewById<TextView>(R.id.tvAddress)
val tvAddDis = v.findViewById<TextView>(R.id.tvAddDis)
tvEndTimeDis = v.findViewById<TextView>(R.id.tvEndTime)
ryDis = v.findViewById<BaseRecyclerView>(R.id.ryDis)
ryDis.addItemDecoration(RecyclerViewDecoration(this, RecyclerViewDecoration.VERTICAL_LIST))
ryDis.createV(this,
ArrayList<OrderInputBean.PutTableDataDTO.GoodsDTO>(),
R.layout.item_cargo)
.setOnItemViewListener(
AdapterAll.onItemViewListenter { position1: Int, o1: Any?, v1: View ->
val tvHWName = v1.findViewById<TextView>(R.id.tvHWName)
val tvCount = v1.findViewById<TextView>(R.id.tvCount)
val tvDw = v1.findViewById<TextView>(R.id.tvDw)
val tvBzfs = v1.findViewById<TextView>(R.id.tvBzfs)
val tvDel = v1.findViewById<TextView>(R.id.tvDel)
// OrderInputBean.PutTableDataDTO.GoodsDTO osg1 = (OrderInputBean.PutTableDataDTO.GoodsDTO) o1;
val osg1: OrderInputBean.PutTableDataDTO.GoodsDTO =
oib.putTableData.get(0).getGoods().get(position1)
tvHWName.text = osg1.name
tvCount.text = osg1.num
tvDw.text = osg1.unit
tvBzfs.text = osg1.packName
v1.setOnClickListener { v2: View? ->
goodsType = 1
updatePosGoodsDis = position1
val `in` = Intent(this, GoodsDischargeActivity::class.java)
`in`.putExtra("goodData", gson.toJson(oib))
`in`.putExtra("choiceData", gson.toJson(oib.putTableData.get(0).goods.get(position1)))
startActivity(`in`)
}
tvDel.setOnClickListener { v22: View? ->
oib.putTableData.get(0).goods.remove(osg1)
ryDis.delItemV(position1)
}
})
val putTableDataDTO = oib.putTableData.get(0)
tvNameDis.text = putTableDataDTO.loadingName
tvPhoneDis.text = putTableDataDTO.loadingPhone
tvAddressDis.text = putTableDataDTO.detailAddress
tvEndTimeDis.text = putTableDataDTO.loadingDeadline
ryDis.notifyDatas(putTableDataDTO.getGoods())
rlTopDis.setOnClickListener { v12: View? ->
val `in` = Intent(this, AddressActivity::class.java)
`in`.putExtra("type", 1)
startActivity(`in`)
}
tvAddDis.setOnClickListener { V: View? ->
if (oib.getSendTableData().get(0).getGoods() != null && oib.getSendTableData().get(0)
.getGoods().size > 0
) {
goodsType = 1
val `in` = Intent(this, GoodsDischargeActivity::class.java)
`in`.putExtra("goodData", gson.toJson(oib))
startActivity(`in`)
} else {
Toast.makeText(this, "请先添加装货信息", Toast.LENGTH_LONG).show()
}
}
tvEndTimeDis.setOnClickListener(View.OnClickListener { V: View? ->
val ap = DatimePicker(this)
val wheelLayout = ap.wheelLayout
ap.setOnDatimePickedListener { year: Int, month: Int, day: Int, hour: Int, minute: Int, second: Int ->
val text =
year.toString() + "-" + getRead(month) + "-" + getRead(day) + " " + getRead(hour) + ":" + getRead(
minute)
oib.putTableData.get(0).setLoadingDeadline(text)
tvEndTimeDis.setText(text)
}
wheelLayout.setDateMode(DateMode.YEAR_MONTH_DAY)
wheelLayout.setTimeMode(TimeMode.HOUR_24_NO_SECOND)
wheelLayout.setRange(DatimeEntity.now(), DatimeEntity.yearOnFuture(10))
wheelLayout.setDateLabel("", "", "")
wheelLayout.setTimeLabel("", "", "")
ap.show()
})
}
/**
* 装货初始化
*
* @param position
* @param o
* @param v
* @param layout
*/
private fun initPretend(position: Int, v: View) {
if (oib.sendTableData.size == 0) {
return
}
tvName = v.findViewById<TextView>(R.id.tvName)
tvPhone = v.findViewById<TextView>(R.id.tvPhone)
tvAddress = v.findViewById<TextView>(R.id.tvAddress)
etMoney = v.findViewById<EditText>(R.id.etMoney)
tvStartTime = v.findViewById<TextView>(R.id.tvStartTime)
val tvAddPre = v.findViewById<TextView>(R.id.tvAddPre)
val rlTop = v.findViewById<RelativeLayout>(R.id.rlTop)
ryPretend = v.findViewById<BaseRecyclerView>(R.id.ryPretend)
val sendTableDataDTO = oib.sendTableData.get(0)
tvName.text = sendTableDataDTO.loadingName
tvPhone.text = sendTableDataDTO.loadingPhone
tvAddress.text = sendTableDataDTO.detailAddress
tvStartTime.text = sendTableDataDTO.loadingDeadline
// etMoney.setText(sendTableDataDTO.totalFreight)
rlTop.setOnClickListener { v12: View? ->
val `in` = Intent(this, AddressActivity::class.java)
`in`.putExtra("type", 0)
startActivity(`in`)
}
tvAddPre.setOnClickListener { V: View? ->
goodsType = 0
val `in` = Intent(this, GoodsActivity::class.java)
startActivity(`in`)
}
tvStartTime.setOnClickListener(View.OnClickListener { V: View? ->
val ap = DatimePicker(this)
val wheelLayout = ap.wheelLayout
ap.setOnDatimePickedListener { year: Int, month: Int, day: Int, hour: Int, minute: Int, second: Int ->
val text =
year.toString() + "-" + getRead(month) + "-" + getRead(day) + " " + getRead(hour) + ":" + getRead(
minute)
oib.sendTableData.get(0).setLoadingDeadline(text)
tvStartTime.setText(text)
}
wheelLayout.setDateMode(DateMode.YEAR_MONTH_DAY)
wheelLayout.setTimeMode(TimeMode.HOUR_24_NO_SECOND)
wheelLayout.setRange(DatimeEntity.now(), DatimeEntity.yearOnFuture(10))
wheelLayout.setDateLabel("", "", "")
wheelLayout.setTimeLabel("", "", "")
ap.show()
})
ryPretend.addItemDecoration(RecyclerViewDecoration(this,
RecyclerViewDecoration.VERTICAL_LIST))
ryPretend.createV(this, oib.sendTableData.get(0).goods, R.layout.item_cargo)
.setOnItemViewListener(AdapterAll.onItemViewListenter { position1: Int, o1: Any, v1: View ->
val tvHWName = v1.findViewById<TextView>(R.id.tvHWName)
val tvCount = v1.findViewById<TextView>(R.id.tvCount)
val tvDw = v1.findViewById<TextView>(R.id.tvDw)
val tvBzfs = v1.findViewById<TextView>(R.id.tvBzfs)
val tvDel = v1.findViewById<TextView>(R.id.tvDel)
if (oib.sendTableData.size > 0) {
val osg1 = o1 as OrderInputBean.SendTableDataDTO.GoodsDTO
tvHWName.text = osg1.name
tvCount.text = osg1.num
tvDw.text = osg1.unit
tvBzfs.text = osg1.packName
v1.setOnClickListener { v2: View? ->
goodsType = 0
updatePosGoods = position1
val `in` = Intent(this, GoodsActivity::class.java)
`in`.putExtra("goodData", Gson().toJson(osg1))
startActivity(`in`)
}
tvDel.setOnClickListener { v22: View? ->
if (oib.sendTableData.get(0).getGoods().size > 0) {
XPopup.Builder(this) // .isDestroyOnDismiss(true) //对于只使用一次的弹窗,推荐设置这个
.asConfirm("请确认", "删除装货货物,需重新添加卸货地址货物?",
"取消", "确认",
{
ryPretend.delItemV(position1)
oib.putTableData.get(0).goods = oib.putTableData.get(0).getGoods().filter { it.name!= osg1.name }
ryDis.delAllDatas()
ryDis.notifyDatas(oib.putTableData.get(0).goods)
// ryDis.notifyDatas(oib.putTableData.get(0).goods)
// oib.putTableData.get(0).getGoods().clear()
// ryDis.delAllDatas()
}, null, false, R.layout.alert_ok_cancel) //最后一个参数绑定已有布局
.show()
} else {
ryPretend.delItemV(position1)
}
}
}
})
}
private fun initListener() {
//车型
r3.setOnClickListener {
if (isLogin()) {
etMoney.clearFocus()
val ctb = TypeParts.getCarTypeLong(this)
val data: MutableList<OptionBaseBean?> = java.util.ArrayList()
for (typeDTO in ctb.data.type) {
data.add(OptionBaseBean(typeDTO.value, typeDTO.name))
}
val picker = OptionPicker(this)
picker.setBodyWidth(140)
picker.setOnOptionPickedListener { position: Int, item: Any ->
val obb = item as OptionBaseBean
vehicle_type.text = obb.name
oib.formData.vehicleType = obb.id
}
picker.setData(data)
picker.setDefaultPosition(2)
picker.show()
}
}
//车长
r31.setOnClickListener {
if (isLogin()) {
etMoney.clearFocus()
val ctb = TypeParts.getCarTypeLong(this)
val data: MutableList<OptionBaseBean?> = java.util.ArrayList()
for (lengthDTO in ctb.data.length) {
data.add(OptionBaseBean(lengthDTO.value, lengthDTO.name))
}
val picker = OptionPicker(this)
picker.setBodyWidth(140)
picker.setOnOptionPickedListener { position: Int, item: Any ->
val obb = item as OptionBaseBean
vehicle_length.text = obb.name
oib.formData.vehicleLength = obb.id
}
picker.setData(data)
picker.setDefaultPosition(2)
picker.show()
}
}
//业务类型
r4.setOnClickListener {
if (isLogin()) {
etMoney.clearFocus()
val btb = TypeParts.getBusType(this)
val data: MutableList<OptionBaseBean?> = java.util.ArrayList()
for (datum in btb.data) {
data.add(OptionBaseBean(datum.value, datum.name))
}
val picker = OptionPicker(this)
picker.setBodyWidth(140)
picker.setOnOptionPickedListener { position: Int, item: Any ->
val obb = item as OptionBaseBean
businessType.text = obb.name
oib.formData.businessType = obb.id
}
picker.setData(data)
picker.setDefaultPosition(2)
picker.show()
}
}
//货物大类(交通厅)
r7.setOnClickListener {
if (isLogin()) {
etMoney.clearFocus()
val al = TypeParts.getNpType(this)
val data: MutableList<OptionBaseBean?> = java.util.ArrayList()
for (datum in al.data) {
data.add(OptionBaseBean(datum.id, datum.cateName))
}
val picker = OptionPicker(this)
picker.setBodyWidth(140)
picker.setOnOptionPickedListener { position: Int, item: Any ->
val obb = item as OptionBaseBean
tvHwdlJt.text = obb.name
oib.formData.goodsBigCate = obb.id
}
picker.setData(data)
picker.setDefaultPosition(2)
picker.show()
}
}
//货物大类(安联)
r8.setOnClickListener {
if (isLogin()) {
etMoney.clearFocus()
val al = TypeParts.getAlType(this)
val data: MutableList<OptionBaseBean?> = java.util.ArrayList()
for (datum in al.data) {
data.add(OptionBaseBean(datum.id, datum.name))
}
val picker = OptionPicker(this)
picker.setBodyWidth(140)
picker.setOnOptionPickedListener { position: Int, item: Any ->
val obb = item as OptionBaseBean
tvHwdlAl.text = obb.name
oib.formData.alctGoodsType = obb.id
}
picker.setData(data)
picker.setDefaultPosition(14)
picker.show()
}
}
//订单有效期
r5.setOnClickListener {
if (isLogin()) {
etMoney.clearFocus()
val ap = DatimePicker(this)
val wheelLayout = ap.wheelLayout
ap.setOnDatimePickedListener { year: Int, month: Int, day: Int, hour: Int, minute: Int, second: Int ->
val text =
year.toString() + "-" + getRead(month) + "-" + getRead(day) + " " + getRead(
hour) + ":" + getRead(
minute)
effectiveTime.text = text
oib.formData.effectiveTime = text
}
wheelLayout.setDateMode(DateMode.YEAR_MONTH_DAY)
wheelLayout.setTimeMode(TimeMode.HOUR_24_NO_SECOND)
wheelLayout.setRange(DatimeEntity.now(), DatimeEntity.yearOnFuture(10))
wheelLayout.setDateLabel("", "", "")
wheelLayout.setTimeLabel("", "", "")
ap.show()
}
}
//分配车辆
etCar.setOnClickListener { V: View? ->
val intent = Intent(this, DisCarActivity::class.java)
intent.putExtra(AppConfig.STRING, etCar.text.toString())
startActivity(intent)
}
submit.setOnClickListener {
if (isLogin()) {
if (!TypeParts.isEntrust(this)) {
for (sendTableDatum in oib.sendTableData) {
var ub = UserParts.getUser(this)
if (ub != null) {
if (StringUtil.isNull(ub.getData().getCompanyName(), "") == "") {
sendTableDatum.businessName =
StringUtil.isNull(ub.getData().getRname(), "")
} else {
sendTableDatum.businessName = ub.getData().getCompanyName()
}
}
}
if (etMoney.text.toString().isEmpty()){
showToast("请输入运费信息")
return@setOnClickListener
}
if (oib.sendTableData[0].goods.size>0 &&oib.putTableData[0].goods.size>0 && !TextUtils.isEmpty(
oib.formData.shipperCarId)
) {
XPopup.Builder(this)
.isDestroyOnDismiss(true) //对于只使用一次的弹窗,推荐设置这个
.asConfirm("请确认", "是否确定提交此订单?",
"取消", "确认",
{
oib.isSubmit = 1
oib.formData.isSubmit = 1
oib.sendTableData[0].totalPrice = etMoney.text.toString().toDouble()
Log.e("货源信息", Gson().toJson(oib))
DataManager.getInstance().againOrder(oib)
.compose(DataManager.setThread())
.subscribe(BaseObserver(mContext,object : RxHttpCallBack<Any>(){
override fun onSuccess(t: CommonResponseBean<Any>?) {
super.onSuccess(t)
showToast("订单创建成功")
}
}))
}, null, false, R.layout.alert_ok_cancel) //最后一个参数绑定已有布局
.show()
} else {
Toast.makeText(this, "提交订单信息不完整", Toast.LENGTH_LONG).show()
}
} else {
Toast.makeText(this, "此账户不能进行发货操作", Toast.LENGTH_LONG).show()
}
} else {
Toast.makeText(this, "请先登录", Toast.LENGTH_LONG).show()
}
}
}
//选择分配车辆回调
@Subscribe
fun disCarEvent(baseEvent: BaseEvent<*>) {
if (baseEvent.data is CarBean) {
val data = baseEvent.data as CarBean
etCar.text = data.carNum + " " + data.driverPhone
oib.formData.shipperCarId = data.carId.toString() + ""
oib.formData.shipperDriverId = data.driverId.toString() + ""
}
}
@Subscribe
fun addressResult(event: AddressEvent) {
Log.e("返回结果", event.message + "--")
var ad = Gson().fromJson(event.message,
AddressListBean.DataDTO.RecordsDTO::class.java)
val list: MutableList<Int> = java.util.ArrayList()
list.add(ad.getProvince())
list.add(ad.getCity())
list.add(ad.getArea())
if (event.type == 0) {
oib.sendTableData.get(0).setDetailAddress(ad.getAddressDetail())
oib.sendTableData.get(0).setLoadingName(ad.getContactPerson())
oib.sendTableData.get(0).setLoadingPhone(ad.getContactNumber())
oib.sendTableData.get(0).setCompanyCode(ad.getCompanyCode())
oib.sendTableData.get(0).setCompanyName(ad.getCompanyName())
oib.sendTableData.get(0).setLoadingAddress(list)
tvName.setText(ad.getContactPerson())
tvPhone.setText(ad.getContactNumber())
tvAddress.setText(ad.getAddressDetail())
// GetObjectName.ZIModel(address_box,os,con);
} else {
oib.putTableData.get(0).setDetailAddress(ad.getAddressDetail())
oib.putTableData.get(0).setLoadingName(ad.getContactPerson())
oib.putTableData.get(0).setLoadingPhone(ad.getContactNumber())
oib.putTableData.get(0).setCompanyCode(ad.getCompanyCode())
oib.putTableData.get(0).setCompanyName(ad.getCompanyName())
oib.putTableData.get(0).setLoadingAddress(list)
tvNameDis.setText(ad.getContactPerson())
tvPhoneDis.setText(ad.getContactNumber())
tvAddressDis.setText(ad.getAddressDetail())
// GetObjectName.ZIModel(address_box,op,con);
}
}
@Subscribe
fun goodsResult(event: GoodsEvent) {
Log.e("返回结果", event.message + "--")
if (goodsType == 0) {
val osg1 = Gson().fromJson(event.message,
SendTableDataDTO.GoodsDTO::class.java)
if (-1 != updatePosGoods) {
oib.sendTableData.get(0).goods.set(updatePosGoods, osg1)
// os.getGoods().set(updatePosGoods, osg1)
ryPretend.updateItemV(updatePosGoods, osg1)
//删除卸货货物信息
// oib.putTableData.get(0).getGoods().clear()
// ryDis.delAllDatas()
updatePosGoods = -1
} else {
// os.getGoods().add(osg1);
ryPretend.addItemV(osg1)
// 同步卸货货物
val goodsDTO = Gson().fromJson(event.message,
PutTableDataDTO.GoodsDTO::class.java)
// op.getGoods().add(goodsDTO)
oib.putTableData.get(0).getGoods().add(goodsDTO)
ryDis.addItemV(goodsDTO)
}
} else {
val osg2 = Gson().fromJson(event.message,
PutTableDataDTO.GoodsDTO::class.java)
if (-1 != updatePosGoodsDis) {
oib.putTableData.get(0).getGoods().set(updatePosGoodsDis, osg2)
ryDis.updateItemV(updatePosGoodsDis, osg2)
updatePosGoodsDis = -1
} else {
oib.putTableData.get(0).getGoods().add(osg2)
ryDis.addItemV(osg2)
}
}
}
override fun onDestroy() {
super.onDestroy()
EventBus.getDefault().unregister(this)
}
fun isLogin(): Boolean {
return if (UiAuxiliary.isLogin(this)) {
true
} else {
val `in` = Intent(this, LoginActivity::class.java)
startActivity(`in`)
false
}
}
fun getRead(num: Int): String? {
return if (num < 10) {
"0$num"
} else num.toString() + ""
}
}

View File

@ -0,0 +1,446 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/activity_invoice"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/bg_theme"
android:orientation="vertical">
<include layout="@layout/common_toolbar" />
<!-- <include layout="@layout/assembly_title_block" />-->
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:focusable="true"
android:focusableInTouchMode="true"
>
<com.oneclouds.cargo.util.view.BaseRecyclerView
android:id="@+id/rv"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginLeft="@dimen/dp_10"
android:layout_marginRight="@dimen/dp_10"
android:layout_weight="1"
android:overScrollMode="never"
></com.oneclouds.cargo.util.view.BaseRecyclerView>
<LinearLayout
android:layout_marginLeft="@dimen/dp_10"
android:layout_marginRight="@dimen/dp_10"
android:layout_marginTop="@dimen/dp_9"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:background="@drawable/shape_w_bg8"
android:paddingLeft="@dimen/dp_12"
android:paddingRight="@dimen/dp_12"
android:paddingTop="@dimen/dp_8"
android:paddingBottom="@dimen/dp_12"
android:elevation="@dimen/dp_1">
<RelativeLayout
android:id="@+id/r2"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_49"
android:gravity="center_vertical"
>
<ImageView
android:layout_marginTop="@dimen/dp_12"
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_vehicletype" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="@dimen/dp_24"
android:text="熟车"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14" />
<LinearLayout
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:orientation="horizontal">
<TextView
android:id="@+id/etCar"
android:layout_width="@dimen/dp_160"
android:layout_height="match_parent"
android:hint="选择车牌/手机号搜索"
android:gravity="right|center_vertical"
android:maxLines="1"
android:singleLine="true"
android:textColorHint="#ffc7c7c7"
android:textSize="@dimen/sp_14"
android:layout_marginRight="@dimen/dp_14"
android:background="@null"
/>
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:src="@mipmap/chevron2"
android:scaleType="fitXY"
android:background="@null"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r3"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12">
<ImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_vehicletype" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="@dimen/dp_24"
android:text="车型"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14" />
<LinearLayout
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_marginRight="@dimen/dp_12"
android:id="@+id/vehicle_type"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
/>
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:src="@mipmap/chevron2"
android:scaleType="fitXY"
android:background="@null"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r31"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12">
<ImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_vehicletype"/>
<TextView
android:layout_marginLeft="@dimen/dp_24"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="车长"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
android:layout_centerVertical="true"
/>
<LinearLayout
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_marginRight="@dimen/dp_12"
android:id="@+id/vehicle_length"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
/>
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:src="@mipmap/chevron2"
android:scaleType="fitXY"
android:background="@null"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r4"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12">
<ImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_businesstype"/>
<TextView
android:layout_marginLeft="@dimen/dp_24"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="业务类型"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
android:layout_centerVertical="true"
/>
<LinearLayout
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_marginRight="@dimen/dp_12"
android:id="@+id/businessType"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
/>
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:src="@mipmap/chevron2"
android:scaleType="fitXY"
android:background="@null"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r7"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12">
<ImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_businesstype" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="@dimen/dp_24"
android:text="货物大类(交通厅)"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:orientation="horizontal">
<TextView
android:id="@+id/tvHwdlJt"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="@dimen/dp_12"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14" />
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:layout_gravity="center"
android:background="@null"
android:scaleType="fitXY"
android:src="@mipmap/chevron2" />
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r8"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12">
<ImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_businesstype"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="@dimen/dp_24"
android:text="货物大类(安联)"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14" />
<LinearLayout
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_marginRight="@dimen/dp_12"
android:id="@+id/tvHwdlAl"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
/>
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:src="@mipmap/chevron2"
android:scaleType="fitXY"
android:background="@null"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r5"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12">
<ImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:src="@mipmap/icon_home_time"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="@dimen/dp_24"
android:text="订单有效期"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14" />
<LinearLayout
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:layout_marginRight="@dimen/dp_12"
android:id="@+id/effectiveTime"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="#ff999999"
android:textSize="@dimen/sp_14"
/>
<ImageButton
android:layout_width="@dimen/dp_7"
android:layout_height="@dimen/dp_12"
android:src="@mipmap/chevron2"
android:scaleType="fitXY"
android:background="@null"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"/>
<RelativeLayout
android:id="@+id/r6"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12"
android:visibility="gone">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="是否购买货物险"
android:textColor="#666666"
android:textSize="@dimen/sp_14"
android:layout_centerVertical="true"
/>
<ImageButton
android:layout_alignParentRight="true"
android:id="@+id/isGoods"
android:layout_width="@dimen/dp_18"
android:layout_height="@dimen/dp_18"
android:src="@mipmap/icon_no"
android:scaleType="fitXY"
android:background="@null"
android:layout_centerVertical="true"
/>
</RelativeLayout>
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#8AA5E1"
android:alpha="0.5"
android:visibility="gone"/>
<EditText
android:id="@+id/requirement"
android:paddingTop="@dimen/dp_8"
android:paddingBottom="@dimen/dp_8"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="left|top"
android:minHeight="@dimen/dp_60"
android:hint="添加备注信息(选填)"
android:textColorHint="#ffc7c7c7"
android:textSize="@dimen/sp_14"
android:background="@null"
/>
</LinearLayout>
<Button
android:id="@+id/submit"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_42"
android:layout_marginLeft="@dimen/dp_10"
android:layout_marginTop="@dimen/dp_8"
android:layout_marginRight="@dimen/dp_10"
android:layout_marginBottom="@dimen/dp_12"
android:background="@drawable/bg_btn"
android:text="确定"
android:textColor="#ffffffff"
android:textSize="@dimen/sp_14" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</LinearLayout>

View File

@ -76,6 +76,7 @@
android:layout_gravity="center"
/>
</LinearLayout>
<LinearLayout
android:paddingTop="@dimen/dp_12"
android:paddingBottom="@dimen/dp_12"
@ -84,7 +85,7 @@
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical"
android:visibility="gone">
>
<ImageView
android:id="@+id/news"
android:layout_width="@dimen/dp_26"
@ -99,7 +100,7 @@
android:layout_marginTop="@dimen/dp_4"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="消息"
android:text="运单"
android:textColor="#ffc9c9c9"
android:textSize="@dimen/sp_12"
android:layout_gravity="center"

View File

@ -25,18 +25,18 @@
android:layout_height="wrap_content"/>
</com.scwang.smart.refresh.layout.SmartRefreshLayout>
</LinearLayout>
<Button
android:id="@+id/submit"
android:layout_marginBottom="@dimen/dp_34"
android:layout_alignParentBottom="true"
android:layout_marginLeft="@dimen/dp_20"
android:layout_marginRight="@dimen/dp_20"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_44"
android:background="@drawable/bg_btn"
android:text="提交开票申请"
android:textColor="#ffffffff"
android:textSize="@dimen/sp_16"
android:visibility="gone"
/>
<!-- <Button-->
<!-- android:id="@+id/submit"-->
<!-- android:layout_marginBottom="@dimen/dp_34"-->
<!-- android:layout_alignParentBottom="true"-->
<!-- android:layout_marginLeft="@dimen/dp_20"-->
<!-- android:layout_marginRight="@dimen/dp_20"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="@dimen/dp_44"-->
<!-- android:background="@drawable/bg_btn"-->
<!-- android:text="提交开票申请"-->
<!-- android:textColor="#ffffffff"-->
<!-- android:textSize="@dimen/sp_16"-->
<!-- android:visibility="gone"-->
<!-- />-->
</RelativeLayout>

View File

@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout 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:id="@+id/activity_order_list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/bg_theme"
android:paddingTop="@dimen/dp_49"
android:orientation="vertical">
<include
layout="@layout/order_list_top" />
<com.xuexiang.xui.widget.tabbar.TabSegment
android:id="@+id/tabSegment"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_40"
android:textSize="@dimen/sp_14"
app:ts_normal_color="#ff999999"
app:ts_selected_color="@color/color_theme"
tools:ignore="MissingConstraints" />
<androidx.viewpager.widget.ViewPager
android:id="@+id/vp"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</LinearLayout>

View File

@ -1,91 +1,101 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.cardview.widget.CardView
xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.cardview.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/order_item"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/order_item"
android:layout_marginLeft="@dimen/dp_20"
android:layout_marginRight="@dimen/dp_20"
android:layout_marginTop="@dimen/dp_10"
android:layout_marginRight="@dimen/dp_20"
android:layout_marginBottom="@dimen/dp_1"
app:cardCornerRadius="@dimen/dp_8">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<RelativeLayout
android:layout_marginTop="@dimen/dp_8"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_8">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true">
<View
android:layout_width="@dimen/dp_3"
android:layout_height="@dimen/dp_12"
android:background="@color/color_theme"
android:layout_gravity="center"/>
android:layout_gravity="center"
android:background="@color/color_theme" />
<TextView
android:layout_marginLeft="@dimen/dp_7"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_7"
android:text="货源号:"
android:textColor="#ff333333"
android:textSize="@dimen/sp_13"
/>
android:textSize="@dimen/sp_13" />
<TextView
android:id="@+id/orderNum"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0999023488"
android:textColor="#ff333333"
android:textSize="@dimen/sp_13"
/>
android:textSize="@dimen/sp_13" />
</LinearLayout>
<LinearLayout
android:layout_marginRight="@dimen/dp_10"
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_marginRight="@dimen/dp_10">
<ImageButton
android:id="@+id/xuan"
android:layout_width="@dimen/dp_16"
android:layout_height="@dimen/dp_16"
android:src="@mipmap/no_xuan"
android:background="@null"
android:scaleType="fitXY"
android:background="@null"/>
android:src="@mipmap/no_xuan" />
</LinearLayout>
</RelativeLayout>
<View
android:layout_marginTop="@dimen/dp_5"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#EFEFEF"/>
android:layout_marginTop="@dimen/dp_5"
android:background="#EFEFEF" />
<RelativeLayout
android:layout_marginTop="@dimen/dp_11"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_11">
<LinearLayout
android:layout_marginLeft="@dimen/dp_10"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_10"
android:orientation="vertical">
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal">
<ImageView
android:src="@mipmap/icon_loading"
android:layout_width="@dimen/dp_16"
android:layout_height="@dimen/dp_16"
android:layout_gravity="center"
android:scaleType="fitXY"
android:layout_gravity="center"/>
android:src="@mipmap/icon_loading" />
<TextView
android:id="@+id/loadingAddress"
@ -99,17 +109,19 @@
android:textColor="#ff333333"
android:textSize="@dimen/sp_13" />
</LinearLayout>
<LinearLayout
android:layout_marginTop="@dimen/dp_7"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_7"
android:orientation="horizontal">
<ImageView
android:src="@mipmap/icon_discharge"
android:layout_width="@dimen/dp_16"
android:layout_height="@dimen/dp_16"
android:layout_gravity="center"
android:scaleType="fitXY"
android:layout_gravity="center"/>
android:src="@mipmap/icon_discharge" />
<TextView
android:id="@+id/receiverAddress"
@ -124,19 +136,22 @@
android:textSize="@dimen/sp_13" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_marginRight="@dimen/dp_10"
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_centerVertical="true">
android:layout_alignParentRight="true"
android:layout_centerVertical="true"
android:layout_marginRight="@dimen/dp_10"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="¥"
android:textColor="#fff65151"
android:textSize="@dimen/sp_19" />
<TextView
android:id="@+id/totalFreight"
android:layout_width="wrap_content"
@ -146,51 +161,79 @@
android:textSize="@dimen/sp_19" />
</LinearLayout>
</RelativeLayout>
<LinearLayout
android:layout_marginTop="@dimen/dp_7"
android:layout_marginLeft="@dimen/dp_10"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginBottom="@dimen/dp_7">
android:layout_marginLeft="@dimen/dp_10"
android:layout_marginTop="@dimen/dp_7"
android:layout_marginBottom="@dimen/dp_7"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="状态:"
android:textColor="#999999"
android:textSize="@dimen/sp_13" />
<TextView
android:id="@+id/statusOver"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="审核中"
android:textColor="@color/color_theme"
android:textSize="@dimen/sp_13"
/>
android:textSize="@dimen/sp_13" />
</LinearLayout>
<View
android:layout_marginTop="@dimen/dp_5"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:background="#EFEFEF"/>
<Button
android:id="@+id/btn"
android:layout_marginTop="@dimen/dp_5"
android:background="#EFEFEF" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="@dimen/dp_36"
android:text="撤销"
android:textColor="#ffd95959"
android:textSize="@dimen/sp_16"
android:gravity="center"
android:background="@null"
android:elevation="@dimen/dp_3"/>
android:layout_height="wrap_content"
android:orientation="horizontal">
<Button
android:layout_weight="1"
android:id="@+id/btn"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_36"
android:background="@null"
android:elevation="@dimen/dp_3"
android:gravity="center"
android:text="撤销"
android:textColor="#ffd95959"
android:textSize="@dimen/sp_16" />
<View
android:layout_width="@dimen/dp_1"
android:layout_height="@dimen/dp_36"
android:background="#EFEFEF" />
<Button
android:layout_weight="1"
android:id="@+id/btnAgain"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_36"
android:background="@null"
android:elevation="@dimen/dp_3"
android:gravity="center"
android:text="再来一单"
android:textColor="#4CAF50"
android:textSize="@dimen/sp_16" />
</LinearLayout>
</LinearLayout>
<ImageView
android:id="@+id/state_img"
android:layout_marginTop="@dimen/dp_100"
android:layout_alignParentRight="true"
android:layout_width="@dimen/dp_70"
android:layout_height="@dimen/dp_65"
android:layout_alignParentRight="true"
android:layout_marginTop="@dimen/dp_100"
android:src="@mipmap/invoicing"
android:visibility="gone"/>
android:visibility="gone" />
</RelativeLayout>
</androidx.cardview.widget.CardView>

View File

@ -8,7 +8,7 @@
<color name="colorBlack3">#333333</color>
<color name="colorBlack6">#666666</color>
<color name="colorWebViewIndicator">#FE0606</color>
<color name="mine_top_bg">#ff007aff</color>
<color name="mine_top_bg">#8AA5E1</color>
<color name="text_bg_blue">#3C6FC6</color>
<color name="mask_color">#88888888</color>