feat: 国际进港查询统计新增航班航次并调整筛选条件布局
- 底部统计栏在总重量后新增航班航次显示 - 航班号从筛选面板移至页面上方搜索区,出库状态移入筛选面板 - 筛选红点提示与重置逻辑同步调整字段归属 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -8,5 +8,6 @@ data class ManifestTotalDto(
|
||||
var wbNumber: Int = 0, // 运单票数/总票数
|
||||
var totalPc: Long = 0, // 总件数
|
||||
var totalWeight: Double = 0.0, // 总重量
|
||||
var cargoWeight: Double = 0.0 // 总货重
|
||||
var cargoWeight: Double = 0.0, // 总货重
|
||||
var flightNumber: Int = 0 // 航班航次
|
||||
)
|
||||
|
||||
@@ -55,8 +55,8 @@ class IntImpQueryActivity :
|
||||
if (visible) showFilterPanel() else hideFilterPanel()
|
||||
}
|
||||
|
||||
// 航班号:大写字母+数字
|
||||
binding.filterPanel.filterFlightNo.et.setUpperCaseAlphanumericFilter()
|
||||
// 航班号(顶部搜索区):大写字母+数字
|
||||
binding.flightNoSearch.et.setUpperCaseAlphanumericFilter()
|
||||
// 始发港:仅大写字母
|
||||
binding.filterPanel.filterOrigin.et.setUpperCaseLetterFilter()
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
val flightDateStart = MutableLiveData<String>(DateUtils.getCurrentTime().formatDate())
|
||||
val flightDateEnd = MutableLiveData("")
|
||||
val agentId = MutableLiveData("")
|
||||
val outStatus = MutableLiveData("")
|
||||
val flightNo = MutableLiveData("")
|
||||
val waybillNo = MutableLiveData("")
|
||||
|
||||
// ==================== 下拉列表 ====================
|
||||
@@ -55,6 +55,7 @@ class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
val totalCount = MutableLiveData("0")
|
||||
val totalPc = MutableLiveData("0")
|
||||
val totalWeight = MutableLiveData("0")
|
||||
val totalFlightNumber = MutableLiveData("0")
|
||||
|
||||
// ==================== 特码下拉 ====================
|
||||
val spCodeList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||
@@ -66,7 +67,7 @@ class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
|
||||
// ==================== 筛选条件 ====================
|
||||
val spCode = MutableLiveData("")
|
||||
val flightNo = MutableLiveData("")
|
||||
val outStatus = MutableLiveData("")
|
||||
val origin = MutableLiveData("")
|
||||
val awbType = MutableLiveData("")
|
||||
val businessType = MutableLiveData("")
|
||||
@@ -75,11 +76,11 @@ class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
// 是否有筛选条件(任意一个非空则为 true)
|
||||
val hasFilter: MediatorLiveData<Boolean> = MediatorLiveData<Boolean>().apply {
|
||||
val update = { _: Any? ->
|
||||
value = listOf(spCode, flightNo, origin, awbType, businessType, goodsCn)
|
||||
value = listOf(spCode, outStatus, origin, awbType, businessType, goodsCn)
|
||||
.any { !it.value.isNullOrEmpty() }
|
||||
}
|
||||
addSource(spCode, update)
|
||||
addSource(flightNo, update)
|
||||
addSource(outStatus, update)
|
||||
addSource(origin, update)
|
||||
addSource(awbType, update)
|
||||
addSource(businessType, update)
|
||||
@@ -108,7 +109,7 @@ class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
|
||||
fun resetFilter() {
|
||||
spCode.value = ""
|
||||
flightNo.value = ""
|
||||
outStatus.value = ""
|
||||
origin.value = ""
|
||||
awbType.value = ""
|
||||
businessType.value = ""
|
||||
@@ -176,6 +177,7 @@ class IntImpQueryViewModel : BasePageViewModel(), IOnItemClickListener {
|
||||
totalCount.value = (data?.wbNumber ?: 0).toString()
|
||||
totalPc.value = (data?.totalPc ?: 0).toString()
|
||||
totalWeight.value = (data?.totalWeight ?: 0.0).toString()
|
||||
totalFlightNumber.value = (data?.flightNumber ?: 0).toString()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -72,15 +72,15 @@
|
||||
type="@{SearchLayoutType.SPINNER}"
|
||||
value="@={viewModel.agentId}" />
|
||||
|
||||
<!-- 出库状态 -->
|
||||
<!-- 航班号 -->
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
android:id="@+id/flight_no_search"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
hint='@{"请选择出库状态"}'
|
||||
list="@{viewModel.outStatusList}"
|
||||
type="@{SearchLayoutType.SPINNER}"
|
||||
value="@={viewModel.outStatus}" />
|
||||
hint='@{"请输入航班号"}'
|
||||
type="@{SearchLayoutType.INPUT}"
|
||||
value="@={viewModel.flightNo}" />
|
||||
|
||||
<!-- 运单号 -->
|
||||
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||
@@ -201,6 +201,16 @@
|
||||
android:textStyle="bold"
|
||||
tools:text="总重量:100" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="20dp"
|
||||
android:text='@{`航班航次:` + viewModel.totalFlightNumber}'
|
||||
android:textColor="@color/bottom_tool_tips_text_color"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold"
|
||||
tools:text="航班航次:2" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@@ -68,17 +68,17 @@
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.spCode}' />
|
||||
|
||||
<!-- 航班号 -->
|
||||
<!-- 出库状态 -->
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
android:id="@+id/filter_flight_no"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="10dp"
|
||||
hint='@{"请输入航班号"}'
|
||||
title='@{"航班号"}'
|
||||
hint='@{"请选择出库状态"}'
|
||||
list="@{viewModel.outStatusList}"
|
||||
title='@{"出库状态"}'
|
||||
titleLength="@{4}"
|
||||
type="@{DataLayoutType.INPUT}"
|
||||
value='@={viewModel.flightNo}' />
|
||||
type="@{DataLayoutType.SPINNER}"
|
||||
value='@={viewModel.outStatus}' />
|
||||
|
||||
<!-- 始发港 -->
|
||||
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||
|
||||
Reference in New Issue
Block a user