Compare commits
24 Commits
f61302a1f6
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| 6c4e97945b | |||
| a663609eeb | |||
| 74e9f5a827 | |||
| d6f72186a3 | |||
| b2ea79512c | |||
| 8b666364ae | |||
| aac2c860c6 | |||
| c2b5e74156 | |||
| 093314d601 | |||
| 9b089d51b1 | |||
| 8ced5be7a9 | |||
| da50aa9794 | |||
| 47cef6ee59 | |||
| baaa9c5615 | |||
| edb1f576b7 | |||
| 8b0043d2f5 | |||
| 5ccb971c61 | |||
| 6278d9738d | |||
| 0b25e9c68c | |||
| a4095d6e72 | |||
| d31e78ff49 | |||
| 43b1b6f44f | |||
| f4d5904003 | |||
| 4b3c31252b |
@@ -82,7 +82,25 @@
|
||||
"Read(//private/var/folders/qz/qk20ny650h1fhmxrx46gdfhr0000gn/T/images/**)",
|
||||
"mcp__apifox__read_project_oas_2s2uhx",
|
||||
"mcp__apifox__read_project_oas_ref_resources_2s2uhx",
|
||||
"mcp__apifox__refresh_project_oas_2s2uhx"
|
||||
"mcp__apifox__refresh_project_oas_2s2uhx",
|
||||
"Bash(find /Users/kid/Development/Fusion/Projects/aerologic-app -path \"*/build\" -prune -o -type f \\\\\\( -name \"*manifest*\" -o -name \"*bean*\" \\\\\\) | grep -i \"gjj\\\\|tally\" | grep -E \"\\\\.\\(kt\\)$\" | sort)",
|
||||
"mcp__apifox__read_project_oas_9otrai",
|
||||
"mcp__apifox__read_project_oas_ref_resources_9otrai",
|
||||
"Bash(cd:*)",
|
||||
"mcp__apifox__read_project_oas_tua249",
|
||||
"mcp__apifox__read_project_oas_ref_resources_tua249",
|
||||
"mcp__apifox__read_project_oas_heib77",
|
||||
"mcp__apifox__read_project_oas_ref_resources_heib77",
|
||||
"Bash(export JAVA_HOME=\"/Applications/Android Studio.app/Contents/jbr/Contents/Home\")",
|
||||
"Bash(export PATH=\"$JAVA_HOME/bin:$PATH\")",
|
||||
"Read(//Library/Java/JavaVirtualMachines/**)",
|
||||
"Read(//usr/local/**)",
|
||||
"Read(//opt/homebrew/opt/**)",
|
||||
"Bash(/Users/kid/.vfox/sdks/java/bin/java -version 2>&1)",
|
||||
"Bash(export JAVA_HOME=/Users/kid/.vfox/sdks/java)",
|
||||
"mcp__apifox__read_project_oas_kcl8s7",
|
||||
"mcp__apifox__refresh_project_oas_kcl8s7",
|
||||
"mcp__apifox__read_project_oas_ref_resources_kcl8s7"
|
||||
],
|
||||
"deny": [],
|
||||
"ask": []
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
[tools]
|
||||
java = "17.0.17+10-amzn"
|
||||
java = "17+35-amzn"
|
||||
|
||||
@@ -1 +1 @@
|
||||
/Users/kid/.version-fox/cache/java/v-17.0.17+10-amzn/java-17.0.17+10-amzn
|
||||
/Users/kid/.vfox/cache/java/v-17+35-amzn/java-17+35-amzn
|
||||
@@ -124,11 +124,12 @@ class XxxViewModel : BasePageViewModel() {
|
||||
<LinearLayout orientation="vertical">
|
||||
<include layout="@layout/title_tool_bar" />
|
||||
|
||||
<!-- 搜索区:PadSearchLayout 横排 -->
|
||||
<!-- 搜索区:PadSearchLayout 横排 + 操作按钮(如有) -->
|
||||
<LinearLayout orientation="horizontal">
|
||||
<PadSearchLayout type="@{SearchLayoutType.DATE}" value="@={viewModel.flightDate}" />
|
||||
<PadSearchLayout type="@{SearchLayoutType.INPUT}" value="@={viewModel.flightNo}" />
|
||||
<ImageView style="@style/iv_search_action" android:onClick="@{()-> viewModel.searchClick()}" />
|
||||
<!-- 如需新增/删除按钮,尺寸规范见「开发原则」工具栏图标尺寸规范 -->
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 分页列表 -->
|
||||
@@ -842,6 +843,7 @@ companion object {
|
||||
- 标题栏统一用 `title_tool_bar` — 禁止手动编写 Toolbar
|
||||
- 优先使用 PadDataLayoutNew 和 PadSearchLayout 组件
|
||||
- 在每个页面布局时,如有截图,务必尽可能还原图片上的页面设计,而不是推测假想。如有困难一律要询问,禁止自己想象
|
||||
- 工具栏图标尺寸规范: `img_search` 36dp + padding 2dp;`img_add` 40dp 无 padding(使用 `drawable/img_add.xml` 矢量图,`drawable-xhdpi/img_add.png` 已废弃删除)
|
||||
- 常用资源: `bg_white_radius_8`、`colorPrimary`、`text_normal`、`text_gray`、`color_bottom_layout`
|
||||
|
||||
### 环境配置
|
||||
|
||||
@@ -460,6 +460,12 @@
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpTallyDetailsActivity"
|
||||
android:configChanges="orientation|keyboardHidden"
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<!-- 国际进港-仓库 -->
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpStorageUseActivity"
|
||||
@@ -481,6 +487,13 @@
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<!-- 国际进港-费用修改 -->
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpPickUpChargeEditActivity"
|
||||
android:configChanges="orientation|keyboardHidden"
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<!-- 国际进港-提取出库 -->
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpPickUpDLVActivity"
|
||||
@@ -495,6 +508,20 @@
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<!-- 国际进港-查询详情 -->
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpQueryDetailsActivity"
|
||||
android:configChanges="orientation|keyboardHidden"
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<!-- 国际进港-运单修改 -->
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpQueryEditActivity"
|
||||
android:configChanges="orientation|keyboardHidden"
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<!-- 国际进港-事故签证 -->
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpAccidentVisaActivity"
|
||||
@@ -502,6 +529,12 @@
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<activity
|
||||
android:name="com.lukouguoji.gjj.activity.IntImpAccidentVisaEditActivity"
|
||||
android:configChanges="orientation|keyboardHidden"
|
||||
android:exported="false"
|
||||
android:screenOrientation="userLandscape" />
|
||||
|
||||
<service android:name="com.huitao.printer.service.PrinterService" />
|
||||
<service android:name="com.lukouguoji.gnc.bluetooth.service.AncillaryService" />
|
||||
<service android:name="com.lukouguoji.gnc.bluetooth.service.MyService" />
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
value="@={viewModel.status}"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="0.33" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
hint='@{"选择所属航司"}'
|
||||
@@ -41,7 +41,7 @@
|
||||
value="@={viewModel.uldSuffix}"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="0.33" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
hint='@{"请输入ULD编号"}'
|
||||
@@ -51,7 +51,7 @@
|
||||
value="@={viewModel.uldNo}"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="0.33" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
@@ -69,11 +69,10 @@
|
||||
android:src="@drawable/img_search" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.onAddClick()}"
|
||||
android:padding="4dp"
|
||||
android:src="@drawable/img_add" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -6,7 +6,17 @@
|
||||
# http://www.gradle.org/docs/current/userguide/build_environment.html
|
||||
# Specifies the JVM arguments used for the daemon process.
|
||||
# The setting is particularly useful for tweaking memory settings.
|
||||
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
|
||||
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8 \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.jvm=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED \
|
||||
--add-opens=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED
|
||||
kapt.use.worker.api=false
|
||||
kapt.include.compile.classpath=false
|
||||
# When configured, Gradle will run in incubating parallel mode.
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.lukouguoji.module_base.bean
|
||||
|
||||
class GjAccidentVisaEditBean {
|
||||
var id: Long = 0
|
||||
var fdate: String = "" // 航班日期
|
||||
var fno: String = "" // 航班号
|
||||
var dep: String = "" // 始发站
|
||||
var dest: String = "" // 目的站
|
||||
var wbNo: String = "" // 运单号
|
||||
var dpc: String = "" // 不正常件数
|
||||
var pc: String = "" // 运单总件数
|
||||
var weight: String = "" // 运单总重量
|
||||
var reweight: String = "" // 复称重量
|
||||
var goods: String = "" // 品名
|
||||
var opacking: String = "" // 外包装
|
||||
var damage: String = "" // 包装破损情况
|
||||
var condition: String = "" // 内容物情况
|
||||
var problem: String = "" // 不正常类型
|
||||
var seachDate: String = "" // 发现时间
|
||||
var photo: String = "" // 图片是否留底
|
||||
var remarks: String = "" // 备注
|
||||
var pic: String = "" // 缩略图
|
||||
var originalPic: String = "" // 原图
|
||||
var picNumber: String = "" // 图片数量
|
||||
var idFlag: String = "1" // 国际标志(固定为1=国际)
|
||||
}
|
||||
@@ -50,7 +50,11 @@ class GjjWarehouse(
|
||||
var volume: String? = "",
|
||||
var wbNo: String? = "",
|
||||
var weight: String? = "",
|
||||
var whid: String? = ""
|
||||
var whid: String? = "",
|
||||
var splitFlag: String? = "",
|
||||
var inDate: String? = "",
|
||||
var clearNormal: String? = "",
|
||||
var range: String? = ""
|
||||
) {
|
||||
|
||||
fun getWaybillCode() = "${prefix}${no}"
|
||||
|
||||
@@ -47,10 +47,14 @@ data class GjjImportManifest(
|
||||
var dgrContactMame: String = "",
|
||||
// 危险品收货人通讯方式
|
||||
var dgrContactNumber: String = "",
|
||||
// 航班日期
|
||||
var fdate: String = "",
|
||||
// 航班起始站
|
||||
var fdep: String = "",
|
||||
// 航班目的站
|
||||
var fdest: String = "",
|
||||
// 航班号
|
||||
var fno: String = "",
|
||||
// 航班id
|
||||
var fid: Long = 0,
|
||||
// 运费支付方式
|
||||
@@ -114,6 +118,15 @@ data class GjjImportManifest(
|
||||
// 重量
|
||||
var weight: Double = 0.0
|
||||
) : Serializable {
|
||||
// 获取航班信息(日期去横杠/航班号)
|
||||
fun getFlightSplit(): String {
|
||||
if (fdate != "" && fno != "") {
|
||||
val (year, mon, day) = fdate.split("-")
|
||||
return "${year}${mon}${day}/${fno}"
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
// ========== UI扩展字段 ==========
|
||||
// 选中状态
|
||||
@Transient
|
||||
|
||||
@@ -74,7 +74,27 @@ data class GjjImportTally(
|
||||
// 体积(m³)
|
||||
var volume: Double = 0.0,
|
||||
// 重量(kg)
|
||||
var weight: Double = 0.0
|
||||
var weight: Double = 0.0,
|
||||
// 品名(中文)
|
||||
var goodsCn: String = "",
|
||||
// 品名(英文)
|
||||
var goodsEn: String = "",
|
||||
// 放行模式(代码)
|
||||
var relMode: String = "",
|
||||
// 放行模式(名称)
|
||||
var releaseMode: String = "",
|
||||
// 放行时间(perDate)
|
||||
var perDate: String = "",
|
||||
// 放行时间
|
||||
var releaseTime: String = "",
|
||||
// 指令类型(comType)
|
||||
var comType: String = "",
|
||||
// 指令类型
|
||||
var instructionType: String = "",
|
||||
// 放行备注
|
||||
var relRemark: String = "",
|
||||
// 备注
|
||||
var remark: String = ""
|
||||
) : Serializable {
|
||||
// 选中状态(用于多选功能)- 不参与序列化
|
||||
@Transient
|
||||
@@ -85,7 +105,24 @@ data class GjjImportTally(
|
||||
get() = checked.get()
|
||||
set(value) = checked.set(value)
|
||||
|
||||
// 展开/折叠状态 - 不参与序列化
|
||||
@Transient
|
||||
val showMore: ObservableBoolean = ObservableBoolean(false)
|
||||
|
||||
// 已加载的分单数据 - 不参与序列化
|
||||
@Transient
|
||||
var haWbList: MutableList<GjjImportTally>? = null
|
||||
|
||||
// 获取完整运单号
|
||||
fun getWaybillNo() = "$prefix$no"
|
||||
|
||||
// 获取航班信息(日期去横杠/航班号)
|
||||
fun getFlightSplit(): String {
|
||||
if (fdate != "" && fno != "") {
|
||||
val (year, mon, day) = fdate.split("-")
|
||||
return "${year}${mon}${day}/${fno}"
|
||||
}
|
||||
return ""
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
package com.lukouguoji.module_base.bean
|
||||
|
||||
import java.io.Serializable
|
||||
|
||||
/**
|
||||
* 国际进港-库位使用记录Bean
|
||||
* 对应接口: /IntImpSearch/detail 返回的 storageUseList 项
|
||||
*/
|
||||
data class GjjStorageUse(
|
||||
var id: Long? = null, // 主键
|
||||
var maWbId: Long? = null, // 运单id
|
||||
var prefix: String? = null, // 运单前缀
|
||||
var no: String? = null, // 运单号
|
||||
var location: String? = null, // 库位号
|
||||
var locationId: Long? = null, // 库位id
|
||||
var inDate: String? = null, // 入库时间
|
||||
var inOpId: String? = null, // 入库人ID
|
||||
var inOpName: String? = null, // 入库人姓名
|
||||
var outDate: String? = null, // 出库时间
|
||||
var outOpId: String? = null, // 出库人ID
|
||||
var outOpName: String? = null, // 出库人姓名
|
||||
var cargoStatus: String? = null // 货物状态
|
||||
) : Serializable
|
||||
@@ -38,6 +38,8 @@ class IntImpPickUpDLVBean : Serializable {
|
||||
var efrCharge: Double = 0.0 // 冷藏费
|
||||
var svlCharge: Double = 0.0 // 铲车费
|
||||
var tallyCharge: Double = 0.0 // 理货费
|
||||
var pipFee: Double = 0.0 // 精密仪器处理费
|
||||
var lapFee: Double = 0.0 // 活体动物处理费
|
||||
var chargeId: String = "" // 收费员
|
||||
var chargeName: String = "" // 收费员名称
|
||||
var dlvId: String = ""
|
||||
@@ -54,6 +56,18 @@ class IntImpPickUpDLVBean : Serializable {
|
||||
var awbPc: Long = 0
|
||||
|
||||
// ========== UI扩展字段 ==========
|
||||
/**
|
||||
* 航班信息展示:优先使用 flight 字段,否则用 fdate(去杠)/fno 拼接
|
||||
* 格式示例:20240204/MU2023
|
||||
*/
|
||||
val flightInfo: String
|
||||
get() {
|
||||
if (!flight.isNullOrEmpty()) return flight
|
||||
val dateStr = fdate?.replace("-", "")?.take(8) ?: ""
|
||||
val noStr = fno ?: ""
|
||||
return if (dateStr.isNotEmpty() || noStr.isNotEmpty()) "$dateStr/$noStr" else ""
|
||||
}
|
||||
|
||||
val checked: ObservableBoolean = ObservableBoolean(false)
|
||||
|
||||
var isSelected: Boolean
|
||||
|
||||
@@ -5,28 +5,35 @@ import java.io.Serializable
|
||||
|
||||
/**
|
||||
* 国际进港提取记录-列表数据Bean
|
||||
* 对应API: IntImpPickUpRecord/pageQuery
|
||||
* 对应API: IntImpPickup/pageQuery
|
||||
*/
|
||||
class IntImpPickUpRecordBean : Serializable {
|
||||
var id: Long = 0 // 主键ID
|
||||
var wbNo: String = "" // 运单号
|
||||
var no: String = "" // 主单号
|
||||
var prefix: String = "" // 前缀
|
||||
var hno: String = "" // 分单号
|
||||
var serialNo: String = "" // 序号
|
||||
var pc: Int = 0 // 件数
|
||||
var weight: Double = 0.0 // 重量
|
||||
var checkWeight: Double = 0.0 // 计重重量
|
||||
var cashWeight: Double = 0.0 // 计费重量
|
||||
var agentCode: String = "" // 代理人
|
||||
var spCode: String = "" // 特码
|
||||
var serviceFee: Double = 0.0 // 服务费
|
||||
var storageFee: Double = 0.0 // 仓储费
|
||||
var totalAmount: Double = 0.0 // 总金额
|
||||
var pickUpTime: String = "" // 提取时间
|
||||
var pickUpNo: String = "" // 提货编号
|
||||
var infoFee: Double = 0.0 // 信息费
|
||||
var drawFee: Double = 0.0 // 抽单费
|
||||
var coldFee: Double = 0.0 // 冷藏费
|
||||
var forkliftFee: Double = 0.0 // 铲车费
|
||||
var tallyFee: Double = 0.0 // 理货费
|
||||
var operator: String = "" // 办理人
|
||||
var outTime: String = "" // 出库时间
|
||||
var optCharge: Double = 0.0 // 服务费
|
||||
var whsCharge: Double = 0.0 // 仓储费
|
||||
var amount: Double = 0.0 // 总金额
|
||||
var chargeTime: String = "" // 缴费时间/提取时间
|
||||
var pkId: String = "" // 提货编号
|
||||
var tranCharge: Double = 0.0 // 信息费
|
||||
var drawBillCharge: Double = 0.0 // 抽单费
|
||||
var efrCharge: Double = 0.0 // 冷藏费
|
||||
var svlCharge: Double = 0.0 // 铲车费
|
||||
var tallyCharge: Double = 0.0 // 理货费
|
||||
var pipFee: Double = 0.0 // 精密仪器处理费
|
||||
var lapFee: Double = 0.0 // 活体动物处理费
|
||||
var chargeName: String = "" // 办理人名称
|
||||
var chargeId: String = "" // 收费员ID
|
||||
var dlvTime: String = "" // 出库时间
|
||||
|
||||
// ========== UI扩展字段 ==========
|
||||
val checked: ObservableBoolean = ObservableBoolean(false)
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
package com.lukouguoji.module_base.bean
|
||||
|
||||
/**
|
||||
* 国际进港运单修改-数据模型
|
||||
* 对应接口:/IntImpSearch/modifyMaWb 的请求体 (GjjMaWb)
|
||||
* 详情数据来源:/IntImpSearch/detail 返回的 maWb + maWbM + warehouseList
|
||||
*/
|
||||
data class IntImpQueryEditBean(
|
||||
// ==================== 主键 ====================
|
||||
var maWbId: Long? = null, // 主单主键ID
|
||||
var activeId: Long? = null, // 有效值
|
||||
|
||||
// ==================== 运单号(禁用) ====================
|
||||
var wbNo: String? = null, // 运单号(组合: prefix + no)
|
||||
var prefix: String? = null, // 运单号前缀
|
||||
var no: String? = null, // 运单号主体
|
||||
|
||||
// ==================== 可编辑字段 ====================
|
||||
var agentCode: String? = null, // 代理人code(提交用)
|
||||
var agentName: String? = null, // 代理人名称(显示用)
|
||||
var spCode: String? = null, // 特码
|
||||
var packageType: String? = null, // 包装类型
|
||||
var awbType: String? = null, // 运单类型code
|
||||
var lockState: String? = null, // 锁定状态("0":未锁, "1":锁定)
|
||||
var remark: String? = null, // 备注
|
||||
|
||||
// ==================== 禁用字段(仅显示) ====================
|
||||
var awbPc: Long? = null, // 运单件数(对应API: pc)
|
||||
var awbWeight: Double? = null, // 运单重量(对应API: weight)
|
||||
var businessType: String? = null, // 业务类型code
|
||||
var businessName: String? = null, // 业务类型名称
|
||||
var inPc: Long? = null, // 入库件数
|
||||
var inWeight: Double? = null, // 入库重量
|
||||
var cashWeight: Double? = null, // 计费重量
|
||||
var by1: String? = null, // 承运人
|
||||
var range: String? = null, // 航程
|
||||
var goodsCn: String? = null, // 品名(中)
|
||||
var goods: String? = null, // 品名(英)
|
||||
var unNumber: String? = null, // UN编号
|
||||
|
||||
// ==================== 提交时需要的额外字段 ====================
|
||||
var fno: String? = null, // 航班号
|
||||
var fdate: String? = null, // 航班日期
|
||||
var flight: String? = null, // 航班
|
||||
var pc: Long? = null, // 件数(API用)
|
||||
var weight: Double? = null, // 重量(API用)
|
||||
var volume: Double? = null, // 体积
|
||||
var origin: String? = null, // 货源地
|
||||
var dest: String? = null, // 目的地
|
||||
var cargoType: String? = null, // 货物类型
|
||||
var subCode: String? = null, // 子码
|
||||
var carId: String? = null // 车牌号
|
||||
)
|
||||
@@ -51,6 +51,7 @@ import com.lukouguoji.module_base.bean.GjjGoodsDetailsBean
|
||||
import com.lukouguoji.module_base.bean.GjjGoodsTypeBean
|
||||
import com.lukouguoji.module_base.bean.GjjHandoverRecordBean
|
||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||
import com.lukouguoji.module_base.bean.GjAccidentVisaEditBean
|
||||
import com.lukouguoji.module_base.bean.IntImpAccidentVisaBean
|
||||
import com.lukouguoji.module_base.bean.IntImpPickUpDLVBean
|
||||
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
||||
@@ -301,6 +302,12 @@ interface Api {
|
||||
@POST("typeCode/countryType")
|
||||
suspend fun getAreaTypeList(): DictListBean
|
||||
|
||||
/**
|
||||
* 获取国家代码
|
||||
*/
|
||||
@POST("typeCode/countryCode")
|
||||
suspend fun getCountryCodeList(): DictListBean
|
||||
|
||||
/**
|
||||
* 获取通讯方式类型
|
||||
*/
|
||||
@@ -912,73 +919,73 @@ interface Api {
|
||||
|
||||
/**
|
||||
* 国际进港仓库-分页查询
|
||||
* 接口路径: /IntImpStorageUse/pageQuery
|
||||
* 接口路径: /IntImpStorage/pageQuery
|
||||
*/
|
||||
@POST("IntImpStorageUse/pageQuery")
|
||||
@POST("IntImpStorage/pageQuery")
|
||||
suspend fun getIntImpStorageUseList(@Body data: RequestBody): PageInfo<GjcMaWb>
|
||||
|
||||
/**
|
||||
* 国际进港仓库-分页合计
|
||||
* 接口路径: /IntImpStorageUse/pageQueryTotal
|
||||
* 接口路径: /IntImpStorage/pageQueryTotal
|
||||
*/
|
||||
@POST("IntImpStorageUse/pageQueryTotal")
|
||||
@POST("IntImpStorage/pageQueryTotal")
|
||||
suspend fun getIntImpStorageUseTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||
|
||||
/**
|
||||
* 国际进港库位操作-清仓
|
||||
* 接口路径: /IntImpStorageUse/updateClear
|
||||
* 接口路径: /IntImpStorage/updateClear
|
||||
*/
|
||||
@POST("IntImpStorageUse/updateClear")
|
||||
suspend fun clearIntImpStorage(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
@POST("IntImpStorage/updateClear")
|
||||
suspend fun clearIntImpStorage(@Query("clearNormal") clearNormal: String, @Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港库位操作-修改库位
|
||||
* 接口路径: /IntImpStorageUse/modifyStorage
|
||||
* 接口路径: /IntImpStorage/modifyStorage
|
||||
*/
|
||||
@POST("IntImpStorageUse/modifyStorage")
|
||||
@POST("IntImpStorage/modifyStorage")
|
||||
suspend fun modifyIntImpStorage(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港库位操作-出库
|
||||
* 接口路径: /IntImpStorageUse/outStorage
|
||||
* 接口路径: /IntImpStorage/outStorage
|
||||
*/
|
||||
@POST("IntImpStorageUse/outStorage")
|
||||
@POST("IntImpStorage/outStorage")
|
||||
suspend fun outIntImpStorage(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港库位操作-入库
|
||||
* 接口路径: /IntImpStorageUse/inStorage
|
||||
* 接口路径: /IntImpStorage/inStorage
|
||||
*/
|
||||
@POST("IntImpStorageUse/inStorage")
|
||||
suspend fun inIntImpStorage(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
@POST("IntImpStorage/inStorage")
|
||||
suspend fun inIntImpStorage(@Query("location") location: String, @Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港提取记录-分页查询
|
||||
* 接口路径: /IntImpPickUpRecord/pageQuery
|
||||
* 接口路径: /IntImpPickup/pageQuery
|
||||
*/
|
||||
@POST("IntImpPickUpRecord/pageQuery")
|
||||
@POST("IntImpPickup/pageQuery")
|
||||
suspend fun getIntImpPickUpRecordList(@Body data: RequestBody): PageInfo<IntImpPickUpRecordBean>
|
||||
|
||||
/**
|
||||
* 国际进港提取记录-分页合计
|
||||
* 接口路径: /IntImpPickUpRecord/pageQueryTotal
|
||||
* 接口路径: /IntImpPickup/pageQueryTotal
|
||||
*/
|
||||
@POST("IntImpPickUpRecord/pageQueryTotal")
|
||||
@POST("IntImpPickup/pageQueryTotal")
|
||||
suspend fun getIntImpPickUpRecordTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||
|
||||
/**
|
||||
* 国际进港提取记录-清除提货
|
||||
* 接口路径: /IntImpPickUpRecord/clearPickUp
|
||||
* 接口路径: /IntImpPickup/clearPickup
|
||||
*/
|
||||
@POST("IntImpPickUpRecord/clearPickUp")
|
||||
suspend fun clearIntImpPickUp(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
@POST("IntImpPickup/clearPickup")
|
||||
suspend fun clearIntImpPickUp(@Body data: RequestBody): BaseResultBean<String>
|
||||
|
||||
/**
|
||||
* 国际进港提取记录-详情
|
||||
* 接口路径: /IntImpPickUpRecord/getDetails
|
||||
* 国际进港提取记录-修改费用
|
||||
* 接口路径: /IntImpPickup/modifyCharge
|
||||
*/
|
||||
@POST("IntImpPickUpRecord/getDetails")
|
||||
suspend fun getIntImpPickUpRecordDetails(@Body data: RequestBody): BaseResultBean<IntImpPickUpRecordBean>
|
||||
@POST("IntImpPickup/modifyCharge")
|
||||
suspend fun modifyIntImpPickUpCharge(@Body data: RequestBody): BaseResultBean<String>
|
||||
|
||||
/**
|
||||
* 国际进港提取出库-分页查询
|
||||
@@ -1015,6 +1022,20 @@ interface Api {
|
||||
@POST("IntImpSearch/pageQueryTotal")
|
||||
suspend fun getIntImpQueryTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||
|
||||
/**
|
||||
* 国际进港查询-详情
|
||||
* 接口路径: /IntImpSearch/detail
|
||||
*/
|
||||
@POST("IntImpSearch/detail")
|
||||
suspend fun getIntImpQueryDetails(@Body data: RequestBody): BaseResultBean<Map<String, Any>>
|
||||
|
||||
/**
|
||||
* 国际进港查询-修改运单
|
||||
* 接口路径: /IntImpSearch/modifyMaWb
|
||||
*/
|
||||
@POST("IntImpSearch/modifyMaWb")
|
||||
suspend fun modifyIntImpMaWb(@Body data: RequestBody): BaseResultBean<String>
|
||||
|
||||
/**
|
||||
* 国际出港待计重-分页搜索
|
||||
* 接口路径: /IntExpCheckIn/pageQuery
|
||||
@@ -1896,6 +1917,36 @@ interface Api {
|
||||
@POST("IntImpTally/pageQueryTotal")
|
||||
suspend fun getIntImpTallyTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||
|
||||
/**
|
||||
* 国际进港理货报告-查询分单列表
|
||||
*/
|
||||
@POST("IntImpTally/listHaWb")
|
||||
suspend fun getIntImpTallySubList(@Body data: RequestBody): BaseResultBean<List<GjjImportTally>>
|
||||
|
||||
/**
|
||||
* 国际进港理货-人工放行
|
||||
*/
|
||||
@POST("IntImpTally/customCommand")
|
||||
suspend fun intImpTallyCustomCommand(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港理货-状态重置
|
||||
*/
|
||||
@POST("IntImpTally/resetDeclare")
|
||||
suspend fun intImpTallyResetDeclare(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港理货-删除申报
|
||||
*/
|
||||
@POST("IntImpTally/deleteDeclare")
|
||||
suspend fun intImpTallyDeleteDeclare(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港理货-理货申报
|
||||
*/
|
||||
@POST("IntImpTally/declare")
|
||||
suspend fun intImpTallyDeclare(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||
|
||||
/**
|
||||
* 国际进港舱单-货物发放
|
||||
*/
|
||||
@@ -1918,6 +1969,42 @@ interface Api {
|
||||
@POST("GjAccidentVisa/delete")
|
||||
suspend fun deleteIntImpAccidentVisa(@Body data: RequestBody): BaseResultBean<String>
|
||||
|
||||
/**
|
||||
* 国际事故签证-新增
|
||||
*/
|
||||
@POST("GjAccidentVisa/saveVisa")
|
||||
suspend fun saveGjAccidentVisa(@Body data: RequestBody): BaseResultBean<String>
|
||||
|
||||
/**
|
||||
* 国际事故签证-修改
|
||||
*/
|
||||
@POST("GjAccidentVisa/modifyVisa")
|
||||
suspend fun modifyGjAccidentVisa(@Body data: RequestBody): BaseResultBean<String>
|
||||
|
||||
/**
|
||||
* 国际事故签证-详情
|
||||
*/
|
||||
@POST("GjAccidentVisa/detail")
|
||||
suspend fun getGjAccidentVisaDetail(@Query("id") id: Long): BaseResultBean<GjAccidentVisaEditBean>
|
||||
|
||||
/**
|
||||
* 字典-破损情况
|
||||
*/
|
||||
@POST("typeCode/damageType")
|
||||
suspend fun getDamageTypeList(): DictListBean
|
||||
|
||||
/**
|
||||
* 字典-内容物情况
|
||||
*/
|
||||
@POST("typeCode/contentType")
|
||||
suspend fun getContentTypeList(): DictListBean
|
||||
|
||||
/**
|
||||
* 字典-不正常类型
|
||||
*/
|
||||
@POST("typeCode/unusualType")
|
||||
suspend fun getUnusualTypeList(): DictListBean
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// ULD管理
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -102,6 +102,24 @@ object DictUtils {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取国际进港代理列表
|
||||
*/
|
||||
fun getIntImpAgentList(
|
||||
addAll: Boolean = true,
|
||||
checkedValue: String? = null,
|
||||
callBack: (List<KeyValue>) -> Unit
|
||||
) {
|
||||
launchCollect({
|
||||
NetApply.api
|
||||
.getIntImpAgentList()
|
||||
}) {
|
||||
onSuccess = {
|
||||
handleCallBack(it, checkedValue, addAll, callBack)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取仓管列表
|
||||
*/
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 775 B |
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:width="200dp"
|
||||
android:height="200dp"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
|
||||
@@ -100,11 +100,10 @@
|
||||
|
||||
<!-- 添加按钮 -->
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.addClick()}"
|
||||
android:padding="4dp"
|
||||
android:src="@drawable/img_add" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -104,11 +104,10 @@
|
||||
|
||||
<!-- 添加按钮 -->
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.addClick()}"
|
||||
android:padding="4dp"
|
||||
android:src="@drawable/img_add" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -97,11 +97,10 @@
|
||||
|
||||
<!-- 新<><E696B0><EFBFBD>按钮 -->
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.onAddClick()}"
|
||||
android:padding="4dp"
|
||||
android:src="@drawable/img_add" />
|
||||
|
||||
<!-- 删除按钮 -->
|
||||
|
||||
@@ -24,7 +24,7 @@ import com.lukouguoji.module_base.BaseActivity
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.router.ARouterConstants
|
||||
|
||||
@Route(path = ARouterConstants.ACTIVITY_URL_GJJ_QUERY_INFO)
|
||||
// @Route(path = ARouterConstants.ACTIVITY_URL_GJJ_QUERY_INFO) // 已替换为 IntImpQueryDetailsActivity
|
||||
class GjjQueryInfoActivity : BaseActivity(), View.OnClickListener {
|
||||
|
||||
private lateinit var viewModel: GjjQueryInfoViewModel
|
||||
|
||||
@@ -8,10 +8,14 @@ import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpAccidentVisaBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpAccidentVisaViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.bean.IntImpAccidentVisaBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.impl.observe
|
||||
import com.lukouguoji.module_base.interfaces.IOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.addOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||
import com.lukouguoji.module_base.router.ARouterConstants
|
||||
|
||||
/**
|
||||
@@ -19,7 +23,8 @@ import com.lukouguoji.module_base.router.ARouterConstants
|
||||
*/
|
||||
@Route(path = ARouterConstants.ACTIVITY_URL_INT_IMP_ACCIDENT_VISA)
|
||||
class IntImpAccidentVisaActivity :
|
||||
BaseBindingActivity<ActivityIntImpAccidentVisaBinding, IntImpAccidentVisaViewModel>() {
|
||||
BaseBindingActivity<ActivityIntImpAccidentVisaBinding, IntImpAccidentVisaViewModel>(),
|
||||
IOnItemClickListener {
|
||||
|
||||
override fun layoutId() = R.layout.activity_int_imp_accident_visa
|
||||
override fun viewModelClass() = IntImpAccidentVisaViewModel::class.java
|
||||
@@ -34,6 +39,8 @@ class IntImpAccidentVisaActivity :
|
||||
|
||||
viewModel.pageModel.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, this)
|
||||
|
||||
binding.rv.addOnItemClickListener(this)
|
||||
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||
viewModel.refresh()
|
||||
}
|
||||
@@ -48,4 +55,15 @@ class IntImpAccidentVisaActivity :
|
||||
viewModel.searchClick()
|
||||
}
|
||||
}
|
||||
|
||||
override fun onItemClick(position: Int, type: Int) {
|
||||
when (type) {
|
||||
2000 -> {
|
||||
// 侧滑菜单 - 修改
|
||||
val bean = binding.rv.commonAdapter()?.getItem(position) as? IntImpAccidentVisaBean
|
||||
?: return
|
||||
IntImpAccidentVisaEditActivity.start(this, bean.id)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
package com.lukouguoji.gjj.activity
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpAccidentVisaEditBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpAccidentVisaEditViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.DetailsPageType
|
||||
import com.lukouguoji.module_base.ktx.addOnItemClickListener
|
||||
|
||||
/**
|
||||
* 国际进港-事故签证新增/编辑
|
||||
*/
|
||||
class IntImpAccidentVisaEditActivity :
|
||||
BaseBindingActivity<ActivityIntImpAccidentVisaEditBinding, IntImpAccidentVisaEditViewModel>() {
|
||||
|
||||
override fun layoutId() = R.layout.activity_int_imp_accident_visa_edit
|
||||
override fun viewModelClass() = IntImpAccidentVisaEditViewModel::class.java
|
||||
|
||||
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||
binding.viewModel = viewModel
|
||||
|
||||
viewModel.rv = binding.rv
|
||||
binding.rv.addOnItemClickListener(viewModel)
|
||||
viewModel.initOnCreate(intent)
|
||||
|
||||
viewModel.pageType.observe(this) {
|
||||
val title = if (it == DetailsPageType.Add) "国际事故签证新增" else "国际事故签证修改"
|
||||
setBackArrow(title)
|
||||
}
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun start(context: Context, id: Long = 0) {
|
||||
context.startActivity(
|
||||
Intent(context, IntImpAccidentVisaEditActivity::class.java)
|
||||
.putExtra(Constant.Key.ID, id)
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
package com.lukouguoji.gjj.activity
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import com.google.gson.Gson
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpPickUpChargeEditBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpPickUpChargeEditViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
|
||||
/**
|
||||
* 国际进港-费用修改
|
||||
*/
|
||||
class IntImpPickUpChargeEditActivity :
|
||||
BaseBindingActivity<ActivityIntImpPickUpChargeEditBinding, IntImpPickUpChargeEditViewModel>() {
|
||||
|
||||
override fun layoutId() = R.layout.activity_int_imp_pick_up_charge_edit
|
||||
override fun viewModelClass() = IntImpPickUpChargeEditViewModel::class.java
|
||||
|
||||
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||
setBackArrow("国际进港费用修改")
|
||||
binding.viewModel = viewModel
|
||||
viewModel.initOnCreated(intent)
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun start(context: Context, bean: IntImpPickUpRecordBean) {
|
||||
val starter = Intent(context, IntImpPickUpChargeEditActivity::class.java)
|
||||
.putExtra(Constant.Key.DATA, Gson().toJson(bean))
|
||||
context.startActivity(starter)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,6 @@ package com.lukouguoji.gjj.activity
|
||||
import android.app.Activity
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import androidx.appcompat.app.AlertDialog
|
||||
import com.alibaba.android.arouter.facade.annotation.Route
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpPickUpRecordBinding
|
||||
@@ -14,8 +13,11 @@ import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.impl.observe
|
||||
import com.lukouguoji.module_base.interfaces.IOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.addOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.model.ConfirmDialogModel
|
||||
import com.lukouguoji.module_base.router.ARouterConstants
|
||||
|
||||
/**
|
||||
@@ -41,11 +43,35 @@ class IntImpPickUpRecordActivity :
|
||||
// 绑定分页
|
||||
viewModel.pageModel.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, this)
|
||||
|
||||
// 设置列表项点击回调(侧滑修改按钮)
|
||||
binding.rv.addOnItemClickListener(object : IOnItemClickListener {
|
||||
override fun onItemClick(position: Int, type: Int) {
|
||||
when (type) {
|
||||
2000 -> {
|
||||
// 侧滑修改操作
|
||||
val list = viewModel.pageModel.rv?.commonAdapter()?.items as? List<*> ?: return
|
||||
val bean = list.getOrNull(position) as? IntImpPickUpRecordBean ?: return
|
||||
IntImpPickUpChargeEditActivity.start(this@IntImpPickUpRecordActivity, bean)
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
// 监听刷新事件
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||
viewModel.refresh()
|
||||
}
|
||||
|
||||
// 运单号自动查询额外参数
|
||||
binding.pslWbNo.autoQueryConfig.extraParamsProvider = {
|
||||
mapOf(
|
||||
"beginDate" to viewModel.paymentDateStart.value,
|
||||
"endDate" to viewModel.paymentDateEnd.value,
|
||||
"agentCode" to viewModel.agentCode.value,
|
||||
"spCode" to viewModel.spCode.value
|
||||
)
|
||||
}
|
||||
|
||||
// 初始化下拉列表
|
||||
viewModel.initAgentList()
|
||||
viewModel.initSpecialCodeList()
|
||||
@@ -68,14 +94,12 @@ class IntImpPickUpRecordActivity :
|
||||
return
|
||||
}
|
||||
|
||||
AlertDialog.Builder(this)
|
||||
.setTitle("清除提货确认")
|
||||
.setMessage("确定要清除选中的 ${selectedItems.size} 条提货记录吗?")
|
||||
.setPositiveButton("确定") { _, _ ->
|
||||
viewModel.clearPickUp(selectedItems)
|
||||
}
|
||||
.setNegativeButton("取消", null)
|
||||
.show()
|
||||
ConfirmDialogModel(
|
||||
message = "确定要清除选中的 ${selectedItems.size} 条提货记录吗?",
|
||||
title = "清除提货确认"
|
||||
) {
|
||||
viewModel.clearPickUp(selectedItems)
|
||||
}.show(this)
|
||||
}
|
||||
|
||||
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||
|
||||
@@ -3,10 +3,12 @@ package com.lukouguoji.gjj.activity
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import com.google.gson.Gson
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpPickUpRecordDetailsBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpPickUpRecordDetailsViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
|
||||
/**
|
||||
@@ -26,9 +28,9 @@ class IntImpPickUpRecordDetailsActivity :
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun start(context: Context, id: Long) {
|
||||
fun start(context: Context, bean: IntImpPickUpRecordBean) {
|
||||
val starter = Intent(context, IntImpPickUpRecordDetailsActivity::class.java)
|
||||
.putExtra(Constant.Key.ID, id)
|
||||
.putExtra(Constant.Key.DATA, Gson().toJson(bean))
|
||||
context.startActivity(starter)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.impl.observe
|
||||
import com.lukouguoji.module_base.ktx.addOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.getLifecycleOwner
|
||||
import com.lukouguoji.module_base.router.ARouterConstants
|
||||
|
||||
@@ -33,11 +34,15 @@ class IntImpQueryActivity :
|
||||
viewModel.pageModel
|
||||
.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, getLifecycleOwner())
|
||||
|
||||
// 注册列表项点击事件
|
||||
binding.rv.addOnItemClickListener(viewModel)
|
||||
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||
viewModel.refresh()
|
||||
}
|
||||
|
||||
viewModel.initAgentList()
|
||||
viewModel.initSpecialCodeList()
|
||||
|
||||
viewModel.refresh()
|
||||
}
|
||||
|
||||
@@ -0,0 +1,58 @@
|
||||
package com.lukouguoji.gjj.activity
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import com.alibaba.android.arouter.facade.annotation.Route
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpQueryDetailsBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpQueryDetailsViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.base.CustomVP2Adapter
|
||||
import com.lukouguoji.module_base.router.ARouterConstants
|
||||
|
||||
/**
|
||||
* 国际进港查询详情页面
|
||||
*/
|
||||
@Route(path = ARouterConstants.ACTIVITY_URL_GJJ_QUERY_INFO)
|
||||
class IntImpQueryDetailsActivity :
|
||||
BaseBindingActivity<ActivityIntImpQueryDetailsBinding, IntImpQueryDetailsViewModel>() {
|
||||
|
||||
override fun layoutId() = R.layout.activity_int_imp_query_details
|
||||
override fun viewModelClass() = IntImpQueryDetailsViewModel::class.java
|
||||
|
||||
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||
setBackArrow("国际进港查询详情")
|
||||
binding.viewModel = viewModel
|
||||
|
||||
// 初始化ViewModel(传入maWbId)
|
||||
viewModel.initOnCreated(intent)
|
||||
|
||||
// 配置ViewPager2
|
||||
binding.vp.adapter = CustomVP2Adapter(
|
||||
viewModel.fragmentList,
|
||||
supportFragmentManager,
|
||||
lifecycle
|
||||
)
|
||||
binding.vp.isUserInputEnabled = false // 禁用滑动
|
||||
binding.vp.offscreenPageLimit = 3 // 预加载3个Fragment
|
||||
|
||||
// 监听Tab索引变化,切换Fragment
|
||||
viewModel.currentTab.observe(this) {
|
||||
binding.vp.setCurrentItem(it, false)
|
||||
}
|
||||
|
||||
// 加载详情数据
|
||||
viewModel.loadDetails()
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun start(context: Context, prefix: String?, no: String?) {
|
||||
val starter = Intent(context, IntImpQueryDetailsActivity::class.java)
|
||||
.putExtra("prefix", prefix ?: "")
|
||||
.putExtra("no", no ?: "")
|
||||
context.startActivity(starter)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
package com.lukouguoji.gjj.activity
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpQueryEditBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpQueryEditViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
|
||||
/**
|
||||
* 国际进港运单修改页面
|
||||
*/
|
||||
class IntImpQueryEditActivity :
|
||||
BaseBindingActivity<ActivityIntImpQueryEditBinding, IntImpQueryEditViewModel>() {
|
||||
|
||||
override fun layoutId() = R.layout.activity_int_imp_query_edit
|
||||
|
||||
override fun viewModelClass() = IntImpQueryEditViewModel::class.java
|
||||
|
||||
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||
setBackArrow("国际进港运单修改")
|
||||
binding.viewModel = viewModel
|
||||
viewModel.initOnCreated(intent)
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun start(context: Context, maWbId: Long?, prefix: String?, no: String?) {
|
||||
val starter = Intent(context, IntImpQueryEditActivity::class.java)
|
||||
.putExtra("maWbId", maWbId ?: 0L)
|
||||
.putExtra("prefix", prefix ?: "")
|
||||
.putExtra("no", no ?: "")
|
||||
context.startActivity(starter)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,7 @@ package com.lukouguoji.gjj.activity
|
||||
import android.app.Activity
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import androidx.appcompat.app.AlertDialog
|
||||
import com.lukouguoji.module_base.model.ConfirmDialogModel
|
||||
import com.alibaba.android.arouter.facade.annotation.Route
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpStorageUseBinding
|
||||
@@ -60,12 +60,17 @@ class IntImpStorageUseActivity :
|
||||
val allItems = list.filterIsInstance<com.lukouguoji.module_base.bean.GjcMaWb>()
|
||||
|
||||
val maWbListForClear = allItems.mapNotNull { maWb ->
|
||||
val selectedStorageList = maWb.storageUseList?.filter { it.isSelected } ?: emptyList()
|
||||
|
||||
if (selectedStorageList.isNotEmpty() || maWb.isSelected) {
|
||||
maWb.copy(storageUseList = selectedStorageList)
|
||||
if (maWb.isSelected) {
|
||||
// 勾选运单号 → 默认全选该运单号下的所有库位
|
||||
maWb.copy(storageUseList = maWb.storageUseList ?: emptyList())
|
||||
} else {
|
||||
null
|
||||
// 勾选库位号 → 只对选择的库位进行操作
|
||||
val selectedStorageList = maWb.storageUseList?.filter { it.isSelected } ?: emptyList()
|
||||
if (selectedStorageList.isNotEmpty()) {
|
||||
maWb.copy(storageUseList = selectedStorageList)
|
||||
} else {
|
||||
null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -105,6 +110,7 @@ class IntImpStorageUseActivity :
|
||||
|
||||
val selectedStorage = selectedStorageUseList[0]
|
||||
|
||||
// 弹出库位选择弹框,选择后再调用接口
|
||||
IntImpModifyStorageDialogModel { dialog ->
|
||||
val locationName = dialog.locationName
|
||||
val locationId = dialog.locationId
|
||||
@@ -119,24 +125,32 @@ class IntImpStorageUseActivity :
|
||||
val list = viewModel.pageModel.rv?.commonAdapter()?.items as? List<*> ?: return
|
||||
val allItems = list.filterIsInstance<com.lukouguoji.module_base.bean.GjcMaWb>()
|
||||
|
||||
val selectedStorageUseList = mutableListOf<com.lukouguoji.module_base.bean.GjcStorageUse>()
|
||||
allItems.forEach { maWb ->
|
||||
maWb.storageUseList?.filter { it.isSelected }?.let { selectedStorageUseList.addAll(it) }
|
||||
val maWbListForOutStorage = allItems.mapNotNull { maWb ->
|
||||
if (maWb.isSelected) {
|
||||
// 勾选运单号 → 默认全选该运单号下的所有库位
|
||||
maWb.copy(storageUseList = maWb.storageUseList ?: emptyList())
|
||||
} else {
|
||||
// 勾选库位号 → 只对选择的库位进行操作
|
||||
val selectedStorageList = maWb.storageUseList?.filter { it.isSelected } ?: emptyList()
|
||||
if (selectedStorageList.isNotEmpty()) {
|
||||
maWb.copy(storageUseList = selectedStorageList)
|
||||
} else {
|
||||
null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (selectedStorageUseList.isEmpty()) {
|
||||
if (maWbListForOutStorage.isEmpty()) {
|
||||
showToast("请选择要出库的库位")
|
||||
return
|
||||
}
|
||||
|
||||
AlertDialog.Builder(this)
|
||||
.setTitle("出库确认")
|
||||
.setMessage("确定要将选中的 ${selectedStorageUseList.size} 个库位执行出库操作吗?")
|
||||
.setPositiveButton("确定") { _, _ ->
|
||||
viewModel.performOutStorage(selectedStorageUseList)
|
||||
}
|
||||
.setNegativeButton("取消", null)
|
||||
.show()
|
||||
ConfirmDialogModel(
|
||||
message = "是否确认出库?",
|
||||
title = "出库确认"
|
||||
) {
|
||||
viewModel.performOutStorage(maWbListForOutStorage)
|
||||
}.show(this)
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -147,12 +161,17 @@ class IntImpStorageUseActivity :
|
||||
val allItems = list.filterIsInstance<com.lukouguoji.module_base.bean.GjcMaWb>()
|
||||
|
||||
val maWbListForInStorage = allItems.mapNotNull { maWb ->
|
||||
val selectedStorageList = maWb.storageUseList?.filter { it.isSelected } ?: emptyList()
|
||||
|
||||
if (selectedStorageList.isNotEmpty() || maWb.isSelected) {
|
||||
maWb.copy(storageUseList = selectedStorageList)
|
||||
if (maWb.isSelected) {
|
||||
// 勾选运单号 → 默认全选该运单号下的所有库位
|
||||
maWb.copy(storageUseList = maWb.storageUseList ?: emptyList())
|
||||
} else {
|
||||
null
|
||||
// 勾选库位号 → 只对选择的库位进行操作
|
||||
val selectedStorageList = maWb.storageUseList?.filter { it.isSelected } ?: emptyList()
|
||||
if (selectedStorageList.isNotEmpty()) {
|
||||
maWb.copy(storageUseList = selectedStorageList)
|
||||
} else {
|
||||
null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
package com.lukouguoji.gjj.activity
|
||||
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.os.Bundle
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ActivityIntImpTallyDetailsBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpTallyDetailsViewModel
|
||||
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
|
||||
/**
|
||||
* 国际进港理货报告详情
|
||||
*/
|
||||
class IntImpTallyDetailsActivity :
|
||||
BaseBindingActivity<ActivityIntImpTallyDetailsBinding, IntImpTallyDetailsViewModel>() {
|
||||
|
||||
override fun layoutId() = R.layout.activity_int_imp_tally_details
|
||||
override fun viewModelClass() = IntImpTallyDetailsViewModel::class.java
|
||||
|
||||
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||
setBackArrow("理货报告详情")
|
||||
binding.viewModel = viewModel
|
||||
viewModel.initOnCreated(intent)
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun start(context: Context, tally: GjjImportTally) {
|
||||
val starter = Intent(context, IntImpTallyDetailsActivity::class.java)
|
||||
.putExtra(Constant.Key.DATA, tally)
|
||||
context.startActivity(starter)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -20,6 +20,7 @@ import dev.utils.app.info.KeyValue
|
||||
*/
|
||||
class IntImpQueryFilterDialogModel(
|
||||
val spCode: MutableLiveData<String>,
|
||||
val spCodeList: MutableLiveData<List<KeyValue>>,
|
||||
val flightNo: MutableLiveData<String>,
|
||||
val dest: MutableLiveData<String>,
|
||||
val awbType: MutableLiveData<String>,
|
||||
|
||||
@@ -0,0 +1,58 @@
|
||||
package com.lukouguoji.gjj.dialog
|
||||
|
||||
import android.content.Context
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.DialogIntImpTallyDeleteBinding
|
||||
import com.lukouguoji.module_base.base.BaseDialogModel
|
||||
import com.lukouguoji.module_base.ktx.verifyNullOrEmpty
|
||||
import dev.utils.app.info.KeyValue
|
||||
|
||||
/**
|
||||
* 国际进港理货 - 删除申报对话框
|
||||
*/
|
||||
class IntImpTallyDeleteDialogModel(
|
||||
val changeReasonList: List<KeyValue>, // 变更原因列表
|
||||
private val callback: (IntImpTallyDeleteDialogModel) -> Unit
|
||||
) : BaseDialogModel<DialogIntImpTallyDeleteBinding>(DIALOG_TYPE_CENTER) {
|
||||
|
||||
// 变更原因代码(存储的是 code)
|
||||
val changeReason = MutableLiveData("")
|
||||
|
||||
// 联系人姓名
|
||||
val contactName = MutableLiveData("")
|
||||
|
||||
// 联系人电话
|
||||
val contactPhone = MutableLiveData("")
|
||||
|
||||
override fun layoutId(): Int {
|
||||
return R.layout.dialog_int_imp_tally_delete
|
||||
}
|
||||
|
||||
override fun onDialogCreated(context: Context) {
|
||||
binding.model = this
|
||||
}
|
||||
|
||||
/**
|
||||
* 确认按钮点击
|
||||
*/
|
||||
fun onConfirmClick() {
|
||||
// 验证变更原因
|
||||
if (changeReason.value.verifyNullOrEmpty("请选择变更原因")) {
|
||||
return
|
||||
}
|
||||
|
||||
// 验证联系人姓名
|
||||
if (contactName.value.verifyNullOrEmpty("请输入联系人姓名")) {
|
||||
return
|
||||
}
|
||||
|
||||
// 验证联系人电话
|
||||
if (contactPhone.value.verifyNullOrEmpty("请输入联系人电话")) {
|
||||
return
|
||||
}
|
||||
|
||||
dismiss()
|
||||
callback(this)
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
package com.lukouguoji.gjj.dialog
|
||||
|
||||
import android.content.Context
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.DialogIntImpTallyResetBinding
|
||||
import com.lukouguoji.module_base.base.BaseDialogModel
|
||||
import com.lukouguoji.module_base.ktx.verifyNullOrEmpty
|
||||
import dev.utils.app.info.KeyValue
|
||||
|
||||
/**
|
||||
* 国际进港理货 - 状态重置对话框
|
||||
*/
|
||||
class IntImpTallyResetDialogModel(
|
||||
private val callback: (IntImpTallyResetDialogModel) -> Unit
|
||||
) : BaseDialogModel<DialogIntImpTallyResetBinding>(DIALOG_TYPE_CENTER) {
|
||||
|
||||
// 重置状态列表
|
||||
val resetStatusList = MutableLiveData<List<KeyValue>>()
|
||||
|
||||
// 选中的重置状态(存储的是value)
|
||||
val selectedResetStatus = MutableLiveData("")
|
||||
|
||||
// 重置状态code (传给后端的restStatus参数)
|
||||
var resetStatusCode: String? = null
|
||||
|
||||
override fun layoutId(): Int {
|
||||
return R.layout.dialog_int_imp_tally_reset
|
||||
}
|
||||
|
||||
override fun onDialogCreated(context: Context) {
|
||||
binding.model = this
|
||||
initResetStatusList()
|
||||
|
||||
// 监听选择变化,更新resetStatusCode
|
||||
selectedResetStatus.observeForever { value ->
|
||||
resetStatusCode = when (value) {
|
||||
"01" -> "01" // 正常
|
||||
"02" -> null // 未申报
|
||||
else -> null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 初始化重置状态列表
|
||||
*/
|
||||
private fun initResetStatusList() {
|
||||
val list = listOf(
|
||||
KeyValue("正常", "01"),
|
||||
KeyValue("未申报", "02")
|
||||
)
|
||||
resetStatusList.value = list
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存按钮点击
|
||||
*/
|
||||
fun onSaveClick() {
|
||||
if (selectedResetStatus.value.verifyNullOrEmpty("请选择重置状态")) {
|
||||
return
|
||||
}
|
||||
dismiss()
|
||||
callback(this)
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,89 @@
|
||||
package com.lukouguoji.gjj.fragment
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import androidx.databinding.DataBindingUtil
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.FragmentIntImpQueryStorageBinding
|
||||
import com.lukouguoji.gjj.holder.IntImpQueryStorageViewHolder
|
||||
import com.lukouguoji.gjj.viewModel.IntImpQueryDetailsViewModel
|
||||
import com.lukouguoji.module_base.base.CommonAdapter
|
||||
import com.lukouguoji.module_base.bean.GjjStorageUse
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
|
||||
/**
|
||||
* 国际进港查询详情 - 库位信息Fragment
|
||||
*/
|
||||
class IntImpQueryStorageFragment : Fragment() {
|
||||
|
||||
private lateinit var binding: FragmentIntImpQueryStorageBinding
|
||||
private lateinit var viewModel: IntImpQueryDetailsViewModel
|
||||
private lateinit var adapter: CommonAdapter
|
||||
|
||||
override fun onCreateView(
|
||||
inflater: LayoutInflater,
|
||||
container: ViewGroup?,
|
||||
savedInstanceState: Bundle?
|
||||
): View {
|
||||
binding = DataBindingUtil.inflate(
|
||||
inflater,
|
||||
R.layout.fragment_int_imp_query_storage,
|
||||
container,
|
||||
false
|
||||
)
|
||||
binding.lifecycleOwner = viewLifecycleOwner
|
||||
|
||||
initRecyclerView()
|
||||
observeData()
|
||||
|
||||
return binding.root
|
||||
}
|
||||
|
||||
private fun initRecyclerView() {
|
||||
adapter = CommonAdapter(
|
||||
requireContext(),
|
||||
R.layout.item_int_imp_query_storage,
|
||||
IntImpQueryStorageViewHolder::class.java
|
||||
)
|
||||
|
||||
binding.rvStorageList.apply {
|
||||
layoutManager = LinearLayoutManager(requireContext())
|
||||
adapter = this@IntImpQueryStorageFragment.adapter
|
||||
}
|
||||
}
|
||||
|
||||
private fun observeData() {
|
||||
viewModel.storageUseList.observe(viewLifecycleOwner) { mapList ->
|
||||
if (mapList.isEmpty()) {
|
||||
binding.rvStorageList.visibility = View.GONE
|
||||
binding.llEmpty.visibility = View.VISIBLE
|
||||
} else {
|
||||
val beanList = mapList.map { map ->
|
||||
try {
|
||||
val json = NetApply.gson.toJson(map)
|
||||
NetApply.gson.fromJson(json, GjjStorageUse::class.java)
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
GjjStorageUse()
|
||||
}
|
||||
}
|
||||
|
||||
binding.rvStorageList.visibility = View.VISIBLE
|
||||
binding.llEmpty.visibility = View.GONE
|
||||
adapter.refresh(beanList)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun newInstance(vm: IntImpQueryDetailsViewModel) =
|
||||
IntImpQueryStorageFragment().apply {
|
||||
viewModel = vm
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,89 @@
|
||||
package com.lukouguoji.gjj.fragment
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import androidx.databinding.DataBindingUtil
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.FragmentIntImpQueryWarehouseBinding
|
||||
import com.lukouguoji.gjj.holder.IntImpQueryWarehouseViewHolder
|
||||
import com.lukouguoji.gjj.viewModel.IntImpQueryDetailsViewModel
|
||||
import com.lukouguoji.module_base.base.CommonAdapter
|
||||
import com.lukouguoji.module_base.bean.GjjWarehouse
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
|
||||
/**
|
||||
* 国际进港查询详情 - 仓库信息Fragment
|
||||
*/
|
||||
class IntImpQueryWarehouseFragment : Fragment() {
|
||||
|
||||
private lateinit var binding: FragmentIntImpQueryWarehouseBinding
|
||||
private lateinit var viewModel: IntImpQueryDetailsViewModel
|
||||
private lateinit var adapter: CommonAdapter
|
||||
|
||||
override fun onCreateView(
|
||||
inflater: LayoutInflater,
|
||||
container: ViewGroup?,
|
||||
savedInstanceState: Bundle?
|
||||
): View {
|
||||
binding = DataBindingUtil.inflate(
|
||||
inflater,
|
||||
R.layout.fragment_int_imp_query_warehouse,
|
||||
container,
|
||||
false
|
||||
)
|
||||
binding.lifecycleOwner = viewLifecycleOwner
|
||||
|
||||
initRecyclerView()
|
||||
observeData()
|
||||
|
||||
return binding.root
|
||||
}
|
||||
|
||||
private fun initRecyclerView() {
|
||||
adapter = CommonAdapter(
|
||||
requireContext(),
|
||||
R.layout.item_int_imp_query_warehouse,
|
||||
IntImpQueryWarehouseViewHolder::class.java
|
||||
)
|
||||
|
||||
binding.rvWarehouseList.apply {
|
||||
layoutManager = LinearLayoutManager(requireContext())
|
||||
adapter = this@IntImpQueryWarehouseFragment.adapter
|
||||
}
|
||||
}
|
||||
|
||||
private fun observeData() {
|
||||
viewModel.warehouseList.observe(viewLifecycleOwner) { mapList ->
|
||||
if (mapList.isEmpty()) {
|
||||
binding.rvWarehouseList.visibility = View.GONE
|
||||
binding.llEmpty.visibility = View.VISIBLE
|
||||
} else {
|
||||
val beanList = mapList.map { map ->
|
||||
try {
|
||||
val json = NetApply.gson.toJson(map)
|
||||
NetApply.gson.fromJson(json, GjjWarehouse::class.java)
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
GjjWarehouse()
|
||||
}
|
||||
}
|
||||
|
||||
binding.rvWarehouseList.visibility = View.VISIBLE
|
||||
binding.llEmpty.visibility = View.GONE
|
||||
adapter.refresh(beanList)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun newInstance(vm: IntImpQueryDetailsViewModel) =
|
||||
IntImpQueryWarehouseFragment().apply {
|
||||
viewModel = vm
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
package com.lukouguoji.gjj.fragment
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import androidx.databinding.DataBindingUtil
|
||||
import androidx.fragment.app.Fragment
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.FragmentIntImpQueryWaybillBinding
|
||||
import com.lukouguoji.gjj.viewModel.IntImpQueryDetailsViewModel
|
||||
|
||||
/**
|
||||
* 国际进港查询详情 - 运单信息Fragment
|
||||
*/
|
||||
class IntImpQueryWaybillFragment : Fragment() {
|
||||
|
||||
private lateinit var binding: FragmentIntImpQueryWaybillBinding
|
||||
private lateinit var viewModel: IntImpQueryDetailsViewModel
|
||||
|
||||
override fun onCreateView(
|
||||
inflater: LayoutInflater,
|
||||
container: ViewGroup?,
|
||||
savedInstanceState: Bundle?
|
||||
): View {
|
||||
binding = DataBindingUtil.inflate(
|
||||
inflater,
|
||||
R.layout.fragment_int_imp_query_waybill,
|
||||
container,
|
||||
false
|
||||
)
|
||||
binding.lifecycleOwner = viewLifecycleOwner
|
||||
binding.viewModel = viewModel
|
||||
return binding.root
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun newInstance(vm: IntImpQueryDetailsViewModel) =
|
||||
IntImpQueryWaybillFragment().apply {
|
||||
viewModel = vm
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -21,5 +21,11 @@ class IntImpAccidentVisaViewHolder(view: View) :
|
||||
bean.checked.set(!bean.checked.get())
|
||||
binding.executePendingBindings()
|
||||
}
|
||||
|
||||
// 侧滑菜单 - 修改按钮
|
||||
binding.btnEdit.setOnClickListener {
|
||||
binding.swipeMenu.quickClose()
|
||||
clickListener?.onItemClick(position, 2000) // type=2000表示修改操作
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -62,6 +62,29 @@ class IntImpManifestViewHolder(view: View) :
|
||||
|
||||
// 设置父Bean引用(用于子列表反向联动)
|
||||
binding.rvSub.tag = bean
|
||||
binding.rvSub.refresh(bean.haWbList ?: emptyList())
|
||||
val subList = bean.haWbList ?: emptyList()
|
||||
binding.rvSub.refresh(subList)
|
||||
updateSubListVisibility(bean.haWbList != null, subList.isNotEmpty())
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据分单数据状态,切换表头/列表与空数据提示的显隐
|
||||
* @param loaded 是否已加载过数据(haWbList != null)
|
||||
* @param hasData 是否有数据
|
||||
*/
|
||||
private fun updateSubListVisibility(loaded: Boolean, hasData: Boolean) {
|
||||
if (!loaded || hasData) {
|
||||
// 未加载或有数据:显示表头+列表,隐藏空提示
|
||||
binding.llHeader.visibility = View.VISIBLE
|
||||
binding.dividerHeader.visibility = View.VISIBLE
|
||||
binding.rvSub.visibility = View.VISIBLE
|
||||
binding.tvEmpty.visibility = View.GONE
|
||||
} else {
|
||||
// 已加载但无数据:隐藏表头+列表,显示空提示
|
||||
binding.llHeader.visibility = View.GONE
|
||||
binding.dividerHeader.visibility = View.GONE
|
||||
binding.rvSub.visibility = View.GONE
|
||||
binding.tvEmpty.visibility = View.VISIBLE
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,8 +25,14 @@ class IntImpPickUpRecordViewHolder(view: View) :
|
||||
}
|
||||
|
||||
// 列表项点击进入提取详情
|
||||
itemView.setOnClickListener {
|
||||
IntImpPickUpRecordDetailsActivity.start(itemView.context, bean.id)
|
||||
binding.ll.setOnClickListener {
|
||||
IntImpPickUpRecordDetailsActivity.start(itemView.context, bean)
|
||||
}
|
||||
|
||||
// 侧滑菜单 - 修改按钮
|
||||
binding.btnEdit.setOnClickListener {
|
||||
binding.swipeMenu.quickClose()
|
||||
clickListener?.onItemClick(position, 2000) // type=2000表示修改操作
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.lukouguoji.gjj.holder
|
||||
|
||||
import android.view.View
|
||||
import com.lukouguoji.gjj.databinding.ItemIntImpQueryStorageBinding
|
||||
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||
import com.lukouguoji.module_base.bean.GjjStorageUse
|
||||
|
||||
/**
|
||||
* 国际进港查询详情-库位信息ViewHolder
|
||||
*/
|
||||
class IntImpQueryStorageViewHolder(view: View) :
|
||||
BaseViewHolder<GjjStorageUse, ItemIntImpQueryStorageBinding>(view) {
|
||||
|
||||
override fun onBind(item: Any?, position: Int) {
|
||||
val bean = getItemBean(item) ?: return
|
||||
binding.bean = bean
|
||||
binding.position = position
|
||||
binding.executePendingBindings()
|
||||
}
|
||||
}
|
||||
@@ -15,5 +15,14 @@ class IntImpQueryViewHolder(view: View) :
|
||||
val bean = getItemBean(item)!!
|
||||
binding.bean = bean
|
||||
binding.executePendingBindings()
|
||||
|
||||
// 注册整行点击事件
|
||||
notifyItemClick(position, binding.ll)
|
||||
|
||||
// 侧滑菜单 - 修改按钮
|
||||
binding.btnEdit.setOnClickListener {
|
||||
binding.swipeMenu.quickClose()
|
||||
clickListener?.onItemClick(position, 2000) // type=2000表示修改操作
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
package com.lukouguoji.gjj.holder
|
||||
|
||||
import android.view.View
|
||||
import com.lukouguoji.gjj.databinding.ItemIntImpQueryWarehouseBinding
|
||||
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||
import com.lukouguoji.module_base.bean.GjjWarehouse
|
||||
|
||||
/**
|
||||
* 国际进港查询详情-仓库信息ViewHolder
|
||||
*/
|
||||
class IntImpQueryWarehouseViewHolder(view: View) :
|
||||
BaseViewHolder<GjjWarehouse, ItemIntImpQueryWarehouseBinding>(view) {
|
||||
|
||||
override fun onBind(item: Any?, position: Int) {
|
||||
val bean = getItemBean(item) ?: return
|
||||
binding.bean = bean
|
||||
binding.position = position
|
||||
binding.executePendingBindings()
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
package com.lukouguoji.gjj.holder
|
||||
|
||||
import android.view.View
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.lukouguoji.gjj.databinding.ItemIntImpTallySubBinding
|
||||
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||
|
||||
/**
|
||||
* 国际进港理货报告 分单子列表 ViewHolder
|
||||
*/
|
||||
class IntImpTallySubViewHolder(view: View) :
|
||||
BaseViewHolder<GjjImportTally, ItemIntImpTallySubBinding>(view) {
|
||||
|
||||
override fun onBind(item: Any?, position: Int) {
|
||||
val bean = getItemBean(item) ?: return
|
||||
binding.bean = bean
|
||||
binding.position = position
|
||||
binding.executePendingBindings()
|
||||
|
||||
// 单选框点击切换选择状态(反向联动主列表)
|
||||
binding.ivCheckbox.setOnClickListener {
|
||||
val newCheckedState = !bean.checked.get()
|
||||
bean.checked.set(newCheckedState)
|
||||
binding.executePendingBindings()
|
||||
|
||||
// 反向联动主列表项(勾选时联动主项也勾选)
|
||||
updateParentCheckState(newCheckedState)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新父列表项的选择状态
|
||||
*/
|
||||
private fun updateParentCheckState(newCheckedState: Boolean) {
|
||||
val recyclerView = itemView.parent as? RecyclerView ?: return
|
||||
val parentBean = recyclerView.tag as? GjjImportTally ?: return
|
||||
|
||||
if (newCheckedState) {
|
||||
parentBean.checked.set(true)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,17 @@
|
||||
package com.lukouguoji.gjj.holder
|
||||
|
||||
import android.view.View
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.databinding.ItemIntImpTallyBinding
|
||||
import com.lukouguoji.gjj.activity.IntImpTallyDetailsActivity
|
||||
import com.lukouguoji.module_base.adapter.setCommonAdapter
|
||||
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||
import com.google.gson.Gson
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.ktx.launchCollect
|
||||
import com.lukouguoji.module_base.ktx.refresh
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
|
||||
/**
|
||||
* 国际进港理货报告 ViewHolder
|
||||
@@ -17,10 +25,84 @@ class IntImpTallyViewHolder(view: View) :
|
||||
binding.position = position
|
||||
binding.executePendingBindings()
|
||||
|
||||
// 选中图标点击 - 切换选择状态
|
||||
// 选中图标点击 - 切换选择状态(联动子列表)
|
||||
binding.ivIcon.setOnClickListener {
|
||||
bean.checked.set(!bean.checked.get())
|
||||
val newCheckedState = !bean.checked.get()
|
||||
bean.checked.set(newCheckedState)
|
||||
|
||||
// 联动勾选/取消所有子列表项
|
||||
bean.haWbList?.forEach { sub ->
|
||||
sub.checked.set(newCheckedState)
|
||||
}
|
||||
|
||||
binding.executePendingBindings()
|
||||
binding.rvSub.adapter?.notifyDataSetChanged()
|
||||
}
|
||||
|
||||
// 整个内容区域点击 - 跳转到详情页
|
||||
binding.llContent.setOnClickListener {
|
||||
IntImpTallyDetailsActivity.start(it.context, bean)
|
||||
}
|
||||
|
||||
// 展开按钮点击事件
|
||||
binding.ivShow.setOnClickListener {
|
||||
if (bean.haWbList != null) {
|
||||
// 已加载过数据,直接切换显隐
|
||||
bean.showMore.set(!bean.showMore.get())
|
||||
} else {
|
||||
// 首次展开,调用接口加载分单数据
|
||||
loadSubList(bean)
|
||||
}
|
||||
}
|
||||
|
||||
// 初始化分单子列表 RecyclerView
|
||||
setCommonAdapter(
|
||||
binding.rvSub,
|
||||
IntImpTallySubViewHolder::class.java,
|
||||
R.layout.item_int_imp_tally_sub
|
||||
)
|
||||
|
||||
// 刷新分单数据(传递父Bean引用用于反向联动)
|
||||
binding.rvSub.tag = bean
|
||||
val subList = bean.haWbList ?: emptyList()
|
||||
binding.rvSub.refresh(subList)
|
||||
updateSubListVisibility(subList.isNotEmpty())
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载分单列表数据(将主单整体作为请求参数)
|
||||
*/
|
||||
private fun loadSubList(bean: GjjImportTally) {
|
||||
// 将 bean 转为 Map 并补充 wbNo 字段(prefix + no)
|
||||
val map = Gson().fromJson(Gson().toJson(bean), HashMap::class.java) as HashMap<String, Any?>
|
||||
map["wbNo"] = bean.getWaybillNo()
|
||||
val params = map.toRequestBody()
|
||||
|
||||
launchCollect({ NetApply.api.getIntImpTallySubList(params) }) {
|
||||
onSuccess = { result ->
|
||||
val list = result.data?.toMutableList() ?: mutableListOf()
|
||||
bean.haWbList = list
|
||||
bean.showMore.set(true)
|
||||
binding.rvSub.refresh(list)
|
||||
updateSubListVisibility(list.isNotEmpty())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据分单数据是否为空,切换表头/列表与空数据提示的显隐
|
||||
*/
|
||||
private fun updateSubListVisibility(hasData: Boolean) {
|
||||
if (hasData) {
|
||||
binding.llHeader.visibility = View.VISIBLE
|
||||
binding.dividerHeader.visibility = View.VISIBLE
|
||||
binding.rvSub.visibility = View.VISIBLE
|
||||
binding.tvEmpty.visibility = View.GONE
|
||||
} else {
|
||||
binding.llHeader.visibility = View.GONE
|
||||
binding.dividerHeader.visibility = View.GONE
|
||||
binding.rvSub.visibility = View.GONE
|
||||
binding.tvEmpty.visibility = View.VISIBLE
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import android.view.View
|
||||
import androidx.lifecycle.MediatorLiveData
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
@@ -38,9 +39,6 @@ class GjjManifestAddViewModel : BaseViewModel() {
|
||||
// 航班号
|
||||
val flightNo = MutableLiveData("")
|
||||
|
||||
// 航程
|
||||
val range = MutableLiveData("")
|
||||
|
||||
// 运单号
|
||||
val waybillNo = MutableLiveData("")
|
||||
|
||||
@@ -80,12 +78,10 @@ class GjjManifestAddViewModel : BaseViewModel() {
|
||||
fid = flight.fid.noNull()
|
||||
departure.value = flight.fdep.noNull()
|
||||
destination.value = flight.fdest.noNull()
|
||||
range.value = flight.range.noNull()
|
||||
} else {
|
||||
fid = ""
|
||||
departure.value = ""
|
||||
destination.value = ""
|
||||
range.value = ""
|
||||
showToast(it.msg.noNull("获取航班信息失败"))
|
||||
}
|
||||
}
|
||||
@@ -93,7 +89,6 @@ class GjjManifestAddViewModel : BaseViewModel() {
|
||||
fid = ""
|
||||
departure.value = ""
|
||||
destination.value = ""
|
||||
range.value = ""
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -119,6 +114,17 @@ class GjjManifestAddViewModel : BaseViewModel() {
|
||||
// 目的港
|
||||
val destination = MutableLiveData("")
|
||||
|
||||
// 航程(自动拼接:始发站-目的站)
|
||||
val range = MediatorLiveData<String>().apply {
|
||||
val update = {
|
||||
val dep = departure.value ?: ""
|
||||
val dest = destination.value ?: ""
|
||||
value = if (dep.isNotEmpty() || dest.isNotEmpty()) "$dep-$dest" else ""
|
||||
}
|
||||
addSource(departure) { update() }
|
||||
addSource(destination) { update() }
|
||||
}
|
||||
|
||||
// 品名(中)
|
||||
val goodsNameCn = MutableLiveData("")
|
||||
|
||||
@@ -154,10 +160,10 @@ class GjjManifestAddViewModel : BaseViewModel() {
|
||||
val waybillType = MutableLiveData("")
|
||||
|
||||
init {
|
||||
DictUtils.getAgentList(addAll = false) {
|
||||
DictUtils.getIntImpAgentList(addAll = false) {
|
||||
agentList.postValue(listOf(KeyValue("", "")) + it)
|
||||
}
|
||||
DictUtils.getSpecialCodeList(addAll = false, flag = 1, ieFlag = "I") {
|
||||
DictUtils.getSpecialCodeList(addAll = false, flag = 1, ieFlag = "") {
|
||||
val list = arrayListOf<KeyValue>()
|
||||
it.find { b -> b.key.contains("普通货物") }?.let { b ->
|
||||
list.add(b)
|
||||
@@ -168,7 +174,7 @@ class GjjManifestAddViewModel : BaseViewModel() {
|
||||
DictUtils.getBusinessTypeList(addAll = false) {
|
||||
businessTypeList.postValue(it)
|
||||
}
|
||||
DictUtils.getGjjPackageTypeList(addAll = false) {
|
||||
DictUtils.getShouYunPackageTypeList {
|
||||
packageTypeList.postValue(listOf(KeyValue("", "")) + it)
|
||||
}
|
||||
DictUtils.getGjjGoodsTypeList(addAll = false) {
|
||||
|
||||
@@ -110,7 +110,7 @@ class GjjManifestDetailsViewModel : BaseViewModel(), IGetData {
|
||||
DictUtils.getAgentList(addAll = false, checkedValue = data.agent) {
|
||||
agentList.postValue(it)
|
||||
}
|
||||
DictUtils.getSpecialCodeList(addAll = false, flag = 1, ieFlag = "I", checkedValue = data.spCode) {
|
||||
DictUtils.getSpecialCodeList(addAll = false, flag = 1, ieFlag = "", checkedValue = data.spCode) {
|
||||
specialCodeList.postValue(it)
|
||||
}
|
||||
DictUtils.getBusinessTypeList(
|
||||
|
||||
@@ -12,6 +12,7 @@ import com.lukouguoji.module_base.bean.GjjDeclareParam
|
||||
import com.lukouguoji.module_base.bean.GjjImportManifest
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.gjj.dialog.IntImpTallyResetDialogModel
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||
@@ -134,22 +135,25 @@ class IntArrAirManifestViewModel : BasePageViewModel() {
|
||||
fun resetStatusClick() {
|
||||
val (maWbList, haWbList) = getSelectedItems("请选择要重置的舱单") ?: return
|
||||
|
||||
val param = GjjDeclareParam(
|
||||
maWbList = maWbList,
|
||||
haWbList = haWbList,
|
||||
restStatus = null,
|
||||
resetReason = "状态重置"
|
||||
)
|
||||
val dialog = IntImpTallyResetDialogModel { dialogModel ->
|
||||
val param = GjjDeclareParam(
|
||||
maWbList = maWbList,
|
||||
haWbList = haWbList,
|
||||
restStatus = dialogModel.resetStatusCode
|
||||
)
|
||||
|
||||
launchLoadingCollect({ NetApply.api.resetIntArrManifestStatus(param.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("状态重置成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
launchLoadingCollect({ NetApply.api.resetIntArrManifestStatus(param.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("状态重置成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
}
|
||||
|
||||
dialog.show()
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -250,6 +254,19 @@ class IntArrAirManifestViewModel : BasePageViewModel() {
|
||||
launchLoadingCollect({ NetApply.api.getIntArrAirManifestList(listParams) }) {
|
||||
onSuccess = { result ->
|
||||
isAllExpanded.value = false
|
||||
// 如果接口未返回航班日期/航班号,用筛选条件填充
|
||||
val fd = flightDate.value ?: ""
|
||||
val fn = flightNo.value ?: ""
|
||||
result.list?.forEach { airManifest ->
|
||||
airManifest.maWb?.let {
|
||||
if (it.fdate.isEmpty()) it.fdate = fd
|
||||
if (it.fno.isEmpty()) it.fno = fn
|
||||
}
|
||||
airManifest.haWbList?.forEach {
|
||||
if (it.fdate.isEmpty()) it.fdate = fd
|
||||
if (it.fno.isEmpty()) it.fno = fn
|
||||
}
|
||||
}
|
||||
pageModel.handleListBean(result.toBaseListBean())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,6 +13,7 @@ import com.lukouguoji.module_base.ktx.launchCollect
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import com.lukouguoji.module_base.ktx.verifyNullOrEmpty
|
||||
import dev.utils.app.info.KeyValue
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
@@ -56,7 +57,7 @@ class IntArrSupplementInfoViewModel : BaseViewModel() {
|
||||
* 加载国家代码下拉列表
|
||||
*/
|
||||
private fun loadCountryCodeList() {
|
||||
launchCollect({ NetApply.api.getAreaTypeList() }) {
|
||||
launchCollect({ NetApply.api.getCountryCodeList() }) {
|
||||
onSuccess = { result ->
|
||||
val keyValueList = result.data?.mapNotNull { bean ->
|
||||
if (bean.code != null && bean.name != null) {
|
||||
@@ -96,6 +97,17 @@ class IntArrSupplementInfoViewModel : BaseViewModel() {
|
||||
fun save() {
|
||||
val formBean = dataBean.value ?: return
|
||||
|
||||
// 收货人必填校验
|
||||
if (formBean.consigneeName.verifyNullOrEmpty("收货人名称不能为空")) return
|
||||
if (formBean.consigneeCountryCode.verifyNullOrEmpty("收货人国家代码不能为空")) return
|
||||
if (formBean.consigneeComType.verifyNullOrEmpty("收货人通讯方式不能为空")) return
|
||||
if (formBean.consigneePNum.verifyNullOrEmpty("收货人联系号码不能为空")) return
|
||||
// 发货人必填校验
|
||||
if (formBean.consignorName.verifyNullOrEmpty("发货人名称不能为空")) return
|
||||
if (formBean.consignorCountryCode.verifyNullOrEmpty("发货人国家代码不能为空")) return
|
||||
if (formBean.consignorComType.verifyNullOrEmpty("发货人通讯方式不能为空")) return
|
||||
if (formBean.consignorPNum.verifyNullOrEmpty("发货人联系号码不能为空")) return
|
||||
|
||||
if (manifestList.isEmpty()) {
|
||||
showToast("无可保存的数据")
|
||||
return
|
||||
|
||||
@@ -0,0 +1,271 @@
|
||||
package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.LifecycleOwner
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
import com.lukouguoji.module_base.bean.FileBean
|
||||
import com.lukouguoji.module_base.bean.GjAccidentVisaEditBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.module_base.common.DetailsPageType
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.impl.ImageSelectViewHolder
|
||||
import com.lukouguoji.module_base.interfaces.IOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||
import com.lukouguoji.module_base.ktx.launchCollect
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.noNull
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import com.lukouguoji.module_base.ktx.verifyNullOrEmpty
|
||||
import com.lukouguoji.module_base.util.MediaUtil
|
||||
import com.lukouguoji.module_base.util.UploadUtil
|
||||
import dev.utils.app.info.KeyValue
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.flow.asFlow
|
||||
import kotlinx.coroutines.flow.catch
|
||||
import kotlinx.coroutines.flow.filter
|
||||
import kotlinx.coroutines.flow.flowOn
|
||||
import kotlinx.coroutines.flow.launchIn
|
||||
import kotlinx.coroutines.flow.map
|
||||
import kotlinx.coroutines.flow.onCompletion
|
||||
import kotlinx.coroutines.flow.onEach
|
||||
import kotlinx.coroutines.flow.onStart
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
class IntImpAccidentVisaEditViewModel : BaseViewModel(), IOnItemClickListener {
|
||||
|
||||
var id: Long = 0
|
||||
|
||||
val pageType = MutableLiveData(DetailsPageType.Add)
|
||||
|
||||
val dataBean = MutableLiveData(GjAccidentVisaEditBean())
|
||||
|
||||
// 图片列表
|
||||
val itemLayoutId = R.layout.item_image_select
|
||||
val itemViewHolder = ImageSelectViewHolder::class.java
|
||||
var rv: RecyclerView? = null
|
||||
|
||||
// 下拉列表
|
||||
val outerPackageList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val damageTypeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val contentTypeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val unusualTypeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val photoList = MutableLiveData(
|
||||
listOf(KeyValue("是", "是"), KeyValue("否", "否"))
|
||||
)
|
||||
|
||||
// 航班级联查询
|
||||
private var lastQueriedFlight = ""
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// 初始化
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
fun initOnCreate(intent: Intent) {
|
||||
id = intent.getLongExtra(Constant.Key.ID, 0)
|
||||
pageType.value = if (id == 0L) DetailsPageType.Add else DetailsPageType.Modify
|
||||
|
||||
loadDropdownLists()
|
||||
|
||||
if (id != 0L) {
|
||||
loadDetail()
|
||||
}
|
||||
|
||||
rv?.post {
|
||||
rv?.commonAdapter()?.addItem(FileBean())
|
||||
}
|
||||
}
|
||||
|
||||
private fun loadDropdownLists() {
|
||||
launchCollect({ NetApply.api.getPackTypeList() }) {
|
||||
onSuccess = { result ->
|
||||
outerPackageList.value = result.data?.mapNotNull { bean ->
|
||||
bean.name?.let { name -> KeyValue(name, name) }
|
||||
} ?: emptyList()
|
||||
}
|
||||
}
|
||||
launchCollect({ NetApply.api.getDamageTypeList() }) {
|
||||
onSuccess = { result ->
|
||||
damageTypeList.value = result.data?.mapNotNull { bean ->
|
||||
bean.name?.let { name -> KeyValue(name, name) }
|
||||
} ?: emptyList()
|
||||
}
|
||||
}
|
||||
launchCollect({ NetApply.api.getContentTypeList() }) {
|
||||
onSuccess = { result ->
|
||||
contentTypeList.value = result.data?.mapNotNull { bean ->
|
||||
bean.name?.let { name -> KeyValue(name, name) }
|
||||
} ?: emptyList()
|
||||
}
|
||||
}
|
||||
launchCollect({ NetApply.api.getUnusualTypeList() }) {
|
||||
onSuccess = { result ->
|
||||
unusualTypeList.value = result.data?.mapNotNull { bean ->
|
||||
bean.name?.let { name -> KeyValue(name, name) }
|
||||
} ?: emptyList()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun loadDetail() {
|
||||
launchLoadingCollect({ NetApply.api.getGjAccidentVisaDetail(id) }) {
|
||||
onSuccess = {
|
||||
dataBean.value = it.data ?: GjAccidentVisaEditBean()
|
||||
|
||||
// 渲染图片
|
||||
val bean = dataBean.value!!
|
||||
val picList = bean.pic.split(",")
|
||||
.filter { url -> url.isNotEmpty() }
|
||||
.map { url -> FileBean(MediaUtil.fillUrl(url), url) }
|
||||
val originalList = bean.originalPic.split(",")
|
||||
.filter { url -> url.isNotEmpty() }
|
||||
.map { url -> FileBean(MediaUtil.fillUrl(url)) }
|
||||
for ((index, fileBean) in picList.withIndex()) {
|
||||
if (index < originalList.size) {
|
||||
picList[index].originalPic = originalList[index].path
|
||||
}
|
||||
}
|
||||
rv?.commonAdapter()?.loadMore(picList)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// 航班级联查询
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
fun onFlightDateInputComplete() {
|
||||
lastQueriedFlight = ""
|
||||
queryFlightIfReady()
|
||||
}
|
||||
|
||||
fun onFlightNoInputComplete() {
|
||||
queryFlightIfReady()
|
||||
}
|
||||
|
||||
private fun queryFlightIfReady() {
|
||||
val bean = dataBean.value ?: return
|
||||
val fdate = bean.fdate
|
||||
val fno = bean.fno
|
||||
if (fdate.isEmpty() || fno.isEmpty()) return
|
||||
|
||||
val key = "$fdate-$fno"
|
||||
if (key == lastQueriedFlight) return
|
||||
lastQueriedFlight = key
|
||||
|
||||
launchCollect({
|
||||
NetApply.api.getGjFlightBean(
|
||||
mapOf(
|
||||
"fdate" to fdate,
|
||||
"fno" to fno,
|
||||
"ieFlag" to "I",
|
||||
).toRequestBody()
|
||||
)
|
||||
}) {
|
||||
onSuccess = {
|
||||
if (it.verifySuccess() && it.data != null) {
|
||||
val flight = it.data!!
|
||||
val b = dataBean.value ?: GjAccidentVisaEditBean()
|
||||
b.dep = flight.fdep.noNull()
|
||||
b.dest = flight.fdest.noNull()
|
||||
dataBean.value = b
|
||||
} else {
|
||||
val b = dataBean.value ?: GjAccidentVisaEditBean()
|
||||
b.dep = ""
|
||||
b.dest = ""
|
||||
dataBean.value = b
|
||||
showToast(it.msg.noNull("获取航班信息失败"))
|
||||
}
|
||||
}
|
||||
|
||||
onFailed = { _, _ ->
|
||||
val b = dataBean.value ?: GjAccidentVisaEditBean()
|
||||
b.dep = ""
|
||||
b.dest = ""
|
||||
dataBean.value = b
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// 保存
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
fun onSaveClick() {
|
||||
val bean = dataBean.value ?: return
|
||||
if (bean.fdate.verifyNullOrEmpty("请输入航班日期")) return
|
||||
if (bean.fno.verifyNullOrEmpty("请输入航班号")) return
|
||||
if (bean.wbNo.verifyNullOrEmpty("请输入运单号")) return
|
||||
|
||||
(rv?.commonAdapter()?.items ?: emptyList())
|
||||
.asFlow()
|
||||
.map { it as FileBean }
|
||||
.filter { it.path.isNotEmpty() && it.url.isEmpty() }
|
||||
.onEach {
|
||||
val data = UploadUtil.upload(it.path).data
|
||||
it.url = data?.newName ?: ""
|
||||
it.originalPic = data?.zipFileName ?: ""
|
||||
}
|
||||
.flowOn(Dispatchers.IO)
|
||||
.onStart { showLoading() }
|
||||
.catch {
|
||||
showToast(it.message.noNull("上传图片失败"))
|
||||
dismissLoading()
|
||||
}
|
||||
.onCompletion {
|
||||
launchLoadingCollect({
|
||||
val list = (rv?.commonAdapter()?.items as List<FileBean>)
|
||||
.filter { it.path.isNotEmpty() }
|
||||
bean.picNumber = list.size.toString()
|
||||
bean.originalPic = list.joinToString(separator = ",") { MediaUtil.removeUrl(it.url) }
|
||||
bean.pic = list.joinToString(separator = ",") { MediaUtil.removeUrl(it.originalPic) }
|
||||
bean.idFlag = "1"
|
||||
|
||||
if (pageType.value == DetailsPageType.Add) {
|
||||
NetApply.api.saveGjAccidentVisa(bean.toRequestBody())
|
||||
} else {
|
||||
NetApply.api.modifyGjAccidentVisa(bean.toRequestBody())
|
||||
}
|
||||
}) {
|
||||
onSuccess = {
|
||||
showToast(it.msg.noNull("${pageType.value!!.title}成功"))
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
getTopActivity().finish()
|
||||
}
|
||||
}
|
||||
}
|
||||
.launchIn(viewModelScope)
|
||||
}
|
||||
|
||||
fun onCancelClick() {
|
||||
getTopActivity().finish()
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
// 图片操作
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
override fun onItemClick(position: Int, type: Int) {
|
||||
val adapter = rv!!.commonAdapter()!!
|
||||
val bean = adapter.getItem(position) as FileBean
|
||||
when (type) {
|
||||
R.id.rl -> {
|
||||
bean.canDelete.set(!bean.canDelete.get())
|
||||
}
|
||||
|
||||
R.id.iv_delete -> {
|
||||
adapter.removeItem(position)
|
||||
}
|
||||
|
||||
else -> {}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -123,6 +123,10 @@ class IntImpAccidentVisaViewModel : BasePageViewModel() {
|
||||
ScanModel.startScan(getTopActivity(), Constant.RequestCode.WAYBILL)
|
||||
}
|
||||
|
||||
fun addClick() {
|
||||
com.lukouguoji.gjj.activity.IntImpAccidentVisaEditActivity.start(getTopActivity())
|
||||
}
|
||||
|
||||
fun searchClick() {
|
||||
refresh()
|
||||
}
|
||||
|
||||
@@ -496,19 +496,13 @@ class IntImpManifestViewModel : BasePageViewModel() {
|
||||
* 加载主单下的分单列表(按需加载,加载完成后自动展开)
|
||||
*/
|
||||
private fun loadHaWbList(bean: GjjManifest) {
|
||||
val params = mapOf(
|
||||
"mfId" to bean.mfId
|
||||
).toRequestBody()
|
||||
val params = bean.toRequestBody()
|
||||
|
||||
launchLoadingCollect({ NetApply.api.getIntImpManifestHaWbList(params) }) {
|
||||
onSuccess = { result ->
|
||||
if (result.verifySuccess() && !result.data.isNullOrEmpty()) {
|
||||
bean.haWbList = result.data
|
||||
bean.showMore.set(true)
|
||||
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||
} else {
|
||||
showToast("暂无分单数据")
|
||||
}
|
||||
bean.haWbList = result.data ?: emptyList()
|
||||
bean.showMore.set(true)
|
||||
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,133 @@
|
||||
package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import androidx.lifecycle.Observer
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import com.google.gson.Gson
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
/**
|
||||
* 国际进港费用修改 ViewModel
|
||||
*/
|
||||
class IntImpPickUpChargeEditViewModel : BaseViewModel() {
|
||||
|
||||
val dataBean = MutableLiveData(IntImpPickUpRecordBean())
|
||||
|
||||
// 可编辑费用字段(String 用于双向绑定)
|
||||
val tranChargeStr = MutableLiveData("") // 信息费
|
||||
val whsChargeStr = MutableLiveData("") // 仓储费
|
||||
val drawBillChargeStr = MutableLiveData("") // 文件处理费
|
||||
val svlChargeStr = MutableLiveData("") // 叉车费
|
||||
val tallyChargeStr = MutableLiveData("") // 理货费
|
||||
val pipFeeStr = MutableLiveData("") // 精密仪器处理费
|
||||
val lapFeeStr = MutableLiveData("") // 活体动物处理费
|
||||
val totalAmountStr = MutableLiveData("") // 总费用(实时计算)
|
||||
|
||||
// 总费用计算观察者
|
||||
private val totalCalculator = Observer<String> { calculateTotal() }
|
||||
|
||||
private fun calculateTotal() {
|
||||
val total = (tranChargeStr.value?.toDoubleOrNull() ?: 0.0) +
|
||||
(whsChargeStr.value?.toDoubleOrNull() ?: 0.0) +
|
||||
(drawBillChargeStr.value?.toDoubleOrNull() ?: 0.0) +
|
||||
(svlChargeStr.value?.toDoubleOrNull() ?: 0.0) +
|
||||
(tallyChargeStr.value?.toDoubleOrNull() ?: 0.0) +
|
||||
(dataBean.value?.optCharge ?: 0.0) +
|
||||
(pipFeeStr.value?.toDoubleOrNull() ?: 0.0) +
|
||||
(lapFeeStr.value?.toDoubleOrNull() ?: 0.0)
|
||||
totalAmountStr.value = if (total != 0.0) total.toString() else ""
|
||||
}
|
||||
|
||||
fun initOnCreated(intent: Intent) {
|
||||
val jsonData = intent.getStringExtra(Constant.Key.DATA) ?: ""
|
||||
if (jsonData.isNotEmpty()) {
|
||||
try {
|
||||
val bean = Gson().fromJson(jsonData, IntImpPickUpRecordBean::class.java)
|
||||
dataBean.value = bean
|
||||
// 初始化可编辑费用字段
|
||||
tranChargeStr.value = if (bean.tranCharge != 0.0) bean.tranCharge.toString() else ""
|
||||
whsChargeStr.value = if (bean.whsCharge != 0.0) bean.whsCharge.toString() else ""
|
||||
drawBillChargeStr.value = if (bean.drawBillCharge != 0.0) bean.drawBillCharge.toString() else ""
|
||||
svlChargeStr.value = if (bean.svlCharge != 0.0) bean.svlCharge.toString() else ""
|
||||
tallyChargeStr.value = if (bean.tallyCharge != 0.0) bean.tallyCharge.toString() else ""
|
||||
pipFeeStr.value = if (bean.pipFee != 0.0) bean.pipFee.toString() else ""
|
||||
lapFeeStr.value = if (bean.lapFee != 0.0) bean.lapFee.toString() else ""
|
||||
|
||||
// 注册总费用实时计算
|
||||
tranChargeStr.observeForever(totalCalculator)
|
||||
whsChargeStr.observeForever(totalCalculator)
|
||||
drawBillChargeStr.observeForever(totalCalculator)
|
||||
svlChargeStr.observeForever(totalCalculator)
|
||||
tallyChargeStr.observeForever(totalCalculator)
|
||||
pipFeeStr.observeForever(totalCalculator)
|
||||
lapFeeStr.observeForever(totalCalculator)
|
||||
|
||||
// 初始计算一次
|
||||
calculateTotal()
|
||||
} catch (e: Exception) {
|
||||
showToast("数据解析失败")
|
||||
getTopActivity().finish()
|
||||
}
|
||||
} else {
|
||||
showToast("未接收到数据")
|
||||
getTopActivity().finish()
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存修改
|
||||
*/
|
||||
fun submit() {
|
||||
val bean = dataBean.value ?: return
|
||||
|
||||
// 同步可编辑费用字段回 bean
|
||||
bean.tranCharge = tranChargeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.whsCharge = whsChargeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.drawBillCharge = drawBillChargeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.svlCharge = svlChargeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.tallyCharge = tallyChargeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.pipFee = pipFeeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.lapFee = lapFeeStr.value?.toDoubleOrNull() ?: 0.0
|
||||
bean.amount = totalAmountStr.value?.toDoubleOrNull() ?: 0.0
|
||||
|
||||
launchLoadingCollect({
|
||||
NetApply.api.modifyIntImpPickUpCharge(bean.toRequestBody())
|
||||
}) {
|
||||
onSuccess = {
|
||||
showToast("修改成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
getTopActivity().finish()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消
|
||||
*/
|
||||
fun cancel() {
|
||||
getTopActivity().finish()
|
||||
}
|
||||
|
||||
override fun onCleared() {
|
||||
super.onCleared()
|
||||
tranChargeStr.removeObserver(totalCalculator)
|
||||
whsChargeStr.removeObserver(totalCalculator)
|
||||
drawBillChargeStr.removeObserver(totalCalculator)
|
||||
svlChargeStr.removeObserver(totalCalculator)
|
||||
tallyChargeStr.removeObserver(totalCalculator)
|
||||
pipFeeStr.removeObserver(totalCalculator)
|
||||
lapFeeStr.removeObserver(totalCalculator)
|
||||
}
|
||||
}
|
||||
@@ -16,9 +16,12 @@ import com.lukouguoji.module_base.ktx.commonAdapter
|
||||
import com.lukouguoji.module_base.ktx.launchCollect
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.formatDate
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import com.lukouguoji.module_base.model.ConfirmDialogModel
|
||||
import com.lukouguoji.module_base.model.ScanModel
|
||||
import dev.utils.app.info.KeyValue
|
||||
import dev.utils.common.DateUtils
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
/**
|
||||
@@ -27,7 +30,7 @@ import kotlinx.coroutines.launch
|
||||
class IntImpPickUpDLVViewModel : BasePageViewModel() {
|
||||
|
||||
// ========== 搜索条件 ==========
|
||||
val paymentDateStart = MutableLiveData("") // 缴费日期起
|
||||
val paymentDateStart = MutableLiveData(DateUtils.getCurrentTime().formatDate()) // 缴费日期起
|
||||
val paymentDateEnd = MutableLiveData("") // 缴费日期止
|
||||
val agentCode = MutableLiveData("") // 代理人
|
||||
val wbNo = MutableLiveData("") // 运单号
|
||||
@@ -116,15 +119,20 @@ class IntImpPickUpDLVViewModel : BasePageViewModel() {
|
||||
return
|
||||
}
|
||||
|
||||
launchLoadingCollect({ NetApply.api.confirmIntImpPickUpDLV(selectedItems.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("确认出库成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
ConfirmDialogModel(
|
||||
message = "确定要将选中的${selectedItems.size}条记录确认出库吗?",
|
||||
title = "确认出库"
|
||||
) {
|
||||
launchLoadingCollect({ NetApply.api.confirmIntImpPickUpDLV(selectedItems.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("确认出库成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
}
|
||||
}.show()
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -2,41 +2,26 @@ package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.google.gson.Gson
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
|
||||
/**
|
||||
* 国际进港提取详情 ViewModel
|
||||
*/
|
||||
class IntImpPickUpRecordDetailsViewModel : BaseViewModel() {
|
||||
|
||||
var recordId: Long = 0
|
||||
|
||||
val dataBean = MutableLiveData(IntImpPickUpRecordBean())
|
||||
|
||||
fun initOnCreated(intent: Intent) {
|
||||
recordId = intent.getLongExtra(Constant.Key.ID, 0)
|
||||
if (recordId > 0) {
|
||||
getData()
|
||||
val json = intent.getStringExtra(Constant.Key.DATA) ?: ""
|
||||
if (json.isNotEmpty()) {
|
||||
dataBean.value = Gson().fromJson(json, IntImpPickUpRecordBean::class.java)
|
||||
} else {
|
||||
showToast("参数错误")
|
||||
getTopActivity().finish()
|
||||
}
|
||||
}
|
||||
|
||||
private fun getData() {
|
||||
val params = mapOf("id" to recordId).toRequestBody()
|
||||
launchLoadingCollect({
|
||||
NetApply.api.getIntImpPickUpRecordDetails(params)
|
||||
}) {
|
||||
onSuccess = {
|
||||
dataBean.value = it.data ?: IntImpPickUpRecordBean()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,8 +18,10 @@ import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.noNull
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import com.lukouguoji.module_base.ktx.formatDate
|
||||
import com.lukouguoji.module_base.model.ScanModel
|
||||
import com.lukouguoji.module_base.util.DictUtils
|
||||
import dev.utils.common.DateUtils
|
||||
import dev.utils.app.info.KeyValue
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
@@ -29,7 +31,7 @@ import kotlinx.coroutines.launch
|
||||
class IntImpPickUpRecordViewModel : BasePageViewModel() {
|
||||
|
||||
// ========== 筛选条件 ==========
|
||||
val paymentDateStart = MutableLiveData("") // 缴费日期起
|
||||
val paymentDateStart = MutableLiveData(DateUtils.getCurrentTime().formatDate()) // 缴费日期起
|
||||
val paymentDateEnd = MutableLiveData("") // 缴费日期止
|
||||
val agentCode = MutableLiveData("") // 代理人
|
||||
val spCode = MutableLiveData("") // 特码
|
||||
@@ -81,7 +83,7 @@ class IntImpPickUpRecordViewModel : BasePageViewModel() {
|
||||
fun initSpecialCodeList() {
|
||||
DictUtils.getSpecialCodeList(
|
||||
flag = 1, // 国际
|
||||
ieFlag = "I", // 进港
|
||||
ieFlag = "",
|
||||
parentcode = ""
|
||||
) {
|
||||
spCodeList.value = it
|
||||
@@ -144,16 +146,16 @@ class IntImpPickUpRecordViewModel : BasePageViewModel() {
|
||||
*/
|
||||
override fun getData() {
|
||||
val filterParams = mapOf(
|
||||
"paymentDateStart" to paymentDateStart.value?.ifEmpty { null },
|
||||
"paymentDateEnd" to paymentDateEnd.value?.ifEmpty { null },
|
||||
"beginDate" to paymentDateStart.value?.ifEmpty { null },
|
||||
"endDate" to paymentDateEnd.value?.ifEmpty { null },
|
||||
"agentCode" to agentCode.value?.ifEmpty { null },
|
||||
"spCode" to spCode.value?.ifEmpty { null },
|
||||
"wbNo" to wbNo.value?.ifEmpty { null }
|
||||
)
|
||||
|
||||
val listParams = (filterParams + mapOf(
|
||||
"pageNum" to pageModel.page,
|
||||
"pageSize" to pageModel.limit
|
||||
"page" to pageModel.page,
|
||||
"limit" to pageModel.limit
|
||||
)).toRequestBody()
|
||||
|
||||
val totalParams = filterParams.toRequestBody()
|
||||
|
||||
@@ -0,0 +1,124 @@
|
||||
package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.lukouguoji.gjj.fragment.IntImpQueryStorageFragment
|
||||
import com.lukouguoji.gjj.fragment.IntImpQueryWarehouseFragment
|
||||
import com.lukouguoji.gjj.fragment.IntImpQueryWaybillFragment
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
|
||||
/**
|
||||
* 国际进港查询详情-ViewModel
|
||||
*/
|
||||
class IntImpQueryDetailsViewModel : BaseViewModel() {
|
||||
|
||||
// ==================== 基础数据 ====================
|
||||
var prefix: String = "" // 运单号前缀
|
||||
var no: String = "" // 运单号主体
|
||||
|
||||
// ==================== Tab管理 ====================
|
||||
val currentTab = MutableLiveData(0) // 当前Tab索引 (0/1/2)
|
||||
|
||||
// ==================== 详情数据 ====================
|
||||
val detailData = MutableLiveData<Map<String, Any>>(emptyMap())
|
||||
|
||||
// 运单信息 (maWb)
|
||||
val maWbData = MutableLiveData<Map<String, Any>>(emptyMap())
|
||||
|
||||
// 仓库列表 (warehouseList)
|
||||
val warehouseList = MutableLiveData<List<Map<String, Any>>>(emptyList())
|
||||
|
||||
// 库位列表 (storageUseList)
|
||||
val storageUseList = MutableLiveData<List<Map<String, Any>>>(emptyList())
|
||||
|
||||
// ==================== Fragment列表 ====================
|
||||
val fragmentList by lazy {
|
||||
listOf(
|
||||
IntImpQueryWaybillFragment.newInstance(this), // 运单信息
|
||||
IntImpQueryWarehouseFragment.newInstance(this), // 仓库信息
|
||||
IntImpQueryStorageFragment.newInstance(this) // 库位信息
|
||||
)
|
||||
}
|
||||
|
||||
// ==================== 方法区 ====================
|
||||
|
||||
/**
|
||||
* 初始化(从Intent获取maWbId)
|
||||
*/
|
||||
fun initOnCreated(intent: Intent) {
|
||||
prefix = intent.getStringExtra("prefix") ?: ""
|
||||
no = intent.getStringExtra("no") ?: ""
|
||||
}
|
||||
|
||||
/**
|
||||
* Tab点击事件
|
||||
*/
|
||||
fun onTabClick(index: Int) {
|
||||
currentTab.value = index
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载详情数据
|
||||
*/
|
||||
fun loadDetails() {
|
||||
if (prefix.isEmpty() || no.isEmpty()) {
|
||||
showToast("运单号参数为空")
|
||||
return
|
||||
}
|
||||
|
||||
val params = mapOf("prefix" to prefix, "no" to no).toRequestBody()
|
||||
|
||||
launchLoadingCollect({ NetApply.api.getIntImpQueryDetails(params) }) {
|
||||
onSuccess = { result ->
|
||||
val data = result.data ?: emptyMap()
|
||||
detailData.value = data
|
||||
|
||||
// 解析 maWb 对象
|
||||
@Suppress("UNCHECKED_CAST")
|
||||
val maWb = data["maWb"] as? Map<String, Any> ?: emptyMap()
|
||||
|
||||
// 合并数据并添加组合字段
|
||||
val mergedData = mutableMapOf<String, Any>()
|
||||
mergedData.putAll(maWb)
|
||||
|
||||
// 添加组合字段: wbNo = prefix + no
|
||||
val prefix = maWb["prefix"] as? String ?: ""
|
||||
val no = maWb["no"] as? String ?: ""
|
||||
if (prefix.isNotEmpty() || no.isNotEmpty()) {
|
||||
mergedData["wbNo"] = "$prefix$no"
|
||||
}
|
||||
|
||||
// 锁定状态转中文
|
||||
val lockState = maWb["lockState"]
|
||||
if (lockState != null) {
|
||||
val lockStateInt = when (lockState) {
|
||||
is Double -> lockState.toInt()
|
||||
is Int -> lockState
|
||||
else -> null
|
||||
}
|
||||
mergedData["lockStateText"] = when (lockStateInt) {
|
||||
0 -> "未锁定"
|
||||
1 -> "已锁定"
|
||||
else -> ""
|
||||
}
|
||||
}
|
||||
|
||||
maWbData.value = mergedData
|
||||
|
||||
// 解析 warehouseList 列表
|
||||
@Suppress("UNCHECKED_CAST")
|
||||
val whList = data["warehouseList"] as? List<Map<String, Any>> ?: emptyList()
|
||||
warehouseList.value = whList
|
||||
|
||||
// 解析 storageUseList 列表
|
||||
@Suppress("UNCHECKED_CAST")
|
||||
val suList = data["storageUseList"] as? List<Map<String, Any>> ?: emptyList()
|
||||
storageUseList.value = suList
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,368 @@
|
||||
package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import com.google.gson.Gson
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
import com.lukouguoji.module_base.bean.IntImpQueryEditBean
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.impl.FlowBus
|
||||
import com.lukouguoji.module_base.ktx.launchCollect
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import dev.utils.app.info.KeyValue
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
/**
|
||||
* 国际进港运单修改 ViewModel
|
||||
*/
|
||||
class IntImpQueryEditViewModel : BaseViewModel() {
|
||||
|
||||
// 数据Bean
|
||||
val dataBean = MutableLiveData(IntImpQueryEditBean())
|
||||
|
||||
// 运单标识
|
||||
var maWbId: Long = 0
|
||||
var prefix: String = ""
|
||||
var no: String = ""
|
||||
|
||||
// ==================== 下拉列表 ====================
|
||||
val agentList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val spCodeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val packageTypeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val waybillTypeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
val lockStateList = MutableLiveData(
|
||||
listOf(
|
||||
KeyValue("未锁", "0"),
|
||||
KeyValue("锁定", "1")
|
||||
)
|
||||
)
|
||||
|
||||
/**
|
||||
* 初始化数据
|
||||
*/
|
||||
fun initOnCreated(intent: Intent) {
|
||||
maWbId = intent.getLongExtra("maWbId", 0L)
|
||||
prefix = intent.getStringExtra("prefix") ?: ""
|
||||
no = intent.getStringExtra("no") ?: ""
|
||||
|
||||
if (prefix.isEmpty() || no.isEmpty()) {
|
||||
showToast("运单号参数为空")
|
||||
getTopActivity().finish()
|
||||
return
|
||||
}
|
||||
|
||||
// 加载下拉列表
|
||||
loadAgentList()
|
||||
loadSpCodeList()
|
||||
loadPackageTypeList()
|
||||
loadWaybillTypeList()
|
||||
|
||||
// 加载详情
|
||||
loadDetails()
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载代理人下拉列表
|
||||
*/
|
||||
private fun loadAgentList() {
|
||||
launchCollect({ NetApply.api.getIntImpAgentList() }) {
|
||||
onSuccess = { result ->
|
||||
val list = result.data?.mapNotNull { bean ->
|
||||
if (bean.name != null && bean.code != null) {
|
||||
KeyValue(bean.name, bean.code)
|
||||
} else null
|
||||
} ?: emptyList()
|
||||
agentList.value = list
|
||||
// 详情已加载时匹配代理人
|
||||
matchAgent()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载特码下拉列表
|
||||
* flag=1(国际), ieFlag=I(进港)
|
||||
*/
|
||||
private fun loadSpCodeList() {
|
||||
launchCollect({ NetApply.api.getSpecialCodeList(1, "", "") }) {
|
||||
onSuccess = { result ->
|
||||
val list = result.data?.mapNotNull { bean ->
|
||||
if (bean.name != null && bean.code != null) {
|
||||
KeyValue(bean.name, bean.code)
|
||||
} else null
|
||||
} ?: emptyList()
|
||||
spCodeList.value = list
|
||||
matchSpCode()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载包装类型下拉列表(国际进港专用)
|
||||
*/
|
||||
private fun loadPackageTypeList() {
|
||||
launchCollect({ NetApply.api.getGjjPackTypeList() }) {
|
||||
onSuccess = { result ->
|
||||
val list = result.data?.mapNotNull { bean ->
|
||||
if (bean.packageName.isNotEmpty()) {
|
||||
KeyValue(bean.packageName, bean.packageName)
|
||||
} else null
|
||||
} ?: emptyList()
|
||||
packageTypeList.value = list
|
||||
matchPackageType()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载运单类型下拉列表
|
||||
* type=II(国际进港)
|
||||
*/
|
||||
private fun loadWaybillTypeList() {
|
||||
launchCollect({ NetApply.api.getWaybillTypeList("II") }) {
|
||||
onSuccess = { result ->
|
||||
val list = result.data?.mapNotNull { bean ->
|
||||
if (bean.name != null && bean.code != null) {
|
||||
KeyValue(bean.name, bean.code)
|
||||
} else null
|
||||
} ?: emptyList()
|
||||
waybillTypeList.value = list
|
||||
matchWaybillType()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载运单详情数据
|
||||
*/
|
||||
private fun loadDetails() {
|
||||
val params = mapOf("prefix" to prefix, "no" to no).toRequestBody()
|
||||
|
||||
launchLoadingCollect({ NetApply.api.getIntImpQueryDetails(params) }) {
|
||||
onSuccess = { result ->
|
||||
val data = result.data ?: emptyMap()
|
||||
|
||||
// 提取 maWb 对象
|
||||
val maWb = data["maWb"] as? Map<String, Any> ?: emptyMap()
|
||||
// 提取 maWbM 对象
|
||||
val maWbM = data["maWbM"] as? Map<String, Any> ?: emptyMap()
|
||||
// 提取 warehouseList(用于计算入库件数和入库重量)
|
||||
val warehouseList = data["warehouseList"] as? List<Map<String, Any>> ?: emptyList()
|
||||
|
||||
// 合并数据
|
||||
val mergedData = mutableMapOf<String, Any>()
|
||||
mergedData.putAll(maWb)
|
||||
mergedData.putAll(maWbM)
|
||||
|
||||
// 运单号: 组合 prefix + no
|
||||
val prefix = maWb["prefix"] as? String ?: ""
|
||||
val no = maWb["no"] as? String ?: ""
|
||||
if (prefix.isNotEmpty() && no.isNotEmpty()) {
|
||||
mergedData["wbNo"] = "$prefix$no"
|
||||
}
|
||||
|
||||
// 代理人名称
|
||||
if (!mergedData.containsKey("agentName") || (mergedData["agentName"] as? String).isNullOrEmpty()) {
|
||||
maWb["agentCode"]?.let { mergedData["agentName"] = it }
|
||||
}
|
||||
|
||||
// 运单件数/重量映射
|
||||
val pc = maWb["pc"]
|
||||
when (pc) {
|
||||
is Number -> mergedData["awbPc"] = pc.toLong()
|
||||
is String -> mergedData["awbPc"] = pc.toLongOrNull() ?: 0L
|
||||
}
|
||||
val weight = maWb["weight"]
|
||||
when (weight) {
|
||||
is Number -> mergedData["awbWeight"] = weight.toDouble()
|
||||
is String -> mergedData["awbWeight"] = weight.toDoubleOrNull() ?: 0.0
|
||||
}
|
||||
|
||||
// 入库件数和入库重量: 从 warehouseList 计算总和
|
||||
if (warehouseList.isNotEmpty()) {
|
||||
var totalPc = 0L
|
||||
var totalWeight = 0.0
|
||||
warehouseList.forEach { warehouse ->
|
||||
val wPc = warehouse["pc"]
|
||||
when (wPc) {
|
||||
is Number -> totalPc += wPc.toLong()
|
||||
is String -> totalPc += wPc.toLongOrNull() ?: 0L
|
||||
}
|
||||
val wWeight = warehouse["weight"]
|
||||
when (wWeight) {
|
||||
is Number -> totalWeight += wWeight.toDouble()
|
||||
is String -> totalWeight += wWeight.toDoubleOrNull() ?: 0.0
|
||||
}
|
||||
}
|
||||
mergedData["inPc"] = totalPc
|
||||
mergedData["inWeight"] = totalWeight
|
||||
}
|
||||
|
||||
// lockState 转换为 String(SPINNER 绑定用)
|
||||
val lockState = mergedData["lockState"]
|
||||
when (lockState) {
|
||||
is Number -> mergedData["lockState"] = lockState.toInt().toString()
|
||||
is String -> mergedData["lockState"] = lockState
|
||||
}
|
||||
|
||||
// 转换为 Bean
|
||||
val bean = Gson().fromJson(Gson().toJson(mergedData), IntImpQueryEditBean::class.java)
|
||||
|
||||
// 匹配下拉列表
|
||||
matchAgent(bean)
|
||||
matchSpCode(bean)
|
||||
matchPackageType(bean)
|
||||
matchWaybillType(bean)
|
||||
matchLockState(bean)
|
||||
|
||||
dataBean.value = bean
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 匹配代理人
|
||||
*/
|
||||
private fun matchAgent(bean: IntImpQueryEditBean? = dataBean.value) {
|
||||
bean ?: return
|
||||
val currentCode = bean.agentCode
|
||||
if (currentCode.isNullOrEmpty()) return
|
||||
|
||||
val list = agentList.value ?: return
|
||||
if (list.isEmpty()) return
|
||||
|
||||
val match = list.find { it.value == currentCode }
|
||||
if (match != null) {
|
||||
bean.agentName = match.key
|
||||
bean.agentCode = match.value
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 匹配特码
|
||||
*/
|
||||
private fun matchSpCode(bean: IntImpQueryEditBean? = dataBean.value) {
|
||||
bean ?: return
|
||||
val currentCode = bean.spCode
|
||||
if (currentCode.isNullOrEmpty()) return
|
||||
|
||||
val list = spCodeList.value ?: return
|
||||
if (list.isEmpty()) return
|
||||
|
||||
val match = list.find { it.value == currentCode }
|
||||
if (match != null) {
|
||||
bean.spCode = match.value
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 匹配包装类型
|
||||
*/
|
||||
private fun matchPackageType(bean: IntImpQueryEditBean? = dataBean.value) {
|
||||
bean ?: return
|
||||
val currentType = bean.packageType
|
||||
if (currentType.isNullOrEmpty()) return
|
||||
|
||||
val list = packageTypeList.value ?: return
|
||||
if (list.isEmpty()) return
|
||||
|
||||
val match = list.find { it.value?.contains(currentType) == true }
|
||||
if (match != null) {
|
||||
bean.packageType = match.value
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 匹配运单类型
|
||||
*/
|
||||
private fun matchWaybillType(bean: IntImpQueryEditBean? = dataBean.value) {
|
||||
bean ?: return
|
||||
val currentCode = bean.awbType
|
||||
if (currentCode.isNullOrEmpty()) return
|
||||
|
||||
val list = waybillTypeList.value ?: return
|
||||
if (list.isEmpty()) return
|
||||
|
||||
val match = list.find { it.value == currentCode }
|
||||
if (match != null) {
|
||||
bean.awbType = match.value
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 匹配锁定状态
|
||||
*/
|
||||
private fun matchLockState(bean: IntImpQueryEditBean? = dataBean.value) {
|
||||
bean ?: return
|
||||
val currentState = bean.lockState
|
||||
if (currentState.isNullOrEmpty()) return
|
||||
|
||||
val list = lockStateList.value ?: return
|
||||
val match = list.find { it.value == currentState }
|
||||
if (match != null) {
|
||||
bean.lockState = match.value
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 保存修改
|
||||
*/
|
||||
fun submit() {
|
||||
val bean = dataBean.value ?: return
|
||||
|
||||
// 构建提交数据(只提交需要的字段)
|
||||
val submitData = mutableMapOf<String, Any?>()
|
||||
submitData["maWbId"] = if (maWbId != 0L) maWbId else bean.maWbId
|
||||
submitData["activeId"] = bean.activeId
|
||||
submitData["prefix"] = bean.prefix
|
||||
submitData["no"] = bean.no
|
||||
submitData["wbNo"] = bean.wbNo
|
||||
submitData["agentCode"] = bean.agentCode
|
||||
submitData["spCode"] = bean.spCode
|
||||
submitData["packageType"] = bean.packageType
|
||||
submitData["awbType"] = bean.awbType
|
||||
submitData["lockState"] = bean.lockState?.toIntOrNull()
|
||||
submitData["remark"] = bean.remark
|
||||
submitData["fno"] = bean.fno
|
||||
submitData["fdate"] = bean.fdate
|
||||
submitData["flight"] = bean.flight
|
||||
submitData["pc"] = bean.pc
|
||||
submitData["weight"] = bean.weight
|
||||
submitData["volume"] = bean.volume
|
||||
submitData["origin"] = bean.origin
|
||||
submitData["dest"] = bean.dest
|
||||
submitData["range"] = bean.range
|
||||
submitData["goods"] = bean.goods
|
||||
submitData["goodsCn"] = bean.goodsCn
|
||||
submitData["cargoType"] = bean.cargoType
|
||||
submitData["by1"] = bean.by1
|
||||
submitData["subCode"] = bean.subCode
|
||||
submitData["cashWeight"] = bean.cashWeight
|
||||
submitData["unNumber"] = bean.unNumber
|
||||
submitData["businessType"] = bean.businessType
|
||||
submitData["carId"] = bean.carId
|
||||
|
||||
launchLoadingCollect({
|
||||
NetApply.api.modifyIntImpMaWb(submitData.toRequestBody())
|
||||
}) {
|
||||
onSuccess = {
|
||||
showToast("修改成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
getTopActivity().finish()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消
|
||||
*/
|
||||
fun cancel() {
|
||||
getTopActivity().finish()
|
||||
}
|
||||
}
|
||||
@@ -4,16 +4,22 @@ import android.app.Activity
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.activity.IntImpQueryEditActivity
|
||||
import com.lukouguoji.gjj.dialog.IntImpQueryFilterDialogModel
|
||||
import com.lukouguoji.gjj.holder.IntImpQueryViewHolder
|
||||
import com.lukouguoji.gjj.activity.IntImpQueryDetailsActivity
|
||||
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||
import com.lukouguoji.module_base.bean.IntImpQueryBean
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.http.net.NetApply
|
||||
import com.lukouguoji.module_base.interfaces.IOnItemClickListener
|
||||
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||
import com.lukouguoji.module_base.ktx.launchCollect
|
||||
import com.lukouguoji.module_base.ktx.launchLoadingCollect
|
||||
import com.lukouguoji.module_base.ktx.showToast
|
||||
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||
import com.lukouguoji.module_base.model.ScanModel
|
||||
import com.lukouguoji.module_base.util.DictUtils
|
||||
import dev.utils.app.info.KeyValue
|
||||
import dev.utils.common.DateUtils
|
||||
import com.lukouguoji.module_base.ktx.formatDate
|
||||
@@ -21,7 +27,7 @@ import com.lukouguoji.module_base.ktx.formatDate
|
||||
/**
|
||||
* 国际进港查询ViewModel
|
||||
*/
|
||||
class IntImpQueryViewModel : BasePageViewModel() {
|
||||
class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
|
||||
// ==================== 搜索条件 ====================
|
||||
val flightDateStart = MutableLiveData<String>(DateUtils.getCurrentTime().formatDate())
|
||||
@@ -50,6 +56,9 @@ class IntImpQueryViewModel : BasePageViewModel() {
|
||||
val totalPc = MutableLiveData("0")
|
||||
val totalWeight = MutableLiveData("0")
|
||||
|
||||
// ==================== 特码下拉 ====================
|
||||
val spCodeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
|
||||
// ==================== 筛选条件 ====================
|
||||
val spCode = MutableLiveData("")
|
||||
val flightNo = MutableLiveData("")
|
||||
@@ -73,6 +82,7 @@ class IntImpQueryViewModel : BasePageViewModel() {
|
||||
fun filterClick() {
|
||||
val filterDialog = IntImpQueryFilterDialogModel(
|
||||
spCode = spCode,
|
||||
spCodeList = spCodeList,
|
||||
flightNo = flightNo,
|
||||
dest = dest,
|
||||
awbType = awbType,
|
||||
@@ -85,8 +95,8 @@ class IntImpQueryViewModel : BasePageViewModel() {
|
||||
|
||||
override fun getData() {
|
||||
val listParams = mapOf(
|
||||
"pageNum" to pageModel.page,
|
||||
"pageSize" to pageModel.limit,
|
||||
"page" to pageModel.page,
|
||||
"limit" to pageModel.limit,
|
||||
"beginDate" to flightDateStart.value!!.ifEmpty { null },
|
||||
"endDate" to flightDateEnd.value!!.ifEmpty { null },
|
||||
"agentCode" to agentId.value!!.ifEmpty { null },
|
||||
@@ -145,6 +155,32 @@ class IntImpQueryViewModel : BasePageViewModel() {
|
||||
}
|
||||
}
|
||||
|
||||
override fun onItemClick(position: Int, type: Int) {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpQueryBean> ?: return
|
||||
val bean = list.getOrNull(position) ?: return
|
||||
|
||||
when (type) {
|
||||
2000 -> {
|
||||
// 侧滑菜单 - 修改操作
|
||||
IntImpQueryEditActivity.start(getTopActivity(), bean.maWbId, bean.prefix, bean.no)
|
||||
}
|
||||
else -> {
|
||||
// 默认点击 - 进入详情
|
||||
IntImpQueryDetailsActivity.start(getTopActivity(), bean.prefix, bean.no)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun initSpecialCodeList() {
|
||||
DictUtils.getSpecialCodeList(
|
||||
flag = 1,
|
||||
ieFlag = "",
|
||||
parentcode = ""
|
||||
) {
|
||||
spCodeList.value = it
|
||||
}
|
||||
}
|
||||
|
||||
fun initAgentList() {
|
||||
launchCollect({
|
||||
NetApply.api.getIntImpAgentList()
|
||||
|
||||
@@ -124,12 +124,9 @@ class IntImpStorageUseViewModel : BasePageViewModel() {
|
||||
return
|
||||
}
|
||||
|
||||
val params = mapOf(
|
||||
"clearNormal" to clearNormal,
|
||||
"maWbList" to maWbListForClear
|
||||
).toRequestBody()
|
||||
val body = maWbListForClear.toRequestBody()
|
||||
|
||||
launchLoadingCollect({ NetApply.api.clearIntImpStorage(params) }) {
|
||||
launchLoadingCollect({ NetApply.api.clearIntImpStorage(clearNormal, body) }) {
|
||||
onSuccess = {
|
||||
showToast("清仓成功")
|
||||
viewModelScope.launch {
|
||||
@@ -188,13 +185,13 @@ class IntImpStorageUseViewModel : BasePageViewModel() {
|
||||
/**
|
||||
* 执行出库操作
|
||||
*/
|
||||
fun performOutStorage(selectedStorageList: List<com.lukouguoji.module_base.bean.GjcStorageUse>) {
|
||||
if (selectedStorageList.isEmpty()) {
|
||||
fun performOutStorage(maWbListForOutStorage: List<GjcMaWb>) {
|
||||
if (maWbListForOutStorage.isEmpty()) {
|
||||
showToast("请选择要出库的库位")
|
||||
return
|
||||
}
|
||||
|
||||
val params = selectedStorageList.toRequestBody()
|
||||
val params = maWbListForOutStorage.toRequestBody()
|
||||
|
||||
launchLoadingCollect({ NetApply.api.outIntImpStorage(params) }) {
|
||||
onSuccess = {
|
||||
@@ -232,13 +229,9 @@ class IntImpStorageUseViewModel : BasePageViewModel() {
|
||||
return
|
||||
}
|
||||
|
||||
val params = mapOf(
|
||||
"location" to locationName,
|
||||
"locationId" to locationId.toLongOrNull(),
|
||||
"maWbList" to maWbListForInStorage
|
||||
).toRequestBody()
|
||||
val body = maWbListForInStorage.toRequestBody()
|
||||
|
||||
launchLoadingCollect({ NetApply.api.inIntImpStorage(params) }) {
|
||||
launchLoadingCollect({ NetApply.api.inIntImpStorage(locationName, body) }) {
|
||||
onSuccess = {
|
||||
showToast("入库成功")
|
||||
viewModelScope.launch {
|
||||
@@ -257,7 +250,8 @@ class IntImpStorageUseViewModel : BasePageViewModel() {
|
||||
"fdate" to flightDate.value?.ifEmpty { null },
|
||||
"fno" to flightNo.value?.ifEmpty { null },
|
||||
"wbNo" to wbNo.value?.ifEmpty { null },
|
||||
"location" to location.value?.ifEmpty { null }
|
||||
"location" to location.value?.ifEmpty { null },
|
||||
"clearNormal" to clearResult.value?.ifEmpty { null }
|
||||
)
|
||||
|
||||
val listParams = (filterParams + mapOf(
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.lukouguoji.gjj.viewModel
|
||||
|
||||
import android.content.Intent
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.lukouguoji.module_base.base.BaseViewModel
|
||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
|
||||
/**
|
||||
* 国际进港理货报告详情 ViewModel
|
||||
*/
|
||||
class IntImpTallyDetailsViewModel : BaseViewModel() {
|
||||
|
||||
// 理货数据
|
||||
val dataBean = MutableLiveData(GjjImportTally())
|
||||
|
||||
/**
|
||||
* 初始化数据(从列表项携带的数据)
|
||||
*/
|
||||
fun initOnCreated(intent: Intent) {
|
||||
val tally = intent.getSerializableExtra(Constant.Key.DATA) as? GjjImportTally
|
||||
if (tally != null) {
|
||||
dataBean.value = tally
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,10 +3,13 @@ package com.lukouguoji.gjj.viewModel
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import com.lukouguoji.gjj.R
|
||||
import com.lukouguoji.gjj.dialog.IntImpTallyDeleteDialogModel
|
||||
import com.lukouguoji.gjj.dialog.IntImpTallyResetDialogModel
|
||||
import dev.utils.common.DateUtils
|
||||
import com.lukouguoji.module_base.ktx.formatDate
|
||||
import com.lukouguoji.gjj.holder.IntImpTallyViewHolder
|
||||
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||
import com.lukouguoji.module_base.bean.GjjDeclareParam
|
||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||
import com.lukouguoji.module_base.common.Constant
|
||||
import com.lukouguoji.module_base.common.ConstantEvent
|
||||
@@ -40,10 +43,13 @@ class IntImpTallyViewModel : BasePageViewModel() {
|
||||
val isAllChecked = MutableLiveData(false)
|
||||
|
||||
init {
|
||||
// 监听全选状态,自动更新所有列表项
|
||||
// 监听全选状态,自动更新所有列表项(联动子列表)
|
||||
isAllChecked.observeForever { checked ->
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally> ?: return@observeForever
|
||||
list.forEach { it.checked.set(checked) }
|
||||
list.forEach {
|
||||
it.checked.set(checked)
|
||||
it.haWbList?.forEach { sub -> sub.checked.set(checked) }
|
||||
}
|
||||
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||
}
|
||||
}
|
||||
@@ -65,9 +71,12 @@ class IntImpTallyViewModel : BasePageViewModel() {
|
||||
fun checkAllClick() {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally> ?: return
|
||||
|
||||
// 切换全选状态
|
||||
// 切换全选状态(联动子列表)
|
||||
val shouldCheckAll = !isAllChecked.value!!
|
||||
list.forEach { it.checked.set(shouldCheckAll) }
|
||||
list.forEach {
|
||||
it.checked.set(shouldCheckAll)
|
||||
it.haWbList?.forEach { sub -> sub.checked.set(shouldCheckAll) }
|
||||
}
|
||||
isAllChecked.value = shouldCheckAll
|
||||
|
||||
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||
@@ -88,63 +97,158 @@ class IntImpTallyViewModel : BasePageViewModel() {
|
||||
}
|
||||
|
||||
/**
|
||||
* 人工放行(暂不实现)
|
||||
* 收集选中的主单和分单
|
||||
*/
|
||||
private fun getSelectedData(): Pair<List<GjjImportTally>, List<GjjImportTally>> {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally>
|
||||
?: return Pair(emptyList(), emptyList())
|
||||
val selectedMaWb = list.filter { it.isSelected }
|
||||
val selectedHaWb = mutableListOf<GjjImportTally>()
|
||||
list.forEach { maWb ->
|
||||
maWb.haWbList?.forEach { haWb ->
|
||||
if (haWb.isSelected) selectedHaWb.add(haWb)
|
||||
}
|
||||
}
|
||||
return Pair(selectedMaWb, selectedHaWb)
|
||||
}
|
||||
|
||||
/**
|
||||
* 人工放行
|
||||
*/
|
||||
fun manualReleaseClick() {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally> ?: return
|
||||
val selectedItems = list.filter { it.isSelected }
|
||||
val (selectedMaWb, selectedHaWb) = getSelectedData()
|
||||
|
||||
if (selectedItems.isEmpty()) {
|
||||
if (selectedMaWb.isEmpty() && selectedHaWb.isEmpty()) {
|
||||
showToast("请选择要放行的记录")
|
||||
return
|
||||
}
|
||||
|
||||
showToast("人工放行功能开发中")
|
||||
val param = GjjDeclareParam(
|
||||
mtallyList = if (selectedMaWb.isNotEmpty()) selectedMaWb else null,
|
||||
htallyList = if (selectedHaWb.isNotEmpty()) selectedHaWb else null
|
||||
)
|
||||
|
||||
launchLoadingCollect({ NetApply.api.intImpTallyCustomCommand(param.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("人工放行成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 状态重置(暂不实现)
|
||||
* 状态重置
|
||||
*/
|
||||
fun statusResetClick() {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally> ?: return
|
||||
val selectedItems = list.filter { it.isSelected }
|
||||
val (selectedMaWb, selectedHaWb) = getSelectedData()
|
||||
|
||||
if (selectedItems.isEmpty()) {
|
||||
if (selectedMaWb.isEmpty() && selectedHaWb.isEmpty()) {
|
||||
showToast("请选择要重置的记录")
|
||||
return
|
||||
}
|
||||
|
||||
showToast("状态重置功能开发中")
|
||||
val dialog = IntImpTallyResetDialogModel { dialogModel ->
|
||||
val param = GjjDeclareParam(
|
||||
mtallyList = if (selectedMaWb.isNotEmpty()) selectedMaWb else null,
|
||||
htallyList = if (selectedHaWb.isNotEmpty()) selectedHaWb else null,
|
||||
restStatus = dialogModel.resetStatusCode
|
||||
)
|
||||
|
||||
launchLoadingCollect({ NetApply.api.intImpTallyResetDeclare(param.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("状态重置成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dialog.show()
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除理货(暂不实现)
|
||||
* 删除理货
|
||||
*/
|
||||
fun deleteTallyClick() {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally> ?: return
|
||||
val selectedItems = list.filter { it.isSelected }
|
||||
val (selectedMaWb, selectedHaWb) = getSelectedData()
|
||||
|
||||
if (selectedItems.isEmpty()) {
|
||||
if (selectedMaWb.isEmpty() && selectedHaWb.isEmpty()) {
|
||||
showToast("请选择要删除的记录")
|
||||
return
|
||||
}
|
||||
|
||||
showToast("删除理货功能开发中")
|
||||
// 校验所选单据状态是否为 01(已申报)
|
||||
val invalidMaWb = selectedMaWb.firstOrNull { it.status != "01" }
|
||||
if (invalidMaWb != null) {
|
||||
showToast("运单 ${invalidMaWb.getWaybillNo()} 理货未申报,不允许删除理货")
|
||||
return
|
||||
}
|
||||
val invalidHaWb = selectedHaWb.firstOrNull { it.status != "01" }
|
||||
if (invalidHaWb != null) {
|
||||
showToast("运单 ${invalidHaWb.getWaybillNo()} 理货未申报,不允许删除理货")
|
||||
return
|
||||
}
|
||||
|
||||
// 从接口获取删除原因列表
|
||||
launchLoadingCollect({ NetApply.api.getDelReasonList() }) {
|
||||
onSuccess = { result ->
|
||||
val changeReasonList = result.data?.map { it.toKeyValue() } ?: emptyList()
|
||||
|
||||
val dialog = IntImpTallyDeleteDialogModel(changeReasonList) { dialogModel ->
|
||||
val param = GjjDeclareParam(
|
||||
dcode = dialogModel.changeReason.value ?: "",
|
||||
dcontactsName = dialogModel.contactName.value ?: "",
|
||||
dcontactsTel = dialogModel.contactPhone.value ?: "",
|
||||
mtallyList = if (selectedMaWb.isNotEmpty()) selectedMaWb else null,
|
||||
htallyList = if (selectedHaWb.isNotEmpty()) selectedHaWb else null
|
||||
)
|
||||
|
||||
launchLoadingCollect({ NetApply.api.intImpTallyDeleteDeclare(param.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("删除申报成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dialog.show()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 理货申报(暂不实现)
|
||||
* 理货申报
|
||||
*/
|
||||
fun tallyDeclareClick() {
|
||||
val list = pageModel.rv?.commonAdapter()?.items as? List<GjjImportTally> ?: return
|
||||
val selectedItems = list.filter { it.isSelected }
|
||||
val (selectedMaWb, selectedHaWb) = getSelectedData()
|
||||
|
||||
if (selectedItems.isEmpty()) {
|
||||
if (selectedMaWb.isEmpty() && selectedHaWb.isEmpty()) {
|
||||
showToast("请选择要申报的记录")
|
||||
return
|
||||
}
|
||||
|
||||
showToast("理货申报功能开发中")
|
||||
val param = GjjDeclareParam(
|
||||
mtallyList = if (selectedMaWb.isNotEmpty()) selectedMaWb else null,
|
||||
htallyList = if (selectedHaWb.isNotEmpty()) selectedHaWb else null
|
||||
)
|
||||
|
||||
launchLoadingCollect({ NetApply.api.intImpTallyDeclare(param.toRequestBody()) }) {
|
||||
onSuccess = {
|
||||
showToast("理货申报成功")
|
||||
viewModelScope.launch {
|
||||
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||
}
|
||||
refresh()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -79,13 +79,13 @@
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{viewModel.pageType == DetailsPageType.Add}"
|
||||
hint='@{"请输入航程"}'
|
||||
enable="@{false}"
|
||||
hint='@{"自动填充"}'
|
||||
required="@{false}"
|
||||
title='@{"航 程"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.range}'
|
||||
value='@{viewModel.range}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="15dp"
|
||||
|
||||
@@ -61,10 +61,10 @@
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"特码"}'
|
||||
title='@{"航班信息"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.spCode}'
|
||||
value='@{viewModel.dataBean.getFlightSplit()}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
@@ -59,6 +59,7 @@
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入名称"}'
|
||||
required="@{true}"
|
||||
title='@{"名称"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
@@ -71,6 +72,7 @@
|
||||
enable="@{true}"
|
||||
hint='@{"请选择国家代码"}'
|
||||
list="@{viewModel.countryCodeList}"
|
||||
required="@{true}"
|
||||
title='@{"国家代码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
@@ -83,6 +85,7 @@
|
||||
enable="@{true}"
|
||||
hint='@{"请选择通讯方式"}'
|
||||
list="@{viewModel.comTypeList}"
|
||||
required="@{true}"
|
||||
title='@{"通讯方式"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
@@ -103,6 +106,7 @@
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入联系号码"}'
|
||||
required="@{true}"
|
||||
title='@{"联系号码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
@@ -154,6 +158,7 @@
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入名称"}'
|
||||
required="@{true}"
|
||||
title='@{"名称"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
@@ -166,6 +171,7 @@
|
||||
enable="@{true}"
|
||||
hint='@{"请选择国家代码"}'
|
||||
list="@{viewModel.countryCodeList}"
|
||||
required="@{true}"
|
||||
title='@{"国家代码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
@@ -178,6 +184,7 @@
|
||||
enable="@{true}"
|
||||
hint='@{"请选择通讯方式"}'
|
||||
list="@{viewModel.comTypeList}"
|
||||
required="@{true}"
|
||||
title='@{"通讯方式"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
@@ -198,6 +205,7 @@
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入联系号码"}'
|
||||
required="@{true}"
|
||||
title='@{"联系号码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
|
||||
@@ -99,18 +99,18 @@
|
||||
android:src="@drawable/img_search" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:padding="2dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.addClick()}"
|
||||
android:src="@drawable/img_add" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_marginStart="8dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.deleteClick()}"
|
||||
android:padding="2dp"
|
||||
android:padding="4dp"
|
||||
android:src="@drawable/img_delete" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -0,0 +1,363 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout 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">
|
||||
|
||||
<data>
|
||||
|
||||
<import type="com.lukouguoji.module_base.ui.weight.data.layout.DataLayoutType" />
|
||||
|
||||
<import type="com.lukouguoji.module_base.common.DetailsPageType" />
|
||||
|
||||
<variable
|
||||
name="viewModel"
|
||||
type="com.lukouguoji.gjj.viewModel.IntImpAccidentVisaEditViewModel" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/color_f2"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/title_tool_bar" />
|
||||
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- Row 1: 航班日期 | 航班号 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择航班日期"}'
|
||||
setRefreshCallBack="@{viewModel::onFlightDateInputComplete}"
|
||||
title='@{"航班日期"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.DATE}"
|
||||
value='@={viewModel.dataBean.fdate}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入航班号"}'
|
||||
setRefreshCallBack="@{viewModel::onFlightNoInputComplete}"
|
||||
title='@{"航班号"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.fno}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 2: 始发站 | 目的站 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"始发站"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.dep}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"目的站"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.dest}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 3: 运单号 | 不正常件数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入运单号"}'
|
||||
title='@{"运单号"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.wbNo}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入不正常件数"}'
|
||||
title='@{"不正常件数"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.dpc}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 4: 运单总件数 | 运单总重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入运单总件数"}'
|
||||
title='@{"运单总件数"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.pc}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入运单总重量"}'
|
||||
title='@{"运单总重量"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.weight}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 5: 复称重量 | 品名 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入复称重量"}'
|
||||
title='@{"复称重量"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.reweight}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入品名"}'
|
||||
title='@{"品名"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.goods}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 6: 外包装 | 包装破损情况 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请选择外包装"}'
|
||||
list="@{viewModel.outerPackageList}"
|
||||
title='@{"外包装"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.opacking}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请选择破损情况"}'
|
||||
list="@{viewModel.damageTypeList}"
|
||||
title='@{"包装破损情况"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.damage}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 7: 内容物情况 | 不正常类型 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请选择内容物情况"}'
|
||||
list="@{viewModel.contentTypeList}"
|
||||
title='@{"内容物情况"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.condition}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请选择不正常类型"}'
|
||||
list="@{viewModel.unusualTypeList}"
|
||||
title='@{"不正常类型"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.problem}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 8: 发现时间 | 图片是否留底 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择发现时间"}'
|
||||
title='@{"发现时间"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.DATE}"
|
||||
value='@={viewModel.dataBean.seachDate}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请选择"}'
|
||||
list="@{viewModel.photoList}"
|
||||
title='@{"图片是否留底"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.photo}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Row 9: 备注(整行) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入备注"}'
|
||||
inputHeight="@{80}"
|
||||
title='@{"备注"}'
|
||||
titleLength="@{6}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.remarks}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 上传图像区域 -->
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="15dp"
|
||||
android:text="上传图像"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv"
|
||||
itemLayoutId="@{viewModel.itemLayoutId}"
|
||||
viewHolder="@{viewModel.itemViewHolder}"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
app:layoutManager="androidx.recyclerview.widget.GridLayoutManager"
|
||||
app:spanCount="4"
|
||||
tools:listitem="@layout/item_image_select" />
|
||||
|
||||
<!-- 底部按钮 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginBottom="15dp"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:layout_width="120dp"
|
||||
android:onClick="@{()-> viewModel.onCancelClick()}"
|
||||
android:text="取消" />
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:layout_width="120dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:onClick="@{()-> viewModel.onSaveClick()}"
|
||||
android:text="保存" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
@@ -109,11 +109,10 @@
|
||||
|
||||
<!-- 新增按钮 -->
|
||||
<ImageView
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginLeft="16dp"
|
||||
android:onClick="@{()-> viewModel.onAddClick()}"
|
||||
android:padding="4dp"
|
||||
android:src="@drawable/img_add" />
|
||||
|
||||
<!-- 删除按钮 -->
|
||||
|
||||
@@ -0,0 +1,314 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
|
||||
<import type="com.lukouguoji.module_base.ui.weight.data.layout.DataLayoutType" />
|
||||
|
||||
<variable
|
||||
name="viewModel"
|
||||
type="com.lukouguoji.gjj.viewModel.IntImpPickUpChargeEditViewModel" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/color_f2"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<include layout="@layout/title_tool_bar" />
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:fillViewport="true">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- 第1行:运单号、代理人、特码(只读) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运 单 号"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.wbNo}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"代 理 人"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.agentCode}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"特 码"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.spCode}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第2行:提货编号、件数、重量(只读) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"提货编号"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.pkId}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"件数"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.pc)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"重量"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.weight)}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第3行:计费重量(只读)、信息费(可编辑)、服务费(只读) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"计费重量"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.cashWeight)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入信息费"}'
|
||||
title='@{"信息费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.tranChargeStr}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"服务费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.optCharge)}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第4行:仓储费、文件处理费、叉车费(可编辑) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入仓储费"}'
|
||||
title='@{"仓储费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.whsChargeStr}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入文件处理费"}'
|
||||
title='@{"文件处理费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.drawBillChargeStr}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入叉车费"}'
|
||||
title='@{"叉车费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.svlChargeStr}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第5行:理货费、精密仪器处理费、活体动物处理费(可编辑) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入理货费"}'
|
||||
title='@{"理货费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.tallyChargeStr}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入精密仪器处理费"}'
|
||||
title='@{"精密仪器处理费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.pipFeeStr}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入活体动物处理费"}'
|
||||
title='@{"活体动物处理费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.lapFeeStr}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第6行:总费用(只读,实时计算) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"总费用"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.totalAmountStr}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:visibility="invisible"
|
||||
enable="@{false}"
|
||||
title='@{""}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{""}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:visibility="invisible"
|
||||
enable="@{false}"
|
||||
title='@{""}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{""}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 底部操作按钮 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="56dp"
|
||||
android:layout_marginTop="24dp"
|
||||
android:gravity="center"
|
||||
android:paddingHorizontal="15dp">
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:layout_width="120dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:onClick="@{()-> viewModel.cancel()}"
|
||||
android:text="取消" />
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:layout_width="120dp"
|
||||
android:onClick="@{()-> viewModel.submit()}"
|
||||
android:text="保存" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
@@ -61,6 +61,12 @@
|
||||
|
||||
<!-- 运单号 -->
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
autoQueryEnabled="@{true}"
|
||||
autoQueryMaxLength="@{8}"
|
||||
autoQueryMinLength="@{4}"
|
||||
autoQueryParamKey="@{`wbNo`}"
|
||||
autoQueryTitle="@{`选择运单号`}"
|
||||
autoQueryUrl="@{`/IntImpPickUpDlv/queryWbNoList`}"
|
||||
hint='@{"请输入运单号"}'
|
||||
icon="@{@drawable/img_scan}"
|
||||
setOnIconClickListener="@{(v)-> viewModel.scanWbNo()}"
|
||||
@@ -159,7 +165,7 @@
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text='@{"合计:" + viewModel.totalCount + "票"}'
|
||||
android:text='@{"合计:" + viewModel.totalCount + "票"}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
@@ -168,7 +174,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:text='@{"总件数:" + viewModel.totalPc}'
|
||||
android:text='@{"总件数:" + viewModel.totalPc}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
@@ -177,7 +183,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:text='@{"总重量:" + viewModel.totalWeight}'
|
||||
android:text='@{"总重量:" + viewModel.totalWeight}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
@@ -75,6 +75,13 @@
|
||||
|
||||
<!-- 运单号 -->
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
android:id="@+id/pslWbNo"
|
||||
autoQueryEnabled="@{true}"
|
||||
autoQueryMaxLength="@{8}"
|
||||
autoQueryMinLength="@{4}"
|
||||
autoQueryParamKey="@{`wbNo`}"
|
||||
autoQueryTitle="@{`选择运单号`}"
|
||||
autoQueryUrl="@{`/IntImpPickup/queryWbNoList`}"
|
||||
hint='@{"请输入运单号"}'
|
||||
icon="@{@drawable/img_scan}"
|
||||
setOnIconClickListener="@{(v)-> viewModel.scanWbNo()}"
|
||||
@@ -162,7 +169,7 @@
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text='@{"合计:" + viewModel.totalCount + "票"}'
|
||||
android:text='@{"合计:" + viewModel.totalCount + "票"}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
@@ -171,7 +178,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:text='@{"总件数:" + viewModel.totalPc}'
|
||||
android:text='@{"总件数:" + viewModel.totalPc}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
@@ -180,7 +187,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:text='@{"总重量:" + viewModel.totalWeight}'
|
||||
android:text='@{"总重量:" + viewModel.totalWeight}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
@@ -41,34 +41,34 @@
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单号"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.wbNo}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{viewModel.dataBean.wbNo}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"代理人"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.agentCode}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{viewModel.dataBean.agentCode}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"特码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.spCode}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"特码"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.spCode}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -80,34 +80,34 @@
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"提货编号"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.pickUpNo}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{viewModel.dataBean.pkId}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"件数"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.pc)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{String.valueOf(viewModel.dataBean.pc)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.weight)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"重量"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.weight)}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -119,38 +119,38 @@
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"计费重量"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.checkWeight)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{String.valueOf(viewModel.dataBean.cashWeight)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"信息费"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.infoFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{String.valueOf(viewModel.dataBean.tranCharge)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"服务费"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.serviceFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{String.valueOf(viewModel.dataBean.optCharge)}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第4行:仓储费、抽单费、冷藏费 -->
|
||||
<!-- 第4行:仓储费、文件处理费、叉车费 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -158,38 +158,38 @@
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"仓储费"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.storageFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{String.valueOf(viewModel.dataBean.whsCharge)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"抽单费"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.drawFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"文件处理费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.drawBillCharge)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"冷藏费"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.coldFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"叉车费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.svlCharge)}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第5行:铲车费、理货费、总金额 -->
|
||||
<!-- 第5行:理货费、精密仪器处理费、活体动物处理费 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -197,38 +197,38 @@
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"铲车费"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.forkliftFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"理货费"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.tallyFee)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{String.valueOf(viewModel.dataBean.tallyCharge)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"总金额"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.totalAmount)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"精密仪器处理费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.pipFee)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"活体动物处理费"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.lapFee)}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第6行:提取时间、办理人、出库时间 -->
|
||||
<!-- 第6行:总费用、提取时间、办理人 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -236,34 +236,75 @@
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"总费用"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.amount)}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"提取时间"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.pickUpTime}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{viewModel.dataBean.chargeTime}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"办理人"}'
|
||||
titleLength="@{5}"
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.operator}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
value='@{viewModel.dataBean.chargeName}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第7行:出库时间 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"出库时间"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.outTime}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"出库时间"}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.dlvTime}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:visibility="invisible"
|
||||
enable="@{false}"
|
||||
title='@{""}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{""}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:visibility="invisible"
|
||||
enable="@{false}"
|
||||
title='@{""}'
|
||||
titleLength="@{7}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{""}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
@@ -78,7 +78,13 @@
|
||||
icon="@{@drawable/img_scan}"
|
||||
setOnIconClickListener="@{()-> viewModel.waybillScanClick()}"
|
||||
type="@{SearchLayoutType.INPUT}"
|
||||
value="@={viewModel.waybillNo}" />
|
||||
value="@={viewModel.waybillNo}"
|
||||
autoQueryEnabled="@{true}"
|
||||
autoQueryUrl="@{`/IntImpSearch/queryWbNoList`}"
|
||||
autoQueryParamKey="@{`wbNo`}"
|
||||
autoQueryMinLength="@{4}"
|
||||
autoQueryMaxLength="@{8}"
|
||||
autoQueryTitle="@{`选择运单号`}" />
|
||||
|
||||
<!-- 搜索和筛选按钮 -->
|
||||
<LinearLayout
|
||||
|
||||
@@ -0,0 +1,124 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<data>
|
||||
|
||||
<import type="android.view.View" />
|
||||
|
||||
<variable
|
||||
name="viewModel"
|
||||
type="com.lukouguoji.gjj.viewModel.IntImpQueryDetailsViewModel" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/color_f2"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<include layout="@layout/title_tool_bar" />
|
||||
|
||||
<!-- Tab栏 (自定义,文字Tab + 底线) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginHorizontal="15dp"
|
||||
android:layout_marginTop="15dp"
|
||||
android:background="@drawable/bg_white_radius_top_8"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<!-- Tab1: 运单信息 -->
|
||||
<LinearLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:onClick="@{()->viewModel.onTabClick(0)}"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="运单信息"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@{viewModel.currentTab == 0 ? @color/colorPrimary : @color/text_gray}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<View
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="3dp"
|
||||
android:background="@{viewModel.currentTab == 0 ? @color/colorPrimary : @color/transparent}"
|
||||
android:visibility="@{viewModel.currentTab == 0 ? View.VISIBLE : View.INVISIBLE}" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Tab2: 仓库信息 -->
|
||||
<LinearLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:onClick="@{()->viewModel.onTabClick(1)}"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="仓库信息"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@{viewModel.currentTab == 1 ? @color/colorPrimary : @color/text_gray}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<View
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="3dp"
|
||||
android:background="@{viewModel.currentTab == 1 ? @color/colorPrimary : @color/transparent}"
|
||||
android:visibility="@{viewModel.currentTab == 1 ? View.VISIBLE : View.INVISIBLE}" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Tab3: 库位信息 -->
|
||||
<LinearLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center"
|
||||
android:onClick="@{()->viewModel.onTabClick(2)}"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="库位信息"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@{viewModel.currentTab == 2 ? @color/colorPrimary : @color/text_gray}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<View
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="3dp"
|
||||
android:background="@{viewModel.currentTab == 2 ? @color/colorPrimary : @color/transparent}"
|
||||
android:visibility="@{viewModel.currentTab == 2 ? View.VISIBLE : View.INVISIBLE}" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.material.divider.MaterialDivider
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginStart="15dp"
|
||||
android:layout_marginEnd="23dp"
|
||||
android:background="@color/color_f2" />
|
||||
|
||||
<!-- ViewPager2 -->
|
||||
<androidx.viewpager2.widget.ViewPager2
|
||||
android:id="@+id/vp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
326
module_gjj/src/main/res/layout/activity_int_imp_query_edit.xml
Normal file
326
module_gjj/src/main/res/layout/activity_int_imp_query_edit.xml
Normal file
@@ -0,0 +1,326 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout 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">
|
||||
|
||||
<data>
|
||||
<import type="com.lukouguoji.module_base.ui.weight.data.layout.DataLayoutType" />
|
||||
|
||||
<variable
|
||||
name="viewModel"
|
||||
type="com.lukouguoji.gjj.viewModel.IntImpQueryEditViewModel" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/color_f2"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<include layout="@layout/title_tool_bar" />
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:fillViewport="true">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- 第1行:运单号(禁用)| 代理人(SPINNER)| 特码(SPINNER)-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单号"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.wbNo}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择代理人"}'
|
||||
list="@{viewModel.agentList}"
|
||||
title='@{"代理人"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.agentCode}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择特码"}'
|
||||
list="@{viewModel.spCodeList}"
|
||||
title='@{"特码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.spCode}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第2行:运单件数(禁用)| 运单重量(禁用)| 业务类型(禁用)-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单件数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.awbPc != null ? String.valueOf(viewModel.dataBean.awbPc) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.awbWeight != null ? String.valueOf(viewModel.dataBean.awbWeight) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"业务类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.businessName}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第3行:入库件数(禁用)| 入库重量(禁用)| 计费重量(禁用)-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"入库件数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.inPc != null ? String.valueOf(viewModel.dataBean.inPc) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"入库重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.inWeight != null ? String.valueOf(viewModel.dataBean.inWeight) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"计费重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.cashWeight != null ? String.valueOf(viewModel.dataBean.cashWeight) : ``}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第4行:承运人(禁用)| 航程(禁用)| 包装类型(SPINNER)-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"承运人"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.by1}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"航程"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.range}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择包装类型"}'
|
||||
list="@{viewModel.packageTypeList}"
|
||||
title='@{"包装类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.packageType}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第5行:品名(中)(禁用)| 品名(英)(禁用)| UN编号(禁用)-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"品名(中)"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.goodsCn}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"品名(英)"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.goods}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"UN编号"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.unNumber}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第6行:运单类型(SPINNER)| 锁定状态(SPINNER)-->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择运单类型"}'
|
||||
list="@{viewModel.waybillTypeList}"
|
||||
title='@{"运单类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.awbType}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{true}"
|
||||
hint='@{"请选择锁定状态"}'
|
||||
list="@{viewModel.lockStateList}"
|
||||
title='@{"锁定状态"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.dataBean.lockState}' />
|
||||
|
||||
<Space
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第7行:备注(多行输入) -->
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
enable="@{true}"
|
||||
hint='@{"请输入备注"}'
|
||||
inputHeight="@{80}"
|
||||
title='@{"备注"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.dataBean.remark}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 底部操作按钮 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="56dp"
|
||||
android:layout_marginTop="24dp"
|
||||
android:gravity="center"
|
||||
android:paddingHorizontal="15dp">
|
||||
|
||||
<!-- 取消按钮 -->
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:layout_width="120dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:onClick="@{()-> viewModel.cancel()}"
|
||||
android:text="取消" />
|
||||
|
||||
<!-- 保存按钮 -->
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:layout_width="120dp"
|
||||
android:onClick="@{()-> viewModel.submit()}"
|
||||
android:text="保存" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
@@ -72,7 +72,7 @@
|
||||
autoQueryMinLength="@{4}"
|
||||
autoQueryParamKey="@{`wbNo`}"
|
||||
autoQueryTitle="@{`选择运单号`}"
|
||||
autoQueryUrl="@{`/IntImpStorageUse/queryWbNoList`}"
|
||||
autoQueryUrl="@{`/IntImpStorage/queryWbNoList`}"
|
||||
hint='@{"请输入运单号"}'
|
||||
icon="@{@drawable/img_scan}"
|
||||
setOnIconClickListener="@{(v)-> viewModel.scanWbNo()}"
|
||||
|
||||
@@ -51,6 +51,11 @@
|
||||
|
||||
<!-- 运单号 -->
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
autoQueryEnabled="@{true}"
|
||||
autoQueryMinLength="@{4}"
|
||||
autoQueryParamKey='@{"wbNo"}'
|
||||
autoQueryTitle='@{"选择运单号"}'
|
||||
autoQueryUrl='@{"/IntImpTally/queryWbNoList"}'
|
||||
hint='@{"请输入运单号"}'
|
||||
icon="@{@drawable/img_scan}"
|
||||
setOnIconClickListener="@{(v)-> viewModel.scanWaybill()}"
|
||||
|
||||
@@ -0,0 +1,359 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
|
||||
<import type="com.lukouguoji.module_base.ui.weight.data.layout.DataLayoutType" />
|
||||
|
||||
<variable
|
||||
name="viewModel"
|
||||
type="com.lukouguoji.gjj.viewModel.IntImpTallyDetailsViewModel" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/color_f2"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<include layout="@layout/title_tool_bar" />
|
||||
|
||||
<!-- 内容区域 -->
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:padding="10dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 收货人信息卡片 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- 段落标题:基础信息 -->
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="基础信息"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<!-- 第1行:运单号、代理、特码 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"运单号"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.getWaybillNo()}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"代理"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.agentName}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"航班信息"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.getFlightSplit()}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第2行:始发港、目的港、件数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"始发港"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.origin}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"目的港"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.dest}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"件数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.pc)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第3行:重量、品名(中)、品名(英) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.weight)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"品名(中)"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.goodsCn}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"品名(英)"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.goodsEn}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第4行:运单类型、申报费率、申报次数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"运单类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.awbTypeName}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"申报费率"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.tallySRate)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"申报次数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.tallySCount)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第5行:删除次数、删除费率、申报状态 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"删除次数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.tallyDCount)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"删除费率"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{String.valueOf(viewModel.dataBean.tallyDRate)}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"申报状态"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.status}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第6行:报文编号(全宽) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"报文编号"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.msgId}'
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第7行:报文回执(全宽,多行) -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
inputHeight="@{60}"
|
||||
title='@{"报文回执"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.response}'
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 海关放行指令卡片 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- 段落标题:海关放行指令 -->
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="海关放行指令"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<!-- 放行模式、放行时间、指令类型、备注 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"放行模式"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.relMode}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"放行时间"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.perDate}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"指令类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.comType}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
enable="@{false}"
|
||||
title='@{"放行备注"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.dataBean.relRemark}'
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -42,10 +42,11 @@
|
||||
|
||||
<!-- 特码 -->
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
hint='@{"请输入特码"}'
|
||||
hint='@{"请选择特码"}'
|
||||
list="@{model.spCodeList}"
|
||||
title='@{"特码"}'
|
||||
titleLength="@{4}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={model.spCode}'
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
138
module_gjj/src/main/res/layout/dialog_int_imp_tally_delete.xml
Normal file
138
module_gjj/src/main/res/layout/dialog_int_imp_tally_delete.xml
Normal file
@@ -0,0 +1,138 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
<import type="com.lukouguoji.module_base.ui.weight.search.layout.SearchLayoutType"/>
|
||||
|
||||
<variable
|
||||
name="model"
|
||||
type="com.lukouguoji.gjj.dialog.IntImpTallyDeleteDialogModel" />
|
||||
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="600dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_dialog_f2_radius_10"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:background="@drawable/bg_primary_radius_top_10"
|
||||
android:gravity="center"
|
||||
android:text="删除原因"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<!-- 表单内容 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="30dp"
|
||||
android:layout_marginTop="30dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 变更原因 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="变更原因:"
|
||||
completeSpace="@{6}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
type="@{SearchLayoutType.SPINNER}"
|
||||
list="@{model.changeReasonList}"
|
||||
value="@={model.changeReason}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 联系人姓名 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="联系人姓名:"
|
||||
completeSpace="@{6}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请输入联系人姓名"}'
|
||||
type="@{SearchLayoutType.INPUT}"
|
||||
value="@={model.contactName}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 联系人电话 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="联系人电话:"
|
||||
completeSpace="@{6}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请输入联系人电话"}'
|
||||
type="@{SearchLayoutType.INPUT}"
|
||||
value="@={model.contactPhone}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 底部按钮 -->
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="40dp"
|
||||
android:layout_marginBottom="20dp">
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:onClick="@{()->model.dismiss()}"
|
||||
android:text="取消" />
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:onClick="@{()->model.onConfirmClick()}"
|
||||
android:text="保存" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -0,0 +1,87 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
<import type="com.lukouguoji.module_base.ui.weight.search.layout.SearchLayoutType"/>
|
||||
|
||||
<variable
|
||||
name="model"
|
||||
type="com.lukouguoji.gjj.dialog.IntImpTallyResetDialogModel" />
|
||||
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="600dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_dialog_f2_radius_10"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 标题栏 -->
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:background="@drawable/bg_primary_radius_top_10"
|
||||
android:gravity="center"
|
||||
android:text="状态重置"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<!-- 表单内容 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="30dp"
|
||||
android:layout_marginTop="30dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 重置状态 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="重置状态:"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
type="@{SearchLayoutType.SPINNER}"
|
||||
hint='@{"请选择重置状态"}'
|
||||
list="@{model.resetStatusList}"
|
||||
value="@={model.selectedResetStatus}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 底部按钮 -->
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="40dp"
|
||||
android:layout_marginBottom="20dp">
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:onClick="@{()->model.dismiss()}"
|
||||
android:text="取消" />
|
||||
|
||||
<TextView
|
||||
style="@style/tv_bottom_btn"
|
||||
android:onClick="@{()->model.onSaveClick()}"
|
||||
android:text="保存" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -0,0 +1,124 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<data>
|
||||
|
||||
<import type="android.view.View" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="15dp"
|
||||
android:paddingBottom="15dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/bg_white_radius_bottom_8"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 表头 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:background="@color/color_f5"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="10dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:gravity="center"
|
||||
android:text="序号"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.5"
|
||||
android:gravity="center"
|
||||
android:text="库位号"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="入库人"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.5"
|
||||
android:gravity="center"
|
||||
android:text="入库时间"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="出库人"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.5"
|
||||
android:gravity="center"
|
||||
android:text="出库时间"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 数据列表 -->
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_storage_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:nestedScrollingEnabled="true"
|
||||
android:overScrollMode="never"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
|
||||
<!-- 暂无数据提示 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_empty"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="暂无数据"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="16sp" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -0,0 +1,134 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<data>
|
||||
|
||||
<import type="android.view.View" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="15dp"
|
||||
android:paddingBottom="15dp">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/bg_white_radius_bottom_8"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 表头 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:background="@color/color_f5"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="10dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:gravity="center"
|
||||
android:text="序号"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="件数"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="重量"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="航班日期"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="航班号"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center"
|
||||
android:text="分批"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.3"
|
||||
android:gravity="center"
|
||||
android:text="入库时间"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 数据列表 -->
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_warehouse_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:nestedScrollingEnabled="true"
|
||||
android:overScrollMode="never"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
|
||||
<!-- 暂无数据提示 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_empty"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="暂无数据"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="16sp" />
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -0,0 +1,336 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
<import type="com.lukouguoji.module_base.ui.weight.data.layout.DataLayoutType" />
|
||||
<import type="android.view.View" />
|
||||
<variable
|
||||
name="viewModel"
|
||||
type="com.lukouguoji.gjj.viewModel.IntImpQueryDetailsViewModel" />
|
||||
</data>
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/color_f2"
|
||||
android:fillViewport="true">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:paddingHorizontal="15dp"
|
||||
android:paddingBottom="15dp">
|
||||
|
||||
<!-- 运单信息卡片 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_white_radius_bottom_8"
|
||||
android:orientation="vertical"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- 第1行: 运单号、代理人、特码 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单号"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("wbNo")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"代理人"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("agentCode")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"特码"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("spCode")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第2行: 运单件数、运单重量、业务类型 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单件数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.maWbData.get("pc") != null ? String.valueOf((int)Math.round(((Double)viewModel.maWbData.get("pc")))) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.maWbData.get("weight") != null ? String.valueOf(viewModel.maWbData.get("weight")) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"业务类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("businessName")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第3行: 入库件数、入库重量、计费重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"入库件数"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.maWbData.get("inPc") != null ? String.valueOf((int)Math.round(((Double)viewModel.maWbData.get("inPc")))) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"入库重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.maWbData.get("inWeight") != null ? String.valueOf(viewModel.maWbData.get("inWeight")) : ``}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"计费重量"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{viewModel.maWbData.get("cashWeight") != null ? String.valueOf(viewModel.maWbData.get("cashWeight")) : ``}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第4行: 承运人、航程、包装类型 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"承运人"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("by1")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"航程"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("range")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"包装类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("packageType")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第5行: 运单类型、UN编号 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"运单类型"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("awbName")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"UN编号"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("unNumber")}' />
|
||||
|
||||
<Space
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第6行: 品名(中)占2列、锁定状态占1列 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="2"
|
||||
enable="@{false}"
|
||||
title='@{"品名(中)"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("goodsCn")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"锁定状态"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("lockStateText")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第7行: 品名(英)占2列、出库时间占1列 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="2"
|
||||
enable="@{false}"
|
||||
title='@{"品名(英)"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("goods")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"出库时间"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("dlvTime")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第8行: 原始舱单、理货报告、海关放行 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"原始舱单"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("mftStatus")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"理货报告"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("tallyStatus")}' />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
enable="@{false}"
|
||||
title='@{"海关放行"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("command")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第9行: 备注 - 多行输入 -->
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
enable="@{false}"
|
||||
inputHeight="@{80}"
|
||||
title='@{"备注"}'
|
||||
titleLength="@{5}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@{(String)viewModel.maWbData.get("remark")}' />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</ScrollView>
|
||||
</layout>
|
||||
@@ -174,7 +174,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<!-- 特码 -->
|
||||
<!-- 航班信息 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -184,13 +184,13 @@
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="特码:" />
|
||||
completeSpace="@{5}"
|
||||
android:text="航班信息:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{manifest.spCode ?? ``}" />
|
||||
android:text="@{manifest.getFlightSplit()}" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
|
||||
@@ -12,283 +12,315 @@
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:id="@+id/ll"
|
||||
<!-- 外层容器承载间距 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="15dp"
|
||||
android:layout_marginVertical="5dp"
|
||||
android:background="@drawable/bg_item"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 左侧选中图标 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/img_plane"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}" />
|
||||
<!-- 侧滑布局 -->
|
||||
<com.mcxtzhang.swipemenulib.SwipeMenuLayout
|
||||
android:id="@+id/swipe_menu"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- 中间内容区 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 第一行:航班日期 | 始发站 | 运单总件数 | 不正常件数 | 运单号 -->
|
||||
<!-- 主列表项容器 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:id="@+id/ll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical">
|
||||
android:background="@drawable/bg_item"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
|
||||
<!-- 航班日期 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
<!-- 左侧选中图标 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/img_plane"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}" />
|
||||
|
||||
<!-- 中间内容区 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
<!-- 第一行:航班日期 | 始发站 | 运单总件数 | 不正常件数 | 运单号 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="航班日期:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
<!-- 航班日期 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="航班日期:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fdate}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 始发站 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="始发站:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{4}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fdep}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 运单总件数 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单总件数:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.totalPc)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 不正常件数 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="不正常件数:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.abnPc)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 运单号 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单号:"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.wbNo}"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 第二行:航班号 | 目的站 | 运单总重量 | 经办人 | 经办时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fdate}"
|
||||
android:textSize="16sp" />
|
||||
android:layout_marginTop="10dp"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
<!-- 航班号 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<!-- 始发站 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="航班号:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="始发站:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{4}" />
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fno}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fdep}"
|
||||
android:textSize="16sp" />
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
<!-- 目的站 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<!-- 运单总件数 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="目的站:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{4}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单总件数:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fdest}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.totalPc)}"
|
||||
android:textSize="16sp" />
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
<!-- 运单总重量 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<!-- 不正常件数 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单总重量:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="不正常件数:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.totalWeight)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.abnPc)}"
|
||||
android:textSize="16sp" />
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
<!-- 经办人 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<!-- 运单号 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="经办人:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单号:"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.opName}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.wbNo}"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp" />
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
<!-- 经办时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="经办时间:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.opDate}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 第二行:航班号 | 目的站 | 运单总重量 | 经办人 | 经办时间 -->
|
||||
<!-- 侧滑菜单按钮区 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:gravity="center_vertical">
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<!-- 航班号 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="航班号:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fno}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 目的站 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="目的站:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{4}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.fdest}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 运单总重量 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单总重量:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.totalWeight)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 经办人 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="经办人:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{6}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.opName}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 经办时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="经办时间:"
|
||||
android:textSize="16sp"
|
||||
completeSpace="@{5}" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.opDate}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
<!-- 修改按钮 -->
|
||||
<TextView
|
||||
android:id="@+id/btn_edit"
|
||||
style="@style/tv_item_action"
|
||||
android:background="@color/colorPrimary"
|
||||
android:text="修改" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</LinearLayout>
|
||||
</com.mcxtzhang.swipemenulib.SwipeMenuLayout>
|
||||
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
|
||||
@@ -375,8 +375,21 @@
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<!-- 暂无数据提示 -->
|
||||
<TextView
|
||||
android:id="@+id/tv_empty"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:paddingVertical="15dp"
|
||||
android:text="暂无分单数据"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="14sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<!-- 表头 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginVertical="10dp"
|
||||
@@ -466,6 +479,7 @@
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.material.divider.MaterialDivider
|
||||
android:id="@+id/divider_header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1px"
|
||||
android:background="@color/c999999" />
|
||||
|
||||
@@ -13,12 +13,13 @@
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:id="@+id/ll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:layout_marginHorizontal="15dp"
|
||||
android:layout_marginVertical="5dp"
|
||||
android:background="@drawable/bg_item"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
@@ -28,7 +29,7 @@
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginEnd="10dp"
|
||||
android:layout_gravity="center"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}"
|
||||
android:src="@drawable/img_plane" />
|
||||
|
||||
@@ -36,22 +37,21 @@
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 第一行:运单号、代理人、航班信息、件数、重量 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- 运单号 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
@@ -65,17 +65,17 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.wbNo}"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp" />
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 代理人 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
@@ -90,15 +90,14 @@
|
||||
android:text="@{bean.agentCode}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 航班信息 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
@@ -110,21 +109,20 @@
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.flight}"
|
||||
android:text="@{bean.flightInfo}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 件数 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{3}"
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="件数:"
|
||||
@@ -136,15 +134,14 @@
|
||||
android:text="@{String.valueOf(bean.pc)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 重量 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{3}"
|
||||
@@ -159,24 +156,22 @@
|
||||
android:text="@{String.valueOf((int)bean.weight)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 第二行:提货单号、库位、提取时间、品名(中) -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<!-- 提货单号 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
@@ -191,21 +186,20 @@
|
||||
android:text="@{bean.pkId}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 库位 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="库 位:"
|
||||
android:text="库位:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
@@ -214,15 +208,14 @@
|
||||
android:text="@{bean.location}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 提取时间 -->
|
||||
<LinearLayout
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
@@ -237,35 +230,37 @@
|
||||
android:text="@{bean.chargeTime}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 品名(中):合并件数+重量列位置 -->
|
||||
<LinearLayout
|
||||
<!-- 品名(中):占据件数+重量两列宽度 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.6"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_weight="1.4"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{6}"
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="品名(中):"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ellipsize="end"
|
||||
android:maxLines="1"
|
||||
android:text="@{bean.goods}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</layout>
|
||||
|
||||
@@ -13,291 +13,311 @@
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<!-- 主列表项容器 -->
|
||||
<!-- 外层容器承载间距 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
android:layout_marginHorizontal="15dp"
|
||||
android:layout_marginVertical="5dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 选中图标 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_marginEnd="10dp"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}"
|
||||
android:src="@drawable/img_plane" />
|
||||
<!-- 侧滑布局 -->
|
||||
<com.mcxtzhang.swipemenulib.SwipeMenuLayout
|
||||
android:id="@+id/swipe_menu"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- 数据展示区域 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 第一行:运单号、件数、重量、计重重量、代理 -->
|
||||
<LinearLayout
|
||||
<!-- 主列表项容器 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:id="@+id/ll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
android:background="@drawable/bg_item"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
|
||||
<!-- 运单号 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
<!-- 选中图标 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_gravity="center"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}"
|
||||
android:src="@drawable/img_plane" />
|
||||
|
||||
<!-- 数据展示区域 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 第一行:运单号、件数、重量、计费重量、代理 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- 运单号 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单号:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.wbNo}"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 件数 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="件数:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.pc)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 重量 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="重量:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.weight)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 计费重量 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="计费重量:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.cashWeight)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 代理 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="代理:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.agentCode}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 第二行:特码、服务费、仓储费、总金额、提取时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:orientation="horizontal">
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
<!-- 特码 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="运单号"
|
||||
android:textSize="16sp" />
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="特码:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.spCode}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 服务费 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@{bean.wbNo}"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp" />
|
||||
android:layout_weight="0.7"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="服务费:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<!-- 件数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:orientation="horizontal">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.optCharge)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
completeSpace="@{3}"
|
||||
android:layout_width="wrap_content"
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 仓储费 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="件数"
|
||||
android:textSize="16sp" />
|
||||
android:layout_weight="0.7"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="仓储费:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.whsCharge)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 总金额 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@{String.valueOf(bean.pc)}"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
android:layout_weight="0.7"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="总金额:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<!-- 重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:orientation="horizontal">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.amount)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
completeSpace="@{3}"
|
||||
android:layout_width="wrap_content"
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 提取时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="重量"
|
||||
android:textSize="16sp" />
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@{String.valueOf((int)bean.weight)}"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="提取时间:"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.chargeTime}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<!-- 计重重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:orientation="horizontal">
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="计重重量"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:text="@{String.valueOf((int)bean.checkWeight)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 代理 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{3}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="代理"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@{bean.agentCode}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第二行:特码、服务费、仓储费、总金额、提取时间 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="horizontal">
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
|
||||
<!-- 特码 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:orientation="horizontal">
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="特码"
|
||||
android:textSize="16sp" />
|
||||
<!-- 侧滑菜单区域 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@{bean.spCode}"
|
||||
android:textSize="16sp" />
|
||||
<!-- 修改按钮 -->
|
||||
<TextView
|
||||
android:id="@+id/btn_edit"
|
||||
style="@style/tv_item_action"
|
||||
android:background="@color/colorPrimary"
|
||||
android:text="修改" />
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 服务费 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="服务费"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:text="@{String.valueOf((int)bean.serviceFee)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 仓储费 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="仓储费"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:text="@{String.valueOf((int)bean.storageFee)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 总金额 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{4}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="总金额"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="8dp"
|
||||
android:text="@{String.valueOf((int)bean.totalAmount)}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 提取时间 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
completeSpace="@{5}"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="提取时间"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="4dp"
|
||||
android:text="@{bean.pickUpTime}"
|
||||
android:textSize="16sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginStart="5dp"
|
||||
android:src="@drawable/ic_arrow_right" />
|
||||
</com.mcxtzhang.swipemenulib.SwipeMenuLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
@@ -8,15 +8,28 @@
|
||||
type="com.lukouguoji.module_base.bean.IntImpQueryBean" />
|
||||
</data>
|
||||
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:id="@+id/ll"
|
||||
<!-- 外层容器承载间距 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="15dp"
|
||||
android:layout_marginVertical="5dp"
|
||||
android:background="@drawable/bg_item"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 侧滑布局 -->
|
||||
<com.mcxtzhang.swipemenulib.SwipeMenuLayout
|
||||
android:id="@+id/swipe_menu"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<!-- 主列表项容器 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:id="@+id/ll"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/bg_item"
|
||||
android:orientation="horizontal"
|
||||
android:padding="10dp">
|
||||
|
||||
<!-- 左侧图标 -->
|
||||
<ImageView
|
||||
@@ -32,7 +45,7 @@
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 第一行:运单号、件数、重量、代理人、入库时间 -->
|
||||
<!-- 第一行:运单号、件数、重量、代理人、航班信息 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
@@ -41,7 +54,7 @@
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.1"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
@@ -63,7 +76,7 @@
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
@@ -84,20 +97,20 @@
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="运单类型:" />
|
||||
android:text="重量:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text='@{bean.awbName}'
|
||||
tools:text="国际进港" />
|
||||
android:text='@{String.valueOf(bean.awbWeight)}'
|
||||
tools:text="200" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
@@ -105,13 +118,13 @@
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
completeSpace="@{5}"
|
||||
android:text="代理人:" />
|
||||
|
||||
<TextView
|
||||
@@ -122,61 +135,61 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 入库时间 -->
|
||||
<!-- 航班信息 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="入库时间:" />
|
||||
android:text="航班信息:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text='@{bean.inDate}'
|
||||
tools:text="2024-05-13 17:10:22" />
|
||||
android:text='@{bean.flight}'
|
||||
tools:text="20240216/MU2026" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 第二行:航班、件数(入库)、重量(运单)、航程、出库时间 -->
|
||||
<!-- 第二行:航程、特码、运单类型、入库时间、出库时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<!-- 航班 -->
|
||||
<!-- 航程 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.1"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="航班:" />
|
||||
android:text="航程:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.flight}"
|
||||
tools:text="20240513/MU2026" />
|
||||
android:text="@{bean.range}"
|
||||
tools:text="LAX-HFE" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 入库件数 -->
|
||||
<!-- 特码 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.7"
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
@@ -193,45 +206,45 @@
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 运单重量 -->
|
||||
<!-- 运单类型 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="业务类型:" />
|
||||
android:text="运单类型:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text='@{bean.businessName}'
|
||||
tools:text="普货" />
|
||||
android:text='@{bean.awbName}'
|
||||
tools:text="国际进港" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 航程 -->
|
||||
<!-- 入库时间 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="目的地:" />
|
||||
completeSpace="@{5}"
|
||||
android:text="入库时间:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.dest}"
|
||||
tools:text="HFE" />
|
||||
android:text='@{bean.inDate}'
|
||||
tools:text="2024-05-13 17:10:22" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
@@ -239,7 +252,7 @@
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
@@ -260,14 +273,33 @@
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
<!-- 侧滑菜单按钮区 -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<!-- 修改按钮 -->
|
||||
<TextView
|
||||
android:id="@+id/btn_edit"
|
||||
style="@style/tv_item_action"
|
||||
android:background="@color/colorPrimary"
|
||||
android:text="修改" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
</com.mcxtzhang.swipemenulib.SwipeMenuLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
|
||||
@@ -0,0 +1,86 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="bean"
|
||||
type="com.lukouguoji.module_base.bean.GjjStorageUse" />
|
||||
|
||||
<variable
|
||||
name="position"
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@{position % 2 == 0 ? @color/white : @color/color_f2}"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="40dp"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="10dp"
|
||||
android:paddingVertical="8dp">
|
||||
|
||||
<!-- 序号 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(position + 1)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 库位号 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.5"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.location ?? `--`}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 入库人 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.inOpName != null ? bean.inOpName : (bean.inOpId ?? `--`)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 入库时间 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.5"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.inDate != null && bean.inDate.length() >= 16 ? bean.inDate.substring(0, 16) : (bean.inDate != null && bean.inDate.length() > 0 ? bean.inDate : `--`)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 出库人 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.outOpName != null ? bean.outOpName : (bean.outOpId ?? `--`)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 出库时间 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.5"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.outDate != null && bean.outDate.length() >= 16 ? bean.outDate.substring(0, 16) : (bean.outDate != null && bean.outDate.length() > 0 ? bean.outDate : `--`)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -0,0 +1,96 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="bean"
|
||||
type="com.lukouguoji.module_base.bean.GjjWarehouse" />
|
||||
|
||||
<variable
|
||||
name="position"
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@{position % 2 == 0 ? @color/white : @color/color_f2}"
|
||||
android:gravity="center_vertical"
|
||||
android:minHeight="40dp"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="10dp"
|
||||
android:paddingVertical="8dp">
|
||||
|
||||
<!-- 序号 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(position + 1)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 件数 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.pc != null ? String.valueOf(bean.pc) : ``}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 重量 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.weight ?? ``}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 航班日期 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.fdate ?? ``}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 航班号 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.fno ?? ``}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 分批 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.6"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.splitFlag != null && bean.splitFlag.length() > 0 ? bean.splitFlag : `1`}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 入库时间(取 opDate) -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.3"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.opDate != null && bean.opDate.length() >= 16 ? bean.opDate.substring(0, 16) : (bean.opDate ?? ``)}"
|
||||
android:textColor="@android:color/black"
|
||||
android:textSize="14sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</layout>
|
||||
@@ -1,6 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout 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"
|
||||
xmlns:loadImage="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
@@ -15,271 +16,449 @@
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<!-- 主列表项容器 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="horizontal"
|
||||
android:padding="15dp"
|
||||
android:gravity="center_vertical">
|
||||
android:layout_marginHorizontal="10dp"
|
||||
android:layout_marginTop="10dp"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 选中图标(飞机图标,根据选择状态切换图片) -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_gravity="center"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}"
|
||||
android:src="@drawable/img_plane" />
|
||||
|
||||
<!-- 理货信息区域 -->
|
||||
<!-- 白色卡片主要内容区域 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_weight="1"
|
||||
android:background="@drawable/bg_white_radius_8"
|
||||
android:orientation="vertical">
|
||||
|
||||
<!-- 第一行:运单号、状态、代理、件数、重量 -->
|
||||
<!-- 主要内容区域 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:orientation="horizontal"
|
||||
android:padding="15dp">
|
||||
|
||||
<!-- 运单号(主要信息,较大权重) -->
|
||||
<!-- 选中图标(飞机图标,根据选择状态切换图片) -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_icon"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:layout_gravity="center"
|
||||
loadImage="@{bean.checked.get() ? @drawable/img_plane_s : @drawable/img_plane}"
|
||||
android:src="@drawable/img_plane" />
|
||||
|
||||
<!-- 理货信息区域 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_weight="1"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
<!-- 第一行:运单号、状态、代理、件数、重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="运单号:" />
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
<!-- 运单号 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="运单号:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.getWaybillNo()}"
|
||||
android:textColor="@color/colorPrimary" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 状态 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="状态:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.status}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 代理 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="代理:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.agentCode}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 件数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="件数:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.pc)}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="重量:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.weight)}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第二行:特码、始发站、目的站、运单类型、分单数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.getWaybillNo()}"
|
||||
android:textColor="@color/colorPrimary" />
|
||||
android:layout_marginTop="10dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<!-- 航班信息 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="航班信息:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.getFlightSplit()}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 始发站 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="始发站:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.origin}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 目的站 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="目的站:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.dest}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 运单类型 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="运单类型:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.awbTypeName}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 分单数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="分单数:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.haWbNum)}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 状态 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="状态:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.status}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 代理 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="代理:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.agentCode}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 件数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="件数:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.pc)}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 重量 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="重量:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf((int)bean.weight)}" />
|
||||
|
||||
</LinearLayout>
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_arrow"
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 第二行:特码、始发站、目的站、运单类型、分单数 -->
|
||||
<LinearLayout
|
||||
<!-- 展开/折叠按钮 -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_show"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<!-- 特码 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="特码:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.spCode}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 始发站 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="始发站:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.origin}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 目的站 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="目的站:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.dest}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 运单类型 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{5}"
|
||||
android:text="运单类型:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{bean.awbTypeName}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 分单数 -->
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
completeSpace="@{4}"
|
||||
android:text="分单数:" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{String.valueOf(bean.haWbNum)}" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:layout_marginBottom="5dp"
|
||||
android:padding="5dp"
|
||||
android:src="@mipmap/img_down" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- 右侧箭头 -->
|
||||
<ImageView
|
||||
android:layout_width="30dp"
|
||||
android:layout_height="30dp"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:src="@drawable/img_pda_right" />
|
||||
<!-- 分单子列表容器(在白色卡片外面) -->
|
||||
<LinearLayout
|
||||
visible="@{bean.showMore}"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="5dp"
|
||||
android:background="#e3f6e0"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<!-- 暂无数据提示 -->
|
||||
<TextView
|
||||
android:id="@+id/tv_empty"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:paddingVertical="15dp"
|
||||
android:text="暂无分单数据"
|
||||
android:textColor="@color/text_gray"
|
||||
android:textSize="14sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<!-- 表头 -->
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginVertical="10dp"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="10dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:gravity="center"
|
||||
android:text="选项"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center"
|
||||
android:text="分单号"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="件数"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="重量"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="申报状态"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1.0"
|
||||
android:gravity="center"
|
||||
android:text="品名(中)"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="申报次数"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="申报费率"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="删除次数"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="删除费率"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.google.android.material.divider.MaterialDivider
|
||||
android:id="@+id/divider_header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1px"
|
||||
android:background="@color/c999999" />
|
||||
|
||||
<!-- 子列表 RecyclerView -->
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/rv_sub"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
136
module_gjj/src/main/res/layout/item_int_imp_tally_sub.xml
Normal file
136
module_gjj/src/main/res/layout/item_int_imp_tally_sub.xml
Normal file
@@ -0,0 +1,136 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:loadImage="http://schemas.android.com/tools">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="bean"
|
||||
type="com.lukouguoji.module_base.bean.GjjImportTally" />
|
||||
|
||||
<variable
|
||||
name="position"
|
||||
type="Integer" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:paddingHorizontal="10dp"
|
||||
android:paddingVertical="8dp">
|
||||
|
||||
<!-- 选项(单选框) -->
|
||||
<ImageView
|
||||
android:id="@+id/iv_checkbox"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.5"
|
||||
loadImage="@{bean.checked.get() ? @drawable/radiobtn_checked_gray : @drawable/radiobtn_unchecked_gray}"
|
||||
android:src="@drawable/radiobtn_unchecked_style" />
|
||||
|
||||
<!-- 分单号 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="1.2"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.hno}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 件数 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(bean.pc)}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 重量 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf((int)bean.weight)}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 申报状态 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{bean.status}"
|
||||
android:textColor="#4CAF50"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 品名(中) -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="1.0"
|
||||
android:ellipsize="end"
|
||||
android:gravity="center"
|
||||
android:maxLines="1"
|
||||
android:text="@{bean.goods}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 申报次数 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(bean.tallySCount)}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 申报费率 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(bean.tallySRate)}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 删除次数 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(bean.tallyDCount)}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- 删除费率 -->
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:layout_weight="0.8"
|
||||
android:gravity="center"
|
||||
android:text="@{String.valueOf(bean.tallyDRate)}"
|
||||
android:textColor="@color/text_normal"
|
||||
android:textSize="14sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
||||
@@ -20,7 +20,8 @@ class HbQueryListViewModel : BasePageViewModel() {
|
||||
|
||||
val date = MutableLiveData(DateUtils.getCurrentTime().formatDate())
|
||||
val fNo = MutableLiveData("")
|
||||
val range = MutableLiveData("")
|
||||
val dep = MutableLiveData("") // 始发站
|
||||
val dest = MutableLiveData("") // 目的站
|
||||
val addressType = MutableLiveData("")
|
||||
val serviceType = MutableLiveData("")
|
||||
|
||||
@@ -59,7 +60,7 @@ class HbQueryListViewModel : BasePageViewModel() {
|
||||
"limit" to pageModel.limit,
|
||||
"fdate" to date.value,
|
||||
"fno" to fNo.value,
|
||||
"range" to range.value,
|
||||
"range" to buildRange(),
|
||||
"countryType" to addressType.value,
|
||||
"serviceType" to serviceType.value,
|
||||
).toRequestBody()
|
||||
@@ -72,6 +73,13 @@ class HbQueryListViewModel : BasePageViewModel() {
|
||||
}
|
||||
}
|
||||
|
||||
private fun buildRange(): String? {
|
||||
val d = dep.value?.trim()
|
||||
val a = dest.value?.trim()
|
||||
if (d.isNullOrEmpty() && a.isNullOrEmpty()) return null
|
||||
return "${d ?: ""}-${a ?: ""}"
|
||||
}
|
||||
|
||||
override fun onItemClick(position: Int, type: Int) {
|
||||
val bean = pageModel.rv!!.commonAdapter()!!.getItem(position) as FlightBean
|
||||
ARouter.getInstance().build(ARouterConstants.ACTIVITY_URL_FLIGHT_QUERY_DETAILS)
|
||||
|
||||
@@ -46,13 +46,29 @@
|
||||
android:layout_weight="1" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
hint='@{"请输入航程"}'
|
||||
hint='@{"始发站"}'
|
||||
setTextAllCaps="@{true}"
|
||||
type="@{SearchLayoutType.INPUT}"
|
||||
value="@={viewModel.range}"
|
||||
value="@={viewModel.dep}"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1" />
|
||||
android:layout_weight="0.6" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="-"
|
||||
android:textSize="16sp" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
hint='@{"目的站"}'
|
||||
setTextAllCaps="@{true}"
|
||||
type="@{SearchLayoutType.INPUT}"
|
||||
value="@={viewModel.dest}"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.6" />
|
||||
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
hint='@{"请选择地区类型"}'
|
||||
@@ -127,7 +143,7 @@
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text='@{"合计:"+viewModel.count+"条"}'
|
||||
android:text='@{"合计:"+viewModel.count+"条"}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="18sp"
|
||||
android:textStyle="bold"
|
||||
|
||||
Reference in New Issue
Block a user