Compare commits
4 Commits
b994f43bc7
...
06713190e0
| Author | SHA1 | Date | |
|---|---|---|---|
| 06713190e0 | |||
| ff8185644b | |||
| 330b5bc28a | |||
| 1476f1368a |
@@ -286,6 +286,14 @@
|
|||||||
android:name=".page.car.list.CarListActivity"
|
android:name=".page.car.list.CarListActivity"
|
||||||
android:configChanges="orientation|keyboardHidden"
|
android:configChanges="orientation|keyboardHidden"
|
||||||
android:screenOrientation="userLandscape" />
|
android:screenOrientation="userLandscape" />
|
||||||
|
<activity
|
||||||
|
android:name=".page.uld.list.UldListActivity"
|
||||||
|
android:configChanges="orientation|keyboardHidden"
|
||||||
|
android:screenOrientation="userLandscape" />
|
||||||
|
<activity
|
||||||
|
android:name=".page.uld.edit.UldEditActivity"
|
||||||
|
android:configChanges="orientation|keyboardHidden"
|
||||||
|
android:screenOrientation="userLandscape" />
|
||||||
<activity
|
<activity
|
||||||
android:name=".page.car.add.CarDetailsActivity"
|
android:name=".page.car.add.CarDetailsActivity"
|
||||||
android:configChanges="orientation|keyboardHidden"
|
android:configChanges="orientation|keyboardHidden"
|
||||||
@@ -302,6 +310,10 @@
|
|||||||
android:name=".page.transportLog.list.TransportLogActivity"
|
android:name=".page.transportLog.list.TransportLogActivity"
|
||||||
android:configChanges="orientation|keyboardHidden"
|
android:configChanges="orientation|keyboardHidden"
|
||||||
android:screenOrientation="userLandscape" />
|
android:screenOrientation="userLandscape" />
|
||||||
|
<activity
|
||||||
|
android:name=".page.coldStorage.list.ColdStorageActivity"
|
||||||
|
android:configChanges="orientation|keyboardHidden"
|
||||||
|
android:screenOrientation="userLandscape" />
|
||||||
<activity
|
<activity
|
||||||
android:name=".page.gnj.manifest.list.GnjManifestListActivity"
|
android:name=".page.gnj.manifest.list.GnjManifestListActivity"
|
||||||
android:configChanges="orientation|keyboardHidden"
|
android:configChanges="orientation|keyboardHidden"
|
||||||
@@ -440,6 +452,27 @@
|
|||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:screenOrientation="userLandscape" />
|
android:screenOrientation="userLandscape" />
|
||||||
|
|
||||||
|
<!-- 国际进港-提取出库 -->
|
||||||
|
<activity
|
||||||
|
android:name="com.lukouguoji.gjj.activity.IntImpPickUpDLVActivity"
|
||||||
|
android:configChanges="orientation|keyboardHidden"
|
||||||
|
android:exported="false"
|
||||||
|
android:screenOrientation="userLandscape" />
|
||||||
|
|
||||||
|
<!-- 国际进港-进港查询 -->
|
||||||
|
<activity
|
||||||
|
android:name="com.lukouguoji.gjj.activity.IntImpQueryActivity"
|
||||||
|
android:configChanges="orientation|keyboardHidden"
|
||||||
|
android:exported="false"
|
||||||
|
android:screenOrientation="userLandscape" />
|
||||||
|
|
||||||
|
<!-- 国际进港-事故签证 -->
|
||||||
|
<activity
|
||||||
|
android:name="com.lukouguoji.gjj.activity.IntImpAccidentVisaActivity"
|
||||||
|
android:configChanges="orientation|keyboardHidden"
|
||||||
|
android:exported="false"
|
||||||
|
android:screenOrientation="userLandscape" />
|
||||||
|
|
||||||
<service android:name="com.huitao.printer.service.PrinterService" />
|
<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.AncillaryService" />
|
||||||
<service android:name="com.lukouguoji.gnc.bluetooth.service.MyService" />
|
<service android:name="com.lukouguoji.gnc.bluetooth.service.MyService" />
|
||||||
|
|||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.coldStorage.list
|
||||||
|
|
||||||
|
import android.app.Activity
|
||||||
|
import android.content.Context
|
||||||
|
import android.content.Intent
|
||||||
|
import android.os.Bundle
|
||||||
|
import com.alibaba.android.arouter.facade.annotation.Route
|
||||||
|
import com.lukouguoji.aerologic.R
|
||||||
|
import com.lukouguoji.aerologic.databinding.ActivityColdStorageBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||||
|
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.router.ARouterConstants
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记页面
|
||||||
|
*/
|
||||||
|
@Route(path = ARouterConstants.ACTIVITY_URL_COLD_STORAGE)
|
||||||
|
class ColdStorageActivity :
|
||||||
|
BaseBindingActivity<ActivityColdStorageBinding, ColdStorageViewModel>() {
|
||||||
|
|
||||||
|
override fun layoutId() = R.layout.activity_cold_storage
|
||||||
|
override fun viewModelClass() = ColdStorageViewModel::class.java
|
||||||
|
|
||||||
|
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||||
|
setBackArrow("冷库登记")
|
||||||
|
binding.viewModel = viewModel
|
||||||
|
|
||||||
|
// 观察全选状态,更新图标透明度
|
||||||
|
viewModel.isAllChecked.observe(this) { isAllChecked ->
|
||||||
|
binding.checkIcon.alpha = if (isAllChecked) 1.0f else 0.5f
|
||||||
|
}
|
||||||
|
|
||||||
|
// 绑定分页
|
||||||
|
viewModel.pageModel.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, this)
|
||||||
|
|
||||||
|
// 监听刷新事件
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 初始加载数据
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||||
|
super.onActivityResult(requestCode, resultCode, data)
|
||||||
|
if (requestCode == Constant.RequestCode.WAYBILL && resultCode == Activity.RESULT_OK) {
|
||||||
|
viewModel.wbNo.value = data?.getStringExtra(Constant.Result.CODED_CONTENT)
|
||||||
|
viewModel.searchClick()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
@JvmStatic
|
||||||
|
fun start(context: Context) {
|
||||||
|
context.startActivity(Intent(context, ColdStorageActivity::class.java))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.coldStorage.list
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.lukouguoji.aerologic.databinding.ItemColdStorageBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||||
|
import com.lukouguoji.module_base.bean.ColdStorageBean
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记 列表项ViewHolder
|
||||||
|
*/
|
||||||
|
class ColdStorageViewHolder(view: View) :
|
||||||
|
BaseViewHolder<ColdStorageBean, ItemColdStorageBinding>(view) {
|
||||||
|
|
||||||
|
override fun onBind(item: Any?, position: Int) {
|
||||||
|
val bean = getItemBean(item) ?: return
|
||||||
|
binding.bean = bean
|
||||||
|
binding.position = position
|
||||||
|
binding.executePendingBindings()
|
||||||
|
|
||||||
|
// 添加图标点击事件 - 切换选择状态
|
||||||
|
binding.ivIcon.setOnClickListener {
|
||||||
|
bean.checked.set(!bean.checked.get())
|
||||||
|
binding.executePendingBindings()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,175 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.coldStorage.list
|
||||||
|
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import androidx.lifecycle.viewModelScope
|
||||||
|
import com.lukouguoji.aerologic.R
|
||||||
|
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||||
|
import com.lukouguoji.module_base.bean.ColdStorageBean
|
||||||
|
import dev.utils.app.info.KeyValue
|
||||||
|
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.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 kotlinx.coroutines.launch
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记 ViewModel
|
||||||
|
*/
|
||||||
|
class ColdStorageViewModel : BasePageViewModel() {
|
||||||
|
|
||||||
|
// ========== 搜索条件 ==========
|
||||||
|
val ieFlag = MutableLiveData("") // 进出港标识
|
||||||
|
val wbNo = MutableLiveData("") // 运单号
|
||||||
|
val status = MutableLiveData("") // 货物状态
|
||||||
|
val outUserName = MutableLiveData("") // 出库人
|
||||||
|
val inUserName = MutableLiveData("") // 入库人
|
||||||
|
|
||||||
|
// ========== 下拉列表数据源 ==========
|
||||||
|
val ieFlagList = MutableLiveData<List<KeyValue>>(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("进港", "I"),
|
||||||
|
KeyValue("出港", "E")
|
||||||
|
)
|
||||||
|
)
|
||||||
|
val statusList = MutableLiveData<List<KeyValue>>(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("已入库", "已入库"),
|
||||||
|
KeyValue("已出库", "已出库")
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
// ========== 统计信息 ==========
|
||||||
|
val totalCount = MutableLiveData("0") // 合计票数
|
||||||
|
val totalPc = MutableLiveData("0") // 总件数
|
||||||
|
val totalWeight = MutableLiveData("0") // 总重量
|
||||||
|
|
||||||
|
// ========== 全选状态 ==========
|
||||||
|
val isAllChecked = MutableLiveData(false)
|
||||||
|
|
||||||
|
init {
|
||||||
|
isAllChecked.observeForever { checked ->
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<ColdStorageBean>
|
||||||
|
?: return@observeForever
|
||||||
|
list.forEach { it.checked.set(checked) }
|
||||||
|
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ========== 适配器配置 ==========
|
||||||
|
val itemViewHolder = ColdStorageViewHolder::class.java
|
||||||
|
val itemLayoutId = R.layout.item_cold_storage
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 扫码运单号
|
||||||
|
*/
|
||||||
|
fun scanWbNo() {
|
||||||
|
ScanModel.startScan(getTopActivity(), Constant.RequestCode.WAYBILL)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索按钮点击
|
||||||
|
*/
|
||||||
|
fun searchClick() {
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 全选按钮点击
|
||||||
|
*/
|
||||||
|
fun checkAllClick() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<ColdStorageBean> ?: return
|
||||||
|
val shouldCheckAll = !isAllChecked.value!!
|
||||||
|
list.forEach { it.checked.set(shouldCheckAll) }
|
||||||
|
isAllChecked.value = shouldCheckAll
|
||||||
|
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 完成入库
|
||||||
|
*/
|
||||||
|
fun completeIn() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<ColdStorageBean> ?: return
|
||||||
|
val selectedItems = list.filter { it.isSelected }
|
||||||
|
|
||||||
|
if (selectedItems.isEmpty()) {
|
||||||
|
showToast("请选择要入库的数据")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
launchLoadingCollect({ NetApply.api.coldStorageCompleteIn(selectedItems.toRequestBody()) }) {
|
||||||
|
onSuccess = {
|
||||||
|
showToast("入库完成")
|
||||||
|
viewModelScope.launch {
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||||
|
}
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 完成出库
|
||||||
|
*/
|
||||||
|
fun completeOut() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<ColdStorageBean> ?: return
|
||||||
|
val selectedItems = list.filter { it.isSelected }
|
||||||
|
|
||||||
|
if (selectedItems.isEmpty()) {
|
||||||
|
showToast("请选择要出库的数据")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
launchLoadingCollect({ NetApply.api.coldStorageCompleteOut(selectedItems.toRequestBody()) }) {
|
||||||
|
onSuccess = {
|
||||||
|
showToast("出库完成")
|
||||||
|
viewModelScope.launch {
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||||
|
}
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取数据
|
||||||
|
*/
|
||||||
|
override fun getData() {
|
||||||
|
val filterParams = mapOf(
|
||||||
|
"ieFlag" to ieFlag.value?.ifEmpty { null },
|
||||||
|
"wbNo" to wbNo.value?.ifEmpty { null },
|
||||||
|
"status" to status.value?.ifEmpty { null },
|
||||||
|
"outUserName" to outUserName.value?.ifEmpty { null },
|
||||||
|
"inUserName" to inUserName.value?.ifEmpty { null }
|
||||||
|
)
|
||||||
|
|
||||||
|
val listParams = (filterParams + mapOf(
|
||||||
|
"pageNum" to pageModel.page,
|
||||||
|
"pageSize" to pageModel.limit
|
||||||
|
)).toRequestBody()
|
||||||
|
|
||||||
|
val totalParams = filterParams.toRequestBody()
|
||||||
|
|
||||||
|
// 获取列表
|
||||||
|
launchLoadingCollect({ NetApply.api.getColdStorageList(listParams) }) {
|
||||||
|
onSuccess = { pageModel.handleListBean(it?.toBaseListBean()) }
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取统计信息
|
||||||
|
launchCollect({ NetApply.api.getColdStorageTotal(totalParams) }) {
|
||||||
|
onSuccess = { result ->
|
||||||
|
val data = result.data
|
||||||
|
totalCount.value = (data?.wbNumber ?: 0).toString()
|
||||||
|
totalPc.value = (data?.totalPc ?: 0).toString()
|
||||||
|
totalWeight.value = (data?.totalWeight ?: 0.0).toString()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.uld.edit
|
||||||
|
|
||||||
|
import android.content.Context
|
||||||
|
import android.content.Intent
|
||||||
|
import android.os.Bundle
|
||||||
|
import com.lukouguoji.aerologic.R
|
||||||
|
import com.lukouguoji.aerologic.databinding.ActivityUldEditBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||||
|
import com.lukouguoji.module_base.common.Constant
|
||||||
|
|
||||||
|
class UldEditActivity : BaseBindingActivity<ActivityUldEditBinding, UldEditViewModel>() {
|
||||||
|
|
||||||
|
override fun layoutId() = R.layout.activity_uld_edit
|
||||||
|
|
||||||
|
override fun viewModelClass() = UldEditViewModel::class.java
|
||||||
|
|
||||||
|
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||||
|
viewModel.initOnCreate(intent)
|
||||||
|
setBackArrow("ULD${viewModel.pageType.value!!.title}")
|
||||||
|
binding.viewModel = viewModel
|
||||||
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
@JvmStatic
|
||||||
|
fun start(context: Context, id: String = "", modify: Boolean = id.isEmpty()) {
|
||||||
|
val starter = Intent(context, UldEditActivity::class.java)
|
||||||
|
.putExtra(Constant.Key.ID, id)
|
||||||
|
.putExtra(Constant.Key.DATA, modify)
|
||||||
|
context.startActivity(starter)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,84 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.uld.edit
|
||||||
|
|
||||||
|
import android.content.Intent
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import com.lukouguoji.module_base.base.BaseViewModel
|
||||||
|
import com.lukouguoji.module_base.bean.ULDBean
|
||||||
|
import com.lukouguoji.module_base.common.Constant
|
||||||
|
import com.lukouguoji.module_base.common.DetailsPageType
|
||||||
|
import com.lukouguoji.module_base.http.net.NetApply
|
||||||
|
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 dev.DevUtils
|
||||||
|
import dev.utils.app.info.KeyValue
|
||||||
|
|
||||||
|
class UldEditViewModel : BaseViewModel() {
|
||||||
|
|
||||||
|
var id = ""
|
||||||
|
|
||||||
|
val pageType = MutableLiveData(DetailsPageType.Add)
|
||||||
|
|
||||||
|
val uldBean = MutableLiveData(ULDBean())
|
||||||
|
|
||||||
|
val statusList = MutableLiveData<List<KeyValue>>(
|
||||||
|
listOf(
|
||||||
|
KeyValue("正常", "0"),
|
||||||
|
KeyValue("故障", "1"),
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
// 所属航司下拉列表(mock,后续替换为接口)
|
||||||
|
val carrierList = MutableLiveData<List<KeyValue>>(
|
||||||
|
listOf(
|
||||||
|
KeyValue("MU - 东方航空", "MU"),
|
||||||
|
KeyValue("CA - 国航", "CA"),
|
||||||
|
KeyValue("CZ - 南方航空", "CZ"),
|
||||||
|
KeyValue("HO - 吉祥航空", "HO"),
|
||||||
|
KeyValue("FM - 上海航空", "FM"),
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
fun initOnCreate(intent: Intent) {
|
||||||
|
id = intent.getStringExtra(Constant.Key.ID) ?: ""
|
||||||
|
val modify = intent.getBooleanExtra(Constant.Key.DATA, false)
|
||||||
|
pageType.value = if (id.isEmpty()) DetailsPageType.Add
|
||||||
|
else if (modify) DetailsPageType.Modify else DetailsPageType.Details
|
||||||
|
|
||||||
|
getData()
|
||||||
|
}
|
||||||
|
|
||||||
|
private fun getData() {
|
||||||
|
if (id.isEmpty()) return
|
||||||
|
launchLoadingCollect({
|
||||||
|
NetApply.api.queryUldByCode(id)
|
||||||
|
}) {
|
||||||
|
onSuccess = {
|
||||||
|
uldBean.value = it.data ?: ULDBean()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onSaveClick() {
|
||||||
|
val bean = uldBean.value ?: return
|
||||||
|
if (bean.uld.isBlank()) {
|
||||||
|
showToast("ULD编号不能为空")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
val isAdd = pageType.value == DetailsPageType.Add
|
||||||
|
launchLoadingCollect({
|
||||||
|
if (isAdd) NetApply.api.saveUld(bean.toRequestBody())
|
||||||
|
else NetApply.api.updateUld(bean.toRequestBody())
|
||||||
|
}) {
|
||||||
|
onSuccess = {
|
||||||
|
showToast(it.msg.noNull(if (isAdd) "新增成功" else "修改成功"))
|
||||||
|
if (isAdd) uldBean.value = ULDBean() else getData()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onCancelClick() {
|
||||||
|
DevUtils.getTopActivity().finish()
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,45 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.uld.list
|
||||||
|
|
||||||
|
import android.content.Context
|
||||||
|
import android.content.Intent
|
||||||
|
import android.os.Bundle
|
||||||
|
import com.lukouguoji.aerologic.R
|
||||||
|
import com.lukouguoji.aerologic.databinding.ActivityUldListBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||||
|
import com.lukouguoji.module_base.ktx.addOnItemClickListener
|
||||||
|
import com.lukouguoji.module_base.ktx.getLifecycleOwner
|
||||||
|
|
||||||
|
class UldListActivity : BaseBindingActivity<ActivityUldListBinding, UldListViewModel>() {
|
||||||
|
|
||||||
|
override fun layoutId(): Int {
|
||||||
|
return R.layout.activity_uld_list
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun viewModelClass(): Class<UldListViewModel> {
|
||||||
|
return UldListViewModel::class.java
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||||
|
setBackArrow("ULD管理")
|
||||||
|
binding.viewModel = viewModel
|
||||||
|
viewModel.pageModel.bindSmartRefreshLayout(
|
||||||
|
binding.srl,
|
||||||
|
binding.rv,
|
||||||
|
viewModel,
|
||||||
|
getLifecycleOwner()
|
||||||
|
)
|
||||||
|
binding.rv.addOnItemClickListener(viewModel)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onResume() {
|
||||||
|
super.onResume()
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
@JvmStatic
|
||||||
|
fun start(context: Context) {
|
||||||
|
context.startActivity(Intent(context, UldListActivity::class.java))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.uld.list
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.lukouguoji.aerologic.databinding.ItemUldListBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||||
|
import com.lukouguoji.module_base.bean.ULDBean
|
||||||
|
|
||||||
|
class UldListViewHolder(view: View) : BaseViewHolder<ULDBean, ItemUldListBinding>(view) {
|
||||||
|
override fun onBind(item: Any?, position: Int) {
|
||||||
|
val itemBean = getItemBean(item)!!
|
||||||
|
binding.bean = itemBean
|
||||||
|
notifyItemClick(position, binding.llContent)
|
||||||
|
notifyItemClick(position, binding.tvModify)
|
||||||
|
notifyItemClick(position, binding.tvDelete)
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,116 @@
|
|||||||
|
package com.lukouguoji.aerologic.page.uld.list
|
||||||
|
|
||||||
|
import android.app.Activity
|
||||||
|
import android.content.Intent
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import com.lukouguoji.aerologic.R
|
||||||
|
import com.lukouguoji.aerologic.page.uld.edit.UldEditActivity
|
||||||
|
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||||
|
import com.lukouguoji.module_base.bean.ULDBean
|
||||||
|
import com.lukouguoji.module_base.common.Constant
|
||||||
|
import com.lukouguoji.module_base.http.net.NetApply
|
||||||
|
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||||
|
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.model.ConfirmDialogModel
|
||||||
|
import com.lukouguoji.module_base.ktx.toRequestBody
|
||||||
|
import com.lukouguoji.module_base.model.ScanModel
|
||||||
|
import dev.DevUtils
|
||||||
|
import dev.utils.app.info.KeyValue
|
||||||
|
|
||||||
|
class UldListViewModel : BasePageViewModel() {
|
||||||
|
|
||||||
|
// 搜索条件
|
||||||
|
val status = MutableLiveData("")
|
||||||
|
val uldSuffix = MutableLiveData("")
|
||||||
|
val uldNo = MutableLiveData("")
|
||||||
|
|
||||||
|
// 状态下拉列表
|
||||||
|
val statusList = MutableLiveData<List<KeyValue>>(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("正常", "0"),
|
||||||
|
KeyValue("故障", "1"),
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
// 所属航司下拉列表(mock,后续替换为接口)
|
||||||
|
val carrierList = MutableLiveData<List<KeyValue>>(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("MU - 东方航空", "MU"),
|
||||||
|
KeyValue("CA - 国航", "CA"),
|
||||||
|
KeyValue("CZ - 南方航空", "CZ"),
|
||||||
|
KeyValue("HO - 吉祥航空", "HO"),
|
||||||
|
KeyValue("FM - 上海航空", "FM"),
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
// 合计数量
|
||||||
|
val count = MutableLiveData(0L)
|
||||||
|
|
||||||
|
val itemLayoutId = R.layout.item_uld_list
|
||||||
|
val itemViewHolder = UldListViewHolder::class.java
|
||||||
|
|
||||||
|
override fun getData() {
|
||||||
|
launchLoadingCollect({
|
||||||
|
NetApply.api.getUldList(
|
||||||
|
mapOf(
|
||||||
|
"pageNum" to pageModel.page,
|
||||||
|
"pageSize" to pageModel.limit,
|
||||||
|
"status" to status.value?.ifEmpty { null },
|
||||||
|
"uldSuffix" to uldSuffix.value?.ifEmpty { null },
|
||||||
|
"uld" to uldNo.value?.ifEmpty { null },
|
||||||
|
).toRequestBody()
|
||||||
|
)
|
||||||
|
}) {
|
||||||
|
onSuccess = {
|
||||||
|
pageModel.handleListBean(it.toBaseListBean())
|
||||||
|
count.value = it.total
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onUldScanClick() {
|
||||||
|
ScanModel.startScan(DevUtils.getTopActivity(), Constant.RequestCode.ULD)
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onAddClick() {
|
||||||
|
UldEditActivity.start(DevUtils.getTopActivity())
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onItemClick(position: Int, type: Int) {
|
||||||
|
val bean = pageModel.rv?.commonAdapter()?.getItem(position) as? ULDBean ?: return
|
||||||
|
when (type) {
|
||||||
|
R.id.ll_content -> UldEditActivity.start(DevUtils.getTopActivity(), bean.uld)
|
||||||
|
R.id.tv_modify -> UldEditActivity.start(DevUtils.getTopActivity(), bean.uld, true)
|
||||||
|
R.id.tv_delete -> deleteUld(bean.uld)
|
||||||
|
else -> {}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private fun deleteUld(uld: String) {
|
||||||
|
ConfirmDialogModel("是否确定删除该ULD记录?") {
|
||||||
|
launchLoadingCollect({
|
||||||
|
NetApply.api.deleteUld(uld)
|
||||||
|
}) {
|
||||||
|
onSuccess = {
|
||||||
|
showToast("删除成功")
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}.show()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||||
|
if (resultCode == Activity.RESULT_OK && data != null) {
|
||||||
|
when (requestCode) {
|
||||||
|
Constant.RequestCode.ULD -> {
|
||||||
|
uldNo.value = data.getStringExtra(Constant.Result.CODED_CONTENT).noNull()
|
||||||
|
}
|
||||||
|
else -> {}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -30,6 +30,8 @@ import com.lukouguoji.aerologic.page.telegram.list.TelegramListActivity
|
|||||||
import com.lukouguoji.aerologic.page.test.PrintActivity
|
import com.lukouguoji.aerologic.page.test.PrintActivity
|
||||||
import com.lukouguoji.aerologic.page.transport.GoodsTransportActivity
|
import com.lukouguoji.aerologic.page.transport.GoodsTransportActivity
|
||||||
import com.lukouguoji.aerologic.page.transportLog.list.TransportLogActivity
|
import com.lukouguoji.aerologic.page.transportLog.list.TransportLogActivity
|
||||||
|
import com.lukouguoji.aerologic.page.coldStorage.list.ColdStorageActivity
|
||||||
|
import com.lukouguoji.aerologic.page.uld.list.UldListActivity
|
||||||
import com.lukouguoji.gnc.page.deposit.list.GncDepositListActivity
|
import com.lukouguoji.gnc.page.deposit.list.GncDepositListActivity
|
||||||
import com.lukouguoji.gnc.page.distribution.home.GncDistributionHomeActivity
|
import com.lukouguoji.gnc.page.distribution.home.GncDistributionHomeActivity
|
||||||
import com.lukouguoji.gnc.page.fubang.list.GncFuBangListActivity
|
import com.lukouguoji.gnc.page.fubang.list.GncFuBangListActivity
|
||||||
@@ -463,6 +465,25 @@ class HomeFragment : Fragment() {
|
|||||||
.navigation()
|
.navigation()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 提取出库
|
||||||
|
Constant.AuthName.IntImpPickUpDLV -> {
|
||||||
|
ARouter.getInstance().build(ARouterConstants.ACTIVITY_URL_INT_IMP_PICK_UP_DLV)
|
||||||
|
.navigation()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 进港查询
|
||||||
|
Constant.AuthName.GjjQueryListActivity -> {
|
||||||
|
ARouter.getInstance().build(ARouterConstants.ACTIVITY_URL_GJJ_QUERY_LIST)
|
||||||
|
.navigation()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 事故签证
|
||||||
|
Constant.AuthName.IntImpAccidentVisa -> {
|
||||||
|
ARouter.getInstance()
|
||||||
|
.build(ARouterConstants.ACTIVITY_URL_INT_IMP_ACCIDENT_VISA)
|
||||||
|
.navigation()
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 航班查询
|
* 航班查询
|
||||||
*/
|
*/
|
||||||
@@ -529,6 +550,14 @@ class HomeFragment : Fragment() {
|
|||||||
Constant.AuthName.ComprehensiveLog -> {
|
Constant.AuthName.ComprehensiveLog -> {
|
||||||
LogListActivity.start(requireContext())
|
LogListActivity.start(requireContext())
|
||||||
}
|
}
|
||||||
|
// ULD管理
|
||||||
|
Constant.AuthName.ComprehensiveUld -> {
|
||||||
|
UldListActivity.start(requireContext())
|
||||||
|
}
|
||||||
|
// 冷库登记
|
||||||
|
Constant.AuthName.ComprehensiveColdStorage -> {
|
||||||
|
ColdStorageActivity.start(requireContext())
|
||||||
|
}
|
||||||
|
|
||||||
else -> {
|
else -> {
|
||||||
Toast.makeText(
|
Toast.makeText(
|
||||||
@@ -826,6 +855,27 @@ class HomeFragment : Fragment() {
|
|||||||
"提取记录"
|
"提取记录"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
list.add(
|
||||||
|
RightMenu(
|
||||||
|
Constant.AuthName.IntImpPickUpDLV,
|
||||||
|
R.mipmap.gnj_cang_ku_icon,
|
||||||
|
"提取出库"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
list.add(
|
||||||
|
RightMenu(
|
||||||
|
Constant.AuthName.GjjQueryListActivity,
|
||||||
|
R.mipmap.img_bwjx,
|
||||||
|
"进港查询"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
list.add(
|
||||||
|
RightMenu(
|
||||||
|
Constant.AuthName.IntImpAccidentVisa,
|
||||||
|
R.mipmap.img_bwjx,
|
||||||
|
"事故签证"
|
||||||
|
)
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
Constant.AuthName.Flight -> {
|
Constant.AuthName.Flight -> {
|
||||||
@@ -910,6 +960,20 @@ class HomeFragment : Fragment() {
|
|||||||
"转运记录"
|
"转运记录"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
list.add(
|
||||||
|
RightMenu(
|
||||||
|
Constant.AuthName.ComprehensiveUld,
|
||||||
|
R.mipmap.cargo,
|
||||||
|
"ULD管理"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
list.add(
|
||||||
|
RightMenu(
|
||||||
|
Constant.AuthName.ComprehensiveColdStorage,
|
||||||
|
com.lukouguoji.module_base.R.mipmap.gnc_cangku,
|
||||||
|
"冷库登记"
|
||||||
|
)
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
else -> {
|
else -> {
|
||||||
|
|||||||
208
app/src/main/res/layout/activity_cold_storage.xml
Normal file
208
app/src/main/res/layout/activity_cold_storage.xml
Normal file
@@ -0,0 +1,208 @@
|
|||||||
|
<?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.search.layout.SearchLayoutType" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="viewModel"
|
||||||
|
type="com.lukouguoji.aerologic.page.coldStorage.list.ColdStorageViewModel" />
|
||||||
|
</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" />
|
||||||
|
|
||||||
|
<!-- 搜索区域 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<!-- 选择进港或出港 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"选择进港或出港"}'
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
list="@{viewModel.ieFlagList}"
|
||||||
|
value="@={viewModel.ieFlag}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 运单号 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入运单号"}'
|
||||||
|
icon="@{@drawable/img_scan}"
|
||||||
|
setOnIconClickListener="@{(v)-> viewModel.scanWbNo()}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.wbNo}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 货物状态 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请选择货物状态"}'
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
list="@{viewModel.statusList}"
|
||||||
|
value="@={viewModel.status}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 出库人 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入出库人"}'
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.outUserName}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 入库人 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入入库人"}'
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.inUserName}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 搜索按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:gravity="center_vertical|start"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:paddingHorizontal="12dp">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:onClick="@{()-> viewModel.searchClick()}"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_search" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 列表 -->
|
||||||
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
|
android:id="@+id/srl"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rv"
|
||||||
|
itemLayoutId="@{viewModel.itemLayoutId}"
|
||||||
|
viewHolder="@{viewModel.itemViewHolder}"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:overScrollMode="never"
|
||||||
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
|
tools:itemCount="3"
|
||||||
|
tools:listitem="@layout/item_cold_storage" />
|
||||||
|
|
||||||
|
</com.scwang.smart.refresh.layout.SmartRefreshLayout>
|
||||||
|
|
||||||
|
<!-- 底部统计和操作按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@android:color/white"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:paddingHorizontal="15dp">
|
||||||
|
|
||||||
|
<!-- 全选按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:onClick="@{()-> viewModel.checkAllClick()}"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/checkIcon"
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:src="@drawable/img_check_all" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="全选"
|
||||||
|
android:textColor="@color/color_66"
|
||||||
|
android:textSize="18sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 统计信息 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text='@{"合计:"+viewModel.totalCount+"票"}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:text='@{"总件数:"+viewModel.totalPc}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:text='@{"总重量:"+viewModel.totalWeight}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 完成出库按钮 -->
|
||||||
|
<TextView
|
||||||
|
style="@style/tv_bottom_btn"
|
||||||
|
android:onClick="@{()-> viewModel.completeOut()}"
|
||||||
|
android:text="完成出库" />
|
||||||
|
|
||||||
|
<!-- 完成入库按钮 -->
|
||||||
|
<TextView
|
||||||
|
style="@style/tv_bottom_btn"
|
||||||
|
android:onClick="@{()-> viewModel.completeIn()}"
|
||||||
|
android:text="完成入库" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</layout>
|
||||||
167
app/src/main/res/layout/activity_uld_edit.xml
Normal file
167
app/src/main/res/layout/activity_uld_edit.xml
Normal file
@@ -0,0 +1,167 @@
|
|||||||
|
<?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="com.lukouguoji.module_base.common.DetailsPageType" />
|
||||||
|
<variable
|
||||||
|
name="viewModel"
|
||||||
|
type="com.lukouguoji.aerologic.page.uld.edit.UldEditViewModel" />
|
||||||
|
</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">
|
||||||
|
|
||||||
|
<!-- Row 1: ULD编号 / 状态 / 自重 -->
|
||||||
|
<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="@{viewModel.pageType == DetailsPageType.Add}"
|
||||||
|
hint='@{"请输入ULD编号"}'
|
||||||
|
title='@{"ULD编号"}'
|
||||||
|
titleLength="@{7}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={viewModel.uldBean.uld}' />
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
enable="@{viewModel.pageType != DetailsPageType.Details}"
|
||||||
|
hint='@{"请选择状态"}'
|
||||||
|
list="@{viewModel.statusList}"
|
||||||
|
title='@{"状态"}'
|
||||||
|
titleLength="@{5}"
|
||||||
|
type="@{DataLayoutType.SPINNER}"
|
||||||
|
value='@={viewModel.uldBean.status}' />
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
enable="@{viewModel.pageType != DetailsPageType.Details}"
|
||||||
|
hint='@{"请输入自重"}'
|
||||||
|
title='@{"自重"}'
|
||||||
|
titleLength="@{5}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={viewModel.uldBean.uldWeight}' />
|
||||||
|
|
||||||
|
</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="@{viewModel.pageType != DetailsPageType.Details}"
|
||||||
|
hint='@{"请输入最大装载容积"}'
|
||||||
|
title='@{"最大装载容积"}'
|
||||||
|
titleLength="@{7}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={viewModel.uldBean.maxVolume}' />
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
enable="@{viewModel.pageType != DetailsPageType.Details}"
|
||||||
|
hint='@{"请输入最大载重"}'
|
||||||
|
title='@{"最大载重"}'
|
||||||
|
titleLength="@{5}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={viewModel.uldBean.maxWeight}' />
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
enable="@{viewModel.pageType != DetailsPageType.Details}"
|
||||||
|
hint='@{"请选择所属航司"}'
|
||||||
|
list="@{viewModel.carrierList}"
|
||||||
|
title='@{"所属航司"}'
|
||||||
|
titleLength="@{5}"
|
||||||
|
type="@{DataLayoutType.SPINNER}"
|
||||||
|
value='@={viewModel.uldBean.carrier}' />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 备注(全行,多行输入) -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="8dp"
|
||||||
|
enable="@{viewModel.pageType != DetailsPageType.Details}"
|
||||||
|
hint='@{"请输入备注"}'
|
||||||
|
inputHeight="@{80}"
|
||||||
|
title='@{"备注"}'
|
||||||
|
titleLength="@{3}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={viewModel.uldBean.remark}' />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 底部操作按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="56dp"
|
||||||
|
android:layout_marginTop="24dp"
|
||||||
|
android:gravity="center"
|
||||||
|
visible="@{viewModel.pageType != DetailsPageType.Details}">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/tv_bottom_btn"
|
||||||
|
android:layout_width="120dp"
|
||||||
|
android:layout_marginEnd="20dp"
|
||||||
|
android:onClick="@{()-> viewModel.onCancelClick()}"
|
||||||
|
android:text="取消" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
style="@style/tv_bottom_btn"
|
||||||
|
android:layout_width="120dp"
|
||||||
|
android:onClick="@{()-> viewModel.onSaveClick()}"
|
||||||
|
android:text="保存" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</ScrollView>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</layout>
|
||||||
119
app/src/main/res/layout/activity_uld_list.xml
Normal file
119
app/src/main/res/layout/activity_uld_list.xml
Normal file
@@ -0,0 +1,119 @@
|
|||||||
|
<?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.search.layout.SearchLayoutType" />
|
||||||
|
<variable
|
||||||
|
name="viewModel"
|
||||||
|
type="com.lukouguoji.aerologic.page.uld.list.UldListViewModel" />
|
||||||
|
</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" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"选择状态"}'
|
||||||
|
list="@{viewModel.statusList}"
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
value="@={viewModel.status}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"选择所属航司"}'
|
||||||
|
list="@{viewModel.carrierList}"
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
value="@={viewModel.uldSuffix}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入ULD编号"}'
|
||||||
|
icon="@{@drawable/img_scan}"
|
||||||
|
setOnIconClickListener="@{()-> viewModel.onUldScanClick()}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.uldNo}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_vertical|start"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:paddingHorizontal="24dp">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:onClick="@{()-> viewModel.refresh()}"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_search" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:layout_marginLeft="16dp"
|
||||||
|
android:onClick="@{()-> viewModel.onAddClick()}"
|
||||||
|
android:padding="4dp"
|
||||||
|
android:src="@drawable/img_add" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
|
android:id="@+id/srl"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rv"
|
||||||
|
itemLayoutId="@{viewModel.itemLayoutId}"
|
||||||
|
viewHolder="@{viewModel.itemViewHolder}"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
|
tools:listitem="@layout/item_uld_list" />
|
||||||
|
|
||||||
|
</com.scwang.smart.refresh.layout.SmartRefreshLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:paddingHorizontal="15dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:text='@{"合计:" + viewModel.count + "条"}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</layout>
|
||||||
283
app/src/main/res/layout/item_cold_storage.xml
Normal file
283
app/src/main/res/layout/item_cold_storage.xml
Normal file
@@ -0,0 +1,283 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<data>
|
||||||
|
|
||||||
|
<import type="android.view.View" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="bean"
|
||||||
|
type="com.lukouguoji.module_base.bean.ColdStorageBean" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="position"
|
||||||
|
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:gravity="center_vertical"
|
||||||
|
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_marginLeft="15dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<!-- 第一行:运单号 | 件数 | 入库人 | 入库时间 | 在库状态 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
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="运单号:"
|
||||||
|
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" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 件数 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.7"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
completeSpace="@{5}"
|
||||||
|
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" />
|
||||||
|
|
||||||
|
</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="@{5}"
|
||||||
|
android:text="入库人:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.inUserName}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</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="入库时间:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.inDate}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</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="@{5}"
|
||||||
|
android:text="在库状态:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.status}"
|
||||||
|
android:textColor='@{bean.status.equals("已出库") ? @color/text_red : bean.status.equals("已入库") ? @color/text_green : @color/text_normal}'
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 第二行:在库时长 | 重量 | 出库人 | 出库时间 -->
|
||||||
|
<LinearLayout
|
||||||
|
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="@{5}"
|
||||||
|
android:text="在库时长:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.storageDuration}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 重量 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.7"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:text="重量:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{String.valueOf((int)bean.wt)}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</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="@{5}"
|
||||||
|
android:text="出库人:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.outUserName}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</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="出库时间:"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.outDate}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 占位,与第一行在库状态对齐 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.8"
|
||||||
|
android:orientation="horizontal" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</layout>
|
||||||
240
app/src/main/res/layout/item_uld_list.xml
Normal file
240
app/src/main/res/layout/item_uld_list.xml
Normal file
@@ -0,0 +1,240 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
<data>
|
||||||
|
<variable
|
||||||
|
name="bean"
|
||||||
|
type="com.lukouguoji.module_base.bean.ULDBean" />
|
||||||
|
</data>
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<com.mcxtzhang.swipemenulib.SwipeMenuLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<FrameLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:id="@+id/ll_content"
|
||||||
|
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">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/iv_icon"
|
||||||
|
android:layout_width="40dp"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:src="@drawable/img_plane"
|
||||||
|
tools: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">
|
||||||
|
|
||||||
|
<!-- ULD编号 -->
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1.5"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="ULD编号:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.uld}"
|
||||||
|
android:textColor="@color/colorPrimary" />
|
||||||
|
|
||||||
|
</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
|
||||||
|
completeSpace="@{3}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="状态:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.statusName()}"
|
||||||
|
android:textColor='@{bean.status.equals("0") ? @color/text_normal : @color/red}' />
|
||||||
|
|
||||||
|
</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
|
||||||
|
completeSpace="@{3}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="自重:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.uldWeight}" />
|
||||||
|
|
||||||
|
</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
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="所属航司:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.carrier}" />
|
||||||
|
|
||||||
|
</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="@{7}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="最大装载容积:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.maxVolume}" />
|
||||||
|
|
||||||
|
</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.5"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="最大载重:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.maxWeight}" />
|
||||||
|
|
||||||
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|
||||||
|
<!-- 备注 -->
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="3.6"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
completeSpace="@{3}"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="备注:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.remark}" />
|
||||||
|
|
||||||
|
</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>
|
||||||
|
|
||||||
|
</FrameLayout>
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_modify"
|
||||||
|
style="@style/tv_item_action"
|
||||||
|
android:background="#8313ef"
|
||||||
|
android:text="修改" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tv_delete"
|
||||||
|
style="@style/tv_item_action"
|
||||||
|
android:background="@color/red"
|
||||||
|
android:text="删除" />
|
||||||
|
|
||||||
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|
||||||
|
</com.mcxtzhang.swipemenulib.SwipeMenuLayout>
|
||||||
|
|
||||||
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
</layout>
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.lukouguoji.module_base.bean
|
||||||
|
|
||||||
|
import androidx.databinding.ObservableBoolean
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记 Bean
|
||||||
|
*/
|
||||||
|
class ColdStorageBean {
|
||||||
|
var id: Long = 0
|
||||||
|
var wbNo: String = "" // 运单号
|
||||||
|
var pc: Int = 0 // 件数
|
||||||
|
var wt: Double = 0.0 // 重量
|
||||||
|
var inUserName: String = "" // 入库人
|
||||||
|
var inDate: String = "" // 入库时间
|
||||||
|
var outUserName: String = "" // 出库人
|
||||||
|
var outDate: String = "" // 出库时间
|
||||||
|
var storageDuration: String = "" // 在库时长
|
||||||
|
var status: String = "" // 在库状态
|
||||||
|
var ieFlag: String = "" // 进出港标识
|
||||||
|
|
||||||
|
// 多选状态
|
||||||
|
val checked: ObservableBoolean = ObservableBoolean(false)
|
||||||
|
var isSelected: Boolean
|
||||||
|
get() = checked.get()
|
||||||
|
set(value) = checked.set(value)
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package com.lukouguoji.module_base.bean
|
||||||
|
|
||||||
|
import androidx.databinding.ObservableBoolean
|
||||||
|
|
||||||
|
class IntImpAccidentVisaBean {
|
||||||
|
var id: Long = 0
|
||||||
|
var fdate: String = "" // 航班日期
|
||||||
|
var fno: String = "" // 航班号
|
||||||
|
var fdep: String = "" // 始发站
|
||||||
|
var fdest: String = "" // 目的站
|
||||||
|
var wbNo: String = "" // 运单号
|
||||||
|
var totalPc: Int = 0 // 运单总件数
|
||||||
|
var totalWeight: Double = 0.0 // 运单总重量
|
||||||
|
var abnPc: Int = 0 // 不正常件数
|
||||||
|
var opName: String = "" // 经办人
|
||||||
|
var opDate: String = "" // 经办时间
|
||||||
|
|
||||||
|
val checked: ObservableBoolean = ObservableBoolean(false)
|
||||||
|
|
||||||
|
var isSelected: Boolean
|
||||||
|
get() = checked.get()
|
||||||
|
set(value) = checked.set(value)
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package com.lukouguoji.module_base.bean
|
||||||
|
|
||||||
|
import androidx.databinding.ObservableBoolean
|
||||||
|
import java.io.Serializable
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港提取出库-列表数据Bean
|
||||||
|
* 对应API: IntImpPickUpDlv/pageQuery
|
||||||
|
*/
|
||||||
|
class IntImpPickUpDLVBean : Serializable {
|
||||||
|
var id: Long = 0 // 主键ID
|
||||||
|
var wbNo: String = "" // 运单号
|
||||||
|
var no: String = "" // 主单号
|
||||||
|
var prefix: String = "" // 主单前缀
|
||||||
|
var hno: String = "" // 分单号
|
||||||
|
var agentCode: String = "" // 代理人代码
|
||||||
|
var agentName: String = "" // 代理人名称
|
||||||
|
var flight: String = "" // 航班信息
|
||||||
|
var fno: String = "" // 航班号
|
||||||
|
var fdate: String = "" // 航班日期
|
||||||
|
var pc: Long = 0 // 件数
|
||||||
|
var weight: Double = 0.0 // 重量
|
||||||
|
var cashWeight: Double = 0.0 // 计费重量
|
||||||
|
var pkId: String = "" // 提货编号(提货单号)
|
||||||
|
var location: String = "" // 库位
|
||||||
|
var chargeTime: String = "" // 缴费时间(提取时间)
|
||||||
|
var dlvTime: String = "" // 出库时间
|
||||||
|
var goods: String = "" // 品名
|
||||||
|
var spCode: String = "" // 特码
|
||||||
|
var pickFlag: String = "" // 提取出库标识
|
||||||
|
var chargeFlag: String = "" // 提取标识
|
||||||
|
var serialNo: Long = 0 // 收费记录项目序号
|
||||||
|
var amount: Double = 0.0 // 总金额
|
||||||
|
var optCharge: Double = 0.0 // 服务费
|
||||||
|
var whsCharge: Double = 0.0 // 仓储费
|
||||||
|
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 chargeId: String = "" // 收费员
|
||||||
|
var chargeName: String = "" // 收费员名称
|
||||||
|
var dlvId: String = ""
|
||||||
|
var dlvIdType: String = ""
|
||||||
|
var dlvName: String = ""
|
||||||
|
var dlvPhone: String = ""
|
||||||
|
var locFlag: String = ""
|
||||||
|
var origin: String = ""
|
||||||
|
var refId: String = ""
|
||||||
|
var receiptNo: String = ""
|
||||||
|
var chgMode: String = ""
|
||||||
|
var billReviewStatus: String = ""
|
||||||
|
var billAgentRemark: String = ""
|
||||||
|
var awbPc: Long = 0
|
||||||
|
|
||||||
|
// ========== UI扩展字段 ==========
|
||||||
|
val checked: ObservableBoolean = ObservableBoolean(false)
|
||||||
|
|
||||||
|
var isSelected: Boolean
|
||||||
|
get() = checked.get()
|
||||||
|
set(value) = checked.set(value)
|
||||||
|
}
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
package com.lukouguoji.module_base.bean
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询-主运单数据模型
|
||||||
|
* 对应接口:/IntImpSearch/pageQuery 返回的列表项 (GjjSearchMaWb)
|
||||||
|
*/
|
||||||
|
data class IntImpQueryBean(
|
||||||
|
var maWbId: Long? = null, // 主单主键ID
|
||||||
|
var wbNo: String? = null, // 运单号
|
||||||
|
var prefix: String? = null, // 运单号前缀
|
||||||
|
var no: String? = null, // 运单号主体
|
||||||
|
|
||||||
|
// ==================== 货物信息 ====================
|
||||||
|
var awbPc: Long? = null, // 运单件数
|
||||||
|
var awbWeight: Double? = null, // 运单重量
|
||||||
|
var inPc: Long? = null, // 入库件数
|
||||||
|
var inWeight: Double? = null, // 入库重量
|
||||||
|
var cashWeight: Double? = null, // 计费重量
|
||||||
|
var goods: String? = null, // 品名(英)
|
||||||
|
var goodsCn: String? = null, // 品名(中)
|
||||||
|
var packageType: String? = null, // 包装类型
|
||||||
|
var unNumber: String? = null, // UN编号
|
||||||
|
|
||||||
|
// ==================== 航班信息 ====================
|
||||||
|
var flight: String? = null, // 航班: 日期/航班号
|
||||||
|
var fno: String? = null, // 航班号
|
||||||
|
var fdate: String? = null, // 航班日期
|
||||||
|
var range: String? = null, // 航程 (如 LAX-HFE)
|
||||||
|
var dest: String? = null, // 目的地
|
||||||
|
var origin: String? = null, // 货源地
|
||||||
|
var by1: String? = null, // 承运人
|
||||||
|
|
||||||
|
// ==================== 代理与运单类型 ====================
|
||||||
|
var agentCode: String? = null, // 代理人code
|
||||||
|
var agentName: String? = null, // 代理人名称
|
||||||
|
var awbType: String? = null, // 运单类型code
|
||||||
|
var awbName: String? = null, // 运单类型名称
|
||||||
|
var businessType: String? = null, // 业务类型code
|
||||||
|
var businessName: String? = null, // 业务类型名称
|
||||||
|
|
||||||
|
// ==================== 特码 ====================
|
||||||
|
var spCode: String? = null, // 特码
|
||||||
|
|
||||||
|
// ==================== 时间信息 ====================
|
||||||
|
var inDate: String? = null, // 入库时间
|
||||||
|
var dlvTime: String? = null, // 出库时间
|
||||||
|
|
||||||
|
// ==================== 状态信息 ====================
|
||||||
|
var mftStatus: String? = null, // 原始舱单状态
|
||||||
|
var tallyStatus: String? = null, // 理货申报状态
|
||||||
|
var lockState: Int? = null, // 锁定状态(0:未锁, 1:锁定)
|
||||||
|
var command: String? = null, // 海关放行
|
||||||
|
|
||||||
|
// ==================== 其他 ====================
|
||||||
|
var remark: String? = null, // 备注
|
||||||
|
var activeId: Long? = null // 有效值
|
||||||
|
)
|
||||||
@@ -15,6 +15,16 @@ data class ULDBean(
|
|||||||
var uld: String = "",
|
var uld: String = "",
|
||||||
var uldFlag: String = "",
|
var uldFlag: String = "",
|
||||||
var uldType: String = "",
|
var uldType: String = "",
|
||||||
|
// 状态 0:正常 1:故障
|
||||||
|
var status: String = "",
|
||||||
|
// 备注
|
||||||
|
var remark: String = "",
|
||||||
){
|
){
|
||||||
val checked = ObservableBoolean(false)
|
val checked = ObservableBoolean(false)
|
||||||
|
|
||||||
|
fun statusName(): String = when (status) {
|
||||||
|
"0" -> "正常"
|
||||||
|
"1" -> "故障"
|
||||||
|
else -> status
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -271,6 +271,8 @@ interface Constant {
|
|||||||
const val IntImpManifest = "AppIntImpManifest" //进港舱单
|
const val IntImpManifest = "AppIntImpManifest" //进港舱单
|
||||||
const val IntImpTally = "AppIntImpTally" //理货报告
|
const val IntImpTally = "AppIntImpTally" //理货报告
|
||||||
const val IntImpPickUpRecord = "AppIntImpPickUpRecord" //提取记录
|
const val IntImpPickUpRecord = "AppIntImpPickUpRecord" //提取记录
|
||||||
|
const val IntImpPickUpDLV = "AppIntImpPickUpDLV" //提取出库
|
||||||
|
const val IntImpAccidentVisa = "AppIntImpAccidentVisa" //事故签证
|
||||||
const val GjjManifestListActivity = "AppIntExpManifest" //舱单
|
const val GjjManifestListActivity = "AppIntExpManifest" //舱单
|
||||||
const val GjjTallyListActivity = "AppIntExpTally" //理货
|
const val GjjTallyListActivity = "AppIntExpTally" //理货
|
||||||
const val GjjGoodsListActivity = "AppIntExpGjjGoods" //货物交接
|
const val GjjGoodsListActivity = "AppIntExpGjjGoods" //货物交接
|
||||||
@@ -326,6 +328,12 @@ interface Constant {
|
|||||||
|
|
||||||
// 日志查询
|
// 日志查询
|
||||||
const val ComprehensiveLog = "AppComprehensiveLog"
|
const val ComprehensiveLog = "AppComprehensiveLog"
|
||||||
|
|
||||||
|
// ULD管理
|
||||||
|
const val ComprehensiveUld = "AppComprehensiveUld"
|
||||||
|
|
||||||
|
// 冷库登记
|
||||||
|
const val ComprehensiveColdStorage = "AppComprehensiveColdStorage"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ import com.lukouguoji.module_base.bean.BaseResultBean
|
|||||||
import com.lukouguoji.module_base.bean.BoxDetailsForCarIdBean
|
import com.lukouguoji.module_base.bean.BoxDetailsForCarIdBean
|
||||||
import com.lukouguoji.module_base.bean.CarBarBean
|
import com.lukouguoji.module_base.bean.CarBarBean
|
||||||
import com.lukouguoji.module_base.bean.CarOrUldBean
|
import com.lukouguoji.module_base.bean.CarOrUldBean
|
||||||
|
import com.lukouguoji.module_base.bean.ColdStorageBean
|
||||||
import com.lukouguoji.module_base.bean.DiBangChannelBean
|
import com.lukouguoji.module_base.bean.DiBangChannelBean
|
||||||
import com.lukouguoji.module_base.bean.DictBean
|
import com.lukouguoji.module_base.bean.DictBean
|
||||||
import com.lukouguoji.module_base.bean.DictIdValueBean
|
import com.lukouguoji.module_base.bean.DictIdValueBean
|
||||||
@@ -50,7 +51,10 @@ import com.lukouguoji.module_base.bean.GjjGoodsDetailsBean
|
|||||||
import com.lukouguoji.module_base.bean.GjjGoodsTypeBean
|
import com.lukouguoji.module_base.bean.GjjGoodsTypeBean
|
||||||
import com.lukouguoji.module_base.bean.GjjHandoverRecordBean
|
import com.lukouguoji.module_base.bean.GjjHandoverRecordBean
|
||||||
import com.lukouguoji.module_base.bean.GjjImportTally
|
import com.lukouguoji.module_base.bean.GjjImportTally
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpAccidentVisaBean
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpPickUpDLVBean
|
||||||
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
import com.lukouguoji.module_base.bean.IntImpPickUpRecordBean
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpQueryBean
|
||||||
import com.lukouguoji.module_base.bean.GjjManifest
|
import com.lukouguoji.module_base.bean.GjjManifest
|
||||||
import com.lukouguoji.module_base.bean.GjjManifestBean
|
import com.lukouguoji.module_base.bean.GjjManifestBean
|
||||||
import com.lukouguoji.module_base.bean.GjjPackTypeBean
|
import com.lukouguoji.module_base.bean.GjjPackTypeBean
|
||||||
@@ -969,6 +973,41 @@ interface Api {
|
|||||||
@POST("IntImpPickUpRecord/getDetails")
|
@POST("IntImpPickUpRecord/getDetails")
|
||||||
suspend fun getIntImpPickUpRecordDetails(@Body data: RequestBody): BaseResultBean<IntImpPickUpRecordBean>
|
suspend fun getIntImpPickUpRecordDetails(@Body data: RequestBody): BaseResultBean<IntImpPickUpRecordBean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港提取出库-分页查询
|
||||||
|
* 接口路径: /IntImpPickUpDlv/pageQuery
|
||||||
|
*/
|
||||||
|
@POST("IntImpPickUpDlv/pageQuery")
|
||||||
|
suspend fun getIntImpPickUpDLVList(@Body data: RequestBody): PageInfo<IntImpPickUpDLVBean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港提取出库-分页合计
|
||||||
|
* 接口路径: /IntImpPickUpDlv/pageQueryTotal
|
||||||
|
*/
|
||||||
|
@POST("IntImpPickUpDlv/pageQueryTotal")
|
||||||
|
suspend fun getIntImpPickUpDLVTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港提取出库-确认出库
|
||||||
|
* 接口路径: /IntImpPickUpDlv/pickUpOut
|
||||||
|
*/
|
||||||
|
@POST("IntImpPickUpDlv/pickUpOut")
|
||||||
|
suspend fun confirmIntImpPickUpDLV(@Body data: RequestBody): BaseResultBean<String>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询-分页
|
||||||
|
* 接口路径: /IntImpSearch/pageQuery
|
||||||
|
*/
|
||||||
|
@POST("IntImpSearch/pageQuery")
|
||||||
|
suspend fun getIntImpQueryList(@Body data: RequestBody): PageInfo<IntImpQueryBean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询-分页合计
|
||||||
|
* 接口路径: /IntImpSearch/pageQueryTotal
|
||||||
|
*/
|
||||||
|
@POST("IntImpSearch/pageQueryTotal")
|
||||||
|
suspend fun getIntImpQueryTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 国际出港待计重-分页搜索
|
* 国际出港待计重-分页搜索
|
||||||
* 接口路径: /IntExpCheckIn/pageQuery
|
* 接口路径: /IntExpCheckIn/pageQuery
|
||||||
@@ -1805,4 +1844,76 @@ interface Api {
|
|||||||
*/
|
*/
|
||||||
@POST("IntImpTally/pageQueryTotal")
|
@POST("IntImpTally/pageQueryTotal")
|
||||||
suspend fun getIntImpTallyTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
suspend fun getIntImpTallyTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
// 国际进港-事故签证
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际事故签证-分页搜索
|
||||||
|
*/
|
||||||
|
@POST("GjAccidentVisa/search")
|
||||||
|
suspend fun getIntImpAccidentVisaList(@Body data: RequestBody): PageInfo<IntImpAccidentVisaBean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际事故签证-删除(传选中的 Bean 列表)
|
||||||
|
*/
|
||||||
|
@POST("GjAccidentVisa/delete")
|
||||||
|
suspend fun deleteIntImpAccidentVisa(@Body data: RequestBody): BaseResultBean<String>
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
// ULD管理
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取-ULD-列表(分页)
|
||||||
|
*/
|
||||||
|
@POST("eqm/uld/pageQuery")
|
||||||
|
suspend fun getUldList(@Body data: RequestBody): PageInfo<ULDBean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增-ULD-信息
|
||||||
|
*/
|
||||||
|
@POST("eqm/uld/saveUld")
|
||||||
|
suspend fun saveUld(@Body data: RequestBody): BaseResultBean<Any>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新-ULD-信息
|
||||||
|
*/
|
||||||
|
@POST("eqm/uld/updateUld")
|
||||||
|
suspend fun updateUld(@Body data: RequestBody): BaseResultBean<Any>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除-ULD-信息
|
||||||
|
*/
|
||||||
|
@POST("eqm/uld/deleteUld")
|
||||||
|
suspend fun deleteUld(@Query("uld") uld: String): BaseResultBean<Any>
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
// 冷库登记
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记-分页查询
|
||||||
|
*/
|
||||||
|
@POST("ColdStorage/pageQuery")
|
||||||
|
suspend fun getColdStorageList(@Body data: RequestBody): PageInfo<ColdStorageBean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记-分页合计
|
||||||
|
*/
|
||||||
|
@POST("ColdStorage/pageQueryTotal")
|
||||||
|
suspend fun getColdStorageTotal(@Body data: RequestBody): BaseResultBean<ManifestTotalDto>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记-完成入库
|
||||||
|
*/
|
||||||
|
@POST("ColdStorage/completeIn")
|
||||||
|
suspend fun coldStorageCompleteIn(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 冷库登记-完成出库
|
||||||
|
*/
|
||||||
|
@POST("ColdStorage/completeOut")
|
||||||
|
suspend fun coldStorageCompleteOut(@Body data: RequestBody): BaseResultBean<Boolean>
|
||||||
}
|
}
|
||||||
@@ -177,6 +177,8 @@ object ARouterConstants {
|
|||||||
const val ACTIVITY_URL_INT_IMP_MANIFEST = "/gjj/IntImpManifestActivity" //国际进港 进港舱单
|
const val ACTIVITY_URL_INT_IMP_MANIFEST = "/gjj/IntImpManifestActivity" //国际进港 进港舱单
|
||||||
const val ACTIVITY_URL_INT_IMP_LOADING_LIST = "/gjj/IntImpLoadingListActivity" //国际进港 装机单(分拣理货)
|
const val ACTIVITY_URL_INT_IMP_LOADING_LIST = "/gjj/IntImpLoadingListActivity" //国际进港 装机单(分拣理货)
|
||||||
const val ACTIVITY_URL_INT_IMP_TALLY = "/gjj/IntImpTallyActivity" //国际进港 理货报告
|
const val ACTIVITY_URL_INT_IMP_TALLY = "/gjj/IntImpTallyActivity" //国际进港 理货报告
|
||||||
|
const val ACTIVITY_URL_INT_IMP_PICK_UP_DLV = "/gjj/IntImpPickUpDLVActivity" //国际进港 提取出库
|
||||||
|
const val ACTIVITY_URL_INT_IMP_ACCIDENT_VISA = "/gjj/IntImpAccidentVisaActivity" //国际进港 事故签证
|
||||||
|
|
||||||
///////////////// 航班查询模块
|
///////////////// 航班查询模块
|
||||||
/**
|
/**
|
||||||
@@ -211,4 +213,7 @@ object ARouterConstants {
|
|||||||
|
|
||||||
const val ACTIVITY_URL_PDA_ENTER = "/pda/PDAEnterActivity" //PDA入口
|
const val ACTIVITY_URL_PDA_ENTER = "/pda/PDAEnterActivity" //PDA入口
|
||||||
|
|
||||||
|
///////////////// 综合管理
|
||||||
|
const val ACTIVITY_URL_COLD_STORAGE = "/app/ColdStorageActivity" //冷库登记
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -36,7 +36,7 @@
|
|||||||
android:background="@null"
|
android:background="@null"
|
||||||
android:paddingStart="10dp"
|
android:paddingStart="10dp"
|
||||||
android:textColor="@color/text_normal"
|
android:textColor="@color/text_normal"
|
||||||
android:textColorHint="@color/text_gray"
|
android:textColorHint="@color/text_gray_l"
|
||||||
android:textSize="14sp" />
|
android:textSize="14sp" />
|
||||||
|
|
||||||
<Spinner
|
<Spinner
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ import com.scwang.smart.refresh.layout.api.RefreshLayout
|
|||||||
import java.text.SimpleDateFormat
|
import java.text.SimpleDateFormat
|
||||||
import java.util.*
|
import java.util.*
|
||||||
|
|
||||||
@Route(path = ARouterConstants.ACTIVITY_URL_GJJ_QUERY_LIST)
|
//@Route(path = ARouterConstants.ACTIVITY_URL_GJJ_QUERY_LIST)
|
||||||
class GjjQueryListActivity : BaseActivity(), View.OnClickListener {
|
class GjjQueryListActivity : BaseActivity(), View.OnClickListener {
|
||||||
private val currentTitleName = "国际进港查询"
|
private val currentTitleName = "国际进港查询"
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,51 @@
|
|||||||
|
package com.lukouguoji.gjj.activity
|
||||||
|
|
||||||
|
import android.app.Activity
|
||||||
|
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.ActivityIntImpAccidentVisaBinding
|
||||||
|
import com.lukouguoji.gjj.viewModel.IntImpAccidentVisaViewModel
|
||||||
|
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||||
|
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.router.ARouterConstants
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港-事故签证
|
||||||
|
*/
|
||||||
|
@Route(path = ARouterConstants.ACTIVITY_URL_INT_IMP_ACCIDENT_VISA)
|
||||||
|
class IntImpAccidentVisaActivity :
|
||||||
|
BaseBindingActivity<ActivityIntImpAccidentVisaBinding, IntImpAccidentVisaViewModel>() {
|
||||||
|
|
||||||
|
override fun layoutId() = R.layout.activity_int_imp_accident_visa
|
||||||
|
override fun viewModelClass() = IntImpAccidentVisaViewModel::class.java
|
||||||
|
|
||||||
|
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||||
|
setBackArrow("国际事故签证")
|
||||||
|
binding.viewModel = viewModel
|
||||||
|
|
||||||
|
viewModel.isAllChecked.observe(this) { isAllChecked ->
|
||||||
|
binding.checkIcon.alpha = if (isAllChecked) 1.0f else 0.5f
|
||||||
|
}
|
||||||
|
|
||||||
|
viewModel.pageModel.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, this)
|
||||||
|
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||||
|
super.onActivityResult(requestCode, resultCode, data)
|
||||||
|
if (requestCode == Constant.RequestCode.WAYBILL && resultCode == Activity.RESULT_OK) {
|
||||||
|
viewModel.wbNo.value = data?.getStringExtra(Constant.Result.CODED_CONTENT)
|
||||||
|
viewModel.searchClick()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
package com.lukouguoji.gjj.activity
|
||||||
|
|
||||||
|
import android.app.Activity
|
||||||
|
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.ActivityIntImpPickUpDlvBinding
|
||||||
|
import com.lukouguoji.gjj.viewModel.IntImpPickUpDLVViewModel
|
||||||
|
import com.lukouguoji.module_base.base.BaseBindingActivity
|
||||||
|
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.router.ARouterConstants
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港-提取出库
|
||||||
|
*/
|
||||||
|
@Route(path = ARouterConstants.ACTIVITY_URL_INT_IMP_PICK_UP_DLV)
|
||||||
|
class IntImpPickUpDLVActivity :
|
||||||
|
BaseBindingActivity<ActivityIntImpPickUpDlvBinding, IntImpPickUpDLVViewModel>() {
|
||||||
|
|
||||||
|
override fun layoutId() = R.layout.activity_int_imp_pick_up_dlv
|
||||||
|
override fun viewModelClass() = IntImpPickUpDLVViewModel::class.java
|
||||||
|
|
||||||
|
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||||
|
setBackArrow("国际进港出库")
|
||||||
|
binding.viewModel = viewModel
|
||||||
|
|
||||||
|
// 观察全选状态,更新图标透明度
|
||||||
|
viewModel.isAllChecked.observe(this) { isAllChecked ->
|
||||||
|
binding.checkIcon.alpha = if (isAllChecked) 1.0f else 0.5f
|
||||||
|
}
|
||||||
|
|
||||||
|
// 绑定分页
|
||||||
|
viewModel.pageModel.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, this)
|
||||||
|
|
||||||
|
// 监听刷新事件
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 初始化代理人列表
|
||||||
|
viewModel.initAgentList()
|
||||||
|
|
||||||
|
// 初始加载数据
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||||
|
super.onActivityResult(requestCode, resultCode, data)
|
||||||
|
if (resultCode == Activity.RESULT_OK) {
|
||||||
|
viewModel.onActivityResult(requestCode, resultCode, data)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,51 @@
|
|||||||
|
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.ActivityIntImpQueryBinding
|
||||||
|
import com.lukouguoji.gjj.viewModel.IntImpQueryViewModel
|
||||||
|
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.getLifecycleOwner
|
||||||
|
import com.lukouguoji.module_base.router.ARouterConstants
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询列表页
|
||||||
|
*/
|
||||||
|
@Route(path = ARouterConstants.ACTIVITY_URL_GJJ_QUERY_LIST)
|
||||||
|
class IntImpQueryActivity :
|
||||||
|
BaseBindingActivity<ActivityIntImpQueryBinding, IntImpQueryViewModel>() {
|
||||||
|
|
||||||
|
override fun layoutId() = R.layout.activity_int_imp_query
|
||||||
|
|
||||||
|
override fun viewModelClass() = IntImpQueryViewModel::class.java
|
||||||
|
|
||||||
|
override fun initOnCreate(savedInstanceState: Bundle?) {
|
||||||
|
setBackArrow("进港查询")
|
||||||
|
|
||||||
|
binding.viewModel = viewModel
|
||||||
|
|
||||||
|
viewModel.pageModel
|
||||||
|
.bindSmartRefreshLayout(binding.srl, binding.rv, viewModel, getLifecycleOwner())
|
||||||
|
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).observe(this) {
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
viewModel.initAgentList()
|
||||||
|
|
||||||
|
viewModel.refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
companion object {
|
||||||
|
@JvmStatic
|
||||||
|
fun start(context: Context) {
|
||||||
|
context.startActivity(Intent(context, IntImpQueryActivity::class.java))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,87 @@
|
|||||||
|
package com.lukouguoji.gjj.dialog
|
||||||
|
|
||||||
|
import android.content.Context
|
||||||
|
import android.content.res.ColorStateList
|
||||||
|
import android.graphics.Color
|
||||||
|
import android.view.View
|
||||||
|
import android.widget.ImageView
|
||||||
|
import android.widget.TextView
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import com.lukouguoji.gjj.R
|
||||||
|
import com.lukouguoji.gjj.databinding.DialogIntImpQueryFilterBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseDialogModel
|
||||||
|
import com.lxj.xpopup.XPopup
|
||||||
|
import com.lxj.xpopup.enums.PopupPosition
|
||||||
|
import dev.DevUtils
|
||||||
|
import dev.utils.app.info.KeyValue
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询筛选抽屉
|
||||||
|
*/
|
||||||
|
class IntImpQueryFilterDialogModel(
|
||||||
|
val spCode: MutableLiveData<String>,
|
||||||
|
val flightNo: MutableLiveData<String>,
|
||||||
|
val dest: MutableLiveData<String>,
|
||||||
|
val awbType: MutableLiveData<String>,
|
||||||
|
val businessType: MutableLiveData<String>,
|
||||||
|
val goodsCn: MutableLiveData<String>,
|
||||||
|
private val onConfirm: () -> Unit
|
||||||
|
) : BaseDialogModel<DialogIntImpQueryFilterBinding>(DIALOG_TYPE_DRAWER) {
|
||||||
|
|
||||||
|
val awbTypeList = MutableLiveData(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("主单", "1"),
|
||||||
|
KeyValue("分单", "2")
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
val businessTypeList = MutableLiveData(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("普货", "1"),
|
||||||
|
KeyValue("特货", "2")
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
override fun layoutId() = R.layout.dialog_int_imp_query_filter
|
||||||
|
|
||||||
|
override fun onBuild(builder: XPopup.Builder) {
|
||||||
|
super.onBuild(builder)
|
||||||
|
builder.popupPosition(PopupPosition.Right)
|
||||||
|
val activity = DevUtils.getTopActivity()
|
||||||
|
val activityWidth = activity.window.decorView.width
|
||||||
|
builder.maxWidth(activityWidth / 3)
|
||||||
|
builder.popupWidth(activityWidth / 3)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onDialogCreated(context: Context) {
|
||||||
|
binding.model = this
|
||||||
|
binding.lifecycleOwner = context as? androidx.lifecycle.LifecycleOwner
|
||||||
|
|
||||||
|
val titleColor = Color.parseColor("#666666")
|
||||||
|
binding.root.findViewById<TextView>(R.id.title_name)?.text = "筛选条件"
|
||||||
|
binding.root.findViewById<TextView>(R.id.title_name)?.setTextColor(titleColor)
|
||||||
|
binding.root.findViewById<TextView>(R.id.tool_tv_back)?.setTextColor(titleColor)
|
||||||
|
binding.root.findViewById<ImageView>(R.id.tool_iv_back)?.imageTintList = ColorStateList.valueOf(titleColor)
|
||||||
|
binding.root.findViewById<View>(R.id.toolbar)?.setBackgroundColor(Color.WHITE)
|
||||||
|
|
||||||
|
binding.root.findViewById<View>(R.id.tool_back)?.setOnClickListener {
|
||||||
|
dismiss()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onResetClick() {
|
||||||
|
spCode.value = ""
|
||||||
|
flightNo.value = ""
|
||||||
|
dest.value = ""
|
||||||
|
awbType.value = ""
|
||||||
|
businessType.value = ""
|
||||||
|
goodsCn.value = ""
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onConfirmClick() {
|
||||||
|
dismiss()
|
||||||
|
onConfirm()
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
package com.lukouguoji.gjj.holder
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.lukouguoji.gjj.databinding.ItemIntImpAccidentVisaBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpAccidentVisaBean
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港-事故签证 列表项ViewHolder
|
||||||
|
*/
|
||||||
|
class IntImpAccidentVisaViewHolder(view: View) :
|
||||||
|
BaseViewHolder<IntImpAccidentVisaBean, ItemIntImpAccidentVisaBinding>(view) {
|
||||||
|
|
||||||
|
override fun onBind(item: Any?, position: Int) {
|
||||||
|
val bean = getItemBean(item) ?: return
|
||||||
|
binding.bean = bean
|
||||||
|
binding.position = position
|
||||||
|
binding.executePendingBindings()
|
||||||
|
|
||||||
|
binding.ivIcon.setOnClickListener {
|
||||||
|
bean.checked.set(!bean.checked.get())
|
||||||
|
binding.executePendingBindings()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
package com.lukouguoji.gjj.holder
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.lukouguoji.gjj.databinding.ItemIntImpPickUpDlvBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpPickUpDLVBean
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港-提取出库 列表项ViewHolder
|
||||||
|
*/
|
||||||
|
class IntImpPickUpDLVViewHolder(view: View) :
|
||||||
|
BaseViewHolder<IntImpPickUpDLVBean, ItemIntImpPickUpDlvBinding>(view) {
|
||||||
|
|
||||||
|
override fun onBind(item: Any?, position: Int) {
|
||||||
|
val bean = getItemBean(item) ?: return
|
||||||
|
binding.bean = bean
|
||||||
|
binding.position = position
|
||||||
|
binding.executePendingBindings()
|
||||||
|
|
||||||
|
// 点击图标切换选中状态
|
||||||
|
binding.ivIcon.setOnClickListener {
|
||||||
|
bean.checked.set(!bean.checked.get())
|
||||||
|
binding.executePendingBindings()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
package com.lukouguoji.gjj.holder
|
||||||
|
|
||||||
|
import android.view.View
|
||||||
|
import com.lukouguoji.gjj.databinding.ItemIntImpQueryBinding
|
||||||
|
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpQueryBean
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询列表ViewHolder
|
||||||
|
*/
|
||||||
|
class IntImpQueryViewHolder(view: View) :
|
||||||
|
BaseViewHolder<IntImpQueryBean, ItemIntImpQueryBinding>(view) {
|
||||||
|
|
||||||
|
override fun onBind(item: Any?, position: Int) {
|
||||||
|
val bean = getItemBean(item)!!
|
||||||
|
binding.bean = bean
|
||||||
|
binding.executePendingBindings()
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,181 @@
|
|||||||
|
package com.lukouguoji.gjj.viewModel
|
||||||
|
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import androidx.lifecycle.viewModelScope
|
||||||
|
import com.lukouguoji.gjj.R
|
||||||
|
import com.lukouguoji.gjj.holder.IntImpAccidentVisaViewHolder
|
||||||
|
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||||
|
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.http.net.NetApply
|
||||||
|
import com.lukouguoji.module_base.impl.FlowBus
|
||||||
|
import com.lukouguoji.module_base.ktx.commonAdapter
|
||||||
|
import com.lukouguoji.module_base.ktx.formatDate
|
||||||
|
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.model.ScanModel
|
||||||
|
import dev.utils.app.info.KeyValue
|
||||||
|
import dev.utils.common.DateUtils
|
||||||
|
import kotlinx.coroutines.launch
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港-事故签证 ViewModel
|
||||||
|
*/
|
||||||
|
class IntImpAccidentVisaViewModel : BasePageViewModel() {
|
||||||
|
|
||||||
|
// ========== 搜索条件 ==========
|
||||||
|
val flightDate = MutableLiveData<String>(DateUtils.getCurrentTime().formatDate())
|
||||||
|
val flightNo = MutableLiveData("")
|
||||||
|
val fdep = MutableLiveData("") // 始发站(下拉)
|
||||||
|
val fdepList = MutableLiveData<List<KeyValue>>(emptyList())
|
||||||
|
val fdest = MutableLiveData("") // 目的站(禁止编辑,由航班查询返回)
|
||||||
|
val wbNo = MutableLiveData("") // 运单号
|
||||||
|
|
||||||
|
// ========== 航班查询 ==========
|
||||||
|
private var fid: String = ""
|
||||||
|
private var lastQueriedFlight = ""
|
||||||
|
|
||||||
|
// ========== 统计信息 ==========
|
||||||
|
val totalCount = MutableLiveData("0")
|
||||||
|
|
||||||
|
// ========== 全选状态 ==========
|
||||||
|
val isAllChecked = MutableLiveData(false)
|
||||||
|
|
||||||
|
init {
|
||||||
|
isAllChecked.observeForever { checked ->
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpAccidentVisaBean>
|
||||||
|
?: return@observeForever
|
||||||
|
list.forEach { it.checked.set(checked) }
|
||||||
|
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ========== 适配器配置 ==========
|
||||||
|
val itemViewHolder = IntImpAccidentVisaViewHolder::class.java
|
||||||
|
val itemLayoutId = R.layout.item_int_imp_accident_visa
|
||||||
|
|
||||||
|
// ========== 航班级联查询 ==========
|
||||||
|
|
||||||
|
fun onFlightDateInputComplete() {
|
||||||
|
lastQueriedFlight = ""
|
||||||
|
queryFlightIfReady()
|
||||||
|
}
|
||||||
|
|
||||||
|
fun onFlightNoInputComplete() {
|
||||||
|
queryFlightIfReady()
|
||||||
|
}
|
||||||
|
|
||||||
|
private fun queryFlightIfReady() {
|
||||||
|
val fdate = flightDate.value
|
||||||
|
val fno = flightNo.value
|
||||||
|
if (fdate.isNullOrEmpty() || fno.isNullOrEmpty()) 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!!
|
||||||
|
fid = flight.fid.noNull()
|
||||||
|
fdest.value = flight.fdest.noNull()
|
||||||
|
|
||||||
|
val list = mutableListOf(
|
||||||
|
KeyValue(flight.fdep.noNull(), flight.fdep.noNull()),
|
||||||
|
)
|
||||||
|
if (!flight.jtz.isNullOrEmpty()) {
|
||||||
|
list.add(KeyValue(flight.jtz.noNull(), flight.jtz.noNull()))
|
||||||
|
}
|
||||||
|
fdepList.value = list
|
||||||
|
fdep.value = flight.fdep.noNull()
|
||||||
|
} else {
|
||||||
|
fid = ""
|
||||||
|
fdest.value = ""
|
||||||
|
fdepList.value = emptyList()
|
||||||
|
fdep.value = ""
|
||||||
|
showToast(it.msg.noNull("获取航班信息失败"))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
onFailed = { _, _ ->
|
||||||
|
fid = ""
|
||||||
|
fdest.value = ""
|
||||||
|
fdepList.value = emptyList()
|
||||||
|
fdep.value = ""
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fun scanWbNo() {
|
||||||
|
ScanModel.startScan(getTopActivity(), Constant.RequestCode.WAYBILL)
|
||||||
|
}
|
||||||
|
|
||||||
|
fun searchClick() {
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
fun checkAllClick() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpAccidentVisaBean> ?: return
|
||||||
|
val shouldCheckAll = !isAllChecked.value!!
|
||||||
|
list.forEach { it.checked.set(shouldCheckAll) }
|
||||||
|
isAllChecked.value = shouldCheckAll
|
||||||
|
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||||
|
}
|
||||||
|
|
||||||
|
fun deleteClick() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpAccidentVisaBean> ?: return
|
||||||
|
val selected = list.filter { it.isSelected }
|
||||||
|
if (selected.isEmpty()) {
|
||||||
|
showToast("请选择要删除的数据")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
launchLoadingCollect({ NetApply.api.deleteIntImpAccidentVisa(selected.toRequestBody()) }) {
|
||||||
|
onSuccess = {
|
||||||
|
showToast("删除成功")
|
||||||
|
viewModelScope.launch {
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||||
|
}
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun getData() {
|
||||||
|
val filterParams = mutableMapOf<String, Any?>(
|
||||||
|
"fdep" to fdep.value?.ifEmpty { null },
|
||||||
|
"fdest" to fdest.value?.ifEmpty { null },
|
||||||
|
"wbNo" to wbNo.value?.ifEmpty { null }
|
||||||
|
)
|
||||||
|
if (fid.isNotEmpty()) {
|
||||||
|
filterParams["fid"] = fid
|
||||||
|
} else {
|
||||||
|
filterParams["fdate"] = flightDate.value?.ifEmpty { null }
|
||||||
|
filterParams["fno"] = flightNo.value?.ifEmpty { null }
|
||||||
|
}
|
||||||
|
|
||||||
|
val listParams = (filterParams + mapOf(
|
||||||
|
"pageNum" to pageModel.page,
|
||||||
|
"pageSize" to pageModel.limit
|
||||||
|
)).toRequestBody()
|
||||||
|
|
||||||
|
launchLoadingCollect({ NetApply.api.getIntImpAccidentVisaList(listParams) }) {
|
||||||
|
onSuccess = { pageInfo ->
|
||||||
|
pageModel.handleListBean(pageInfo.toBaseListBean())
|
||||||
|
totalCount.value = (pageInfo.total ?: 0).toString()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,183 @@
|
|||||||
|
package com.lukouguoji.gjj.viewModel
|
||||||
|
|
||||||
|
import android.app.Activity
|
||||||
|
import android.content.Intent
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import androidx.lifecycle.viewModelScope
|
||||||
|
import com.lukouguoji.gjj.R
|
||||||
|
import com.lukouguoji.gjj.holder.IntImpPickUpDLVViewHolder
|
||||||
|
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||||
|
import com.lukouguoji.module_base.bean.IntImpPickUpDLVBean
|
||||||
|
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.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 dev.utils.app.info.KeyValue
|
||||||
|
import kotlinx.coroutines.launch
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港-提取出库 ViewModel
|
||||||
|
*/
|
||||||
|
class IntImpPickUpDLVViewModel : BasePageViewModel() {
|
||||||
|
|
||||||
|
// ========== 搜索条件 ==========
|
||||||
|
val paymentDateStart = MutableLiveData("") // 缴费日期起
|
||||||
|
val paymentDateEnd = MutableLiveData("") // 缴费日期止
|
||||||
|
val agentCode = MutableLiveData("") // 代理人
|
||||||
|
val wbNo = MutableLiveData("") // 运单号
|
||||||
|
val pickUpNo = MutableLiveData("") // 提货单号
|
||||||
|
|
||||||
|
// ========== 下拉列表数据源 ==========
|
||||||
|
val agentList = MutableLiveData(listOf(KeyValue("全部", "")))
|
||||||
|
|
||||||
|
// ========== 统计信息 ==========
|
||||||
|
val totalCount = MutableLiveData("0") // 合计票数
|
||||||
|
val totalPc = MutableLiveData("0") // 总件数
|
||||||
|
val totalWeight = MutableLiveData("0") // 总重量
|
||||||
|
|
||||||
|
// ========== 全选状态 ==========
|
||||||
|
val isAllChecked = MutableLiveData(false)
|
||||||
|
|
||||||
|
init {
|
||||||
|
isAllChecked.observeForever { checked ->
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpPickUpDLVBean>
|
||||||
|
?: return@observeForever
|
||||||
|
list.forEach { it.checked.set(checked) }
|
||||||
|
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ========== 适配器配置 ==========
|
||||||
|
val itemViewHolder = IntImpPickUpDLVViewHolder::class.java
|
||||||
|
val itemLayoutId = R.layout.item_int_imp_pick_up_dlv
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 初始化代理人列表
|
||||||
|
*/
|
||||||
|
fun initAgentList() {
|
||||||
|
launchCollect({ NetApply.api.getIntImpAgentList() }) {
|
||||||
|
onSuccess = { result ->
|
||||||
|
val list = mutableListOf(KeyValue("全部", ""))
|
||||||
|
result.data?.forEach {
|
||||||
|
list.add(KeyValue(it.name ?: "", it.code ?: ""))
|
||||||
|
}
|
||||||
|
agentList.value = list
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 搜索按钮点击
|
||||||
|
*/
|
||||||
|
fun searchClick() {
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 扫码运单号
|
||||||
|
*/
|
||||||
|
fun scanWbNo() {
|
||||||
|
ScanModel.startScan(getTopActivity(), Constant.RequestCode.WAYBILL)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 扫码提货单号
|
||||||
|
*/
|
||||||
|
fun scanPickUpNo() {
|
||||||
|
ScanModel.startScan(getTopActivity(), Constant.RequestCode.gnj_chu_ku_list)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 全选按钮点击
|
||||||
|
*/
|
||||||
|
fun checkAllClick() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpPickUpDLVBean> ?: return
|
||||||
|
val shouldCheckAll = !isAllChecked.value!!
|
||||||
|
list.forEach { it.checked.set(shouldCheckAll) }
|
||||||
|
isAllChecked.value = shouldCheckAll
|
||||||
|
pageModel.rv?.commonAdapter()?.notifyDataSetChanged()
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 确认出库
|
||||||
|
*/
|
||||||
|
fun confirmOutbound() {
|
||||||
|
val list = pageModel.rv?.commonAdapter()?.items as? List<IntImpPickUpDLVBean> ?: return
|
||||||
|
val selectedItems = list.filter { it.isSelected }
|
||||||
|
|
||||||
|
if (selectedItems.isEmpty()) {
|
||||||
|
showToast("请选择要出库的记录")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
launchLoadingCollect({ NetApply.api.confirmIntImpPickUpDLV(selectedItems.toRequestBody()) }) {
|
||||||
|
onSuccess = {
|
||||||
|
showToast("确认出库成功")
|
||||||
|
viewModelScope.launch {
|
||||||
|
FlowBus.with<String>(ConstantEvent.EVENT_REFRESH).emit("refresh")
|
||||||
|
}
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取列表数据
|
||||||
|
*/
|
||||||
|
override fun getData() {
|
||||||
|
val filterParams = mapOf(
|
||||||
|
"beginDate" to paymentDateStart.value?.ifEmpty { null },
|
||||||
|
"endDate" to paymentDateEnd.value?.ifEmpty { null },
|
||||||
|
"agentCode" to agentCode.value?.ifEmpty { null },
|
||||||
|
"no" to wbNo.value?.ifEmpty { null },
|
||||||
|
"pkId" to pickUpNo.value?.ifEmpty { null }
|
||||||
|
)
|
||||||
|
|
||||||
|
val listParams = (filterParams + mapOf(
|
||||||
|
"page" to pageModel.page,
|
||||||
|
"limit" to pageModel.limit
|
||||||
|
)).toRequestBody()
|
||||||
|
|
||||||
|
val totalParams = filterParams.toRequestBody()
|
||||||
|
|
||||||
|
launchLoadingCollect({ NetApply.api.getIntImpPickUpDLVList(listParams) }) {
|
||||||
|
onSuccess = { result ->
|
||||||
|
pageModel.handleDataList(result.list)
|
||||||
|
pageModel.haveMore.postValue((result.pages) > pageModel.page)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
launchCollect({ NetApply.api.getIntImpPickUpDLVTotal(totalParams) }) {
|
||||||
|
onSuccess = { result ->
|
||||||
|
val data = result.data
|
||||||
|
totalCount.value = (data?.wbNumber ?: 0).toString()
|
||||||
|
totalPc.value = (data?.totalPc ?: 0).toString()
|
||||||
|
totalWeight.value = (data?.totalWeight ?: 0.0).toString()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理扫码结果
|
||||||
|
*/
|
||||||
|
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||||
|
if (resultCode == Activity.RESULT_OK && data != null) {
|
||||||
|
when (requestCode) {
|
||||||
|
Constant.RequestCode.WAYBILL -> {
|
||||||
|
wbNo.value = data.getStringExtra(Constant.Result.CODED_CONTENT)
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
Constant.RequestCode.gnj_chu_ku_list -> {
|
||||||
|
pickUpNo.value = data.getStringExtra(Constant.Result.CODED_CONTENT)
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,161 @@
|
|||||||
|
package com.lukouguoji.gjj.viewModel
|
||||||
|
|
||||||
|
import android.app.Activity
|
||||||
|
import android.content.Intent
|
||||||
|
import androidx.lifecycle.MutableLiveData
|
||||||
|
import com.lukouguoji.gjj.R
|
||||||
|
import com.lukouguoji.gjj.dialog.IntImpQueryFilterDialogModel
|
||||||
|
import com.lukouguoji.gjj.holder.IntImpQueryViewHolder
|
||||||
|
import com.lukouguoji.module_base.base.BasePageViewModel
|
||||||
|
import com.lukouguoji.module_base.common.Constant
|
||||||
|
import com.lukouguoji.module_base.http.net.NetApply
|
||||||
|
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 dev.utils.app.info.KeyValue
|
||||||
|
import dev.utils.common.DateUtils
|
||||||
|
import com.lukouguoji.module_base.ktx.formatDate
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 国际进港查询ViewModel
|
||||||
|
*/
|
||||||
|
class IntImpQueryViewModel : BasePageViewModel() {
|
||||||
|
|
||||||
|
// ==================== 搜索条件 ====================
|
||||||
|
val flightDateStart = MutableLiveData<String>(DateUtils.getCurrentTime().formatDate())
|
||||||
|
val flightDateEnd = MutableLiveData("")
|
||||||
|
val agentId = MutableLiveData("")
|
||||||
|
val outStatus = MutableLiveData("")
|
||||||
|
val waybillNo = MutableLiveData("")
|
||||||
|
|
||||||
|
// ==================== 下拉列表 ====================
|
||||||
|
val agentList = MutableLiveData(listOf(KeyValue("全部", "")))
|
||||||
|
|
||||||
|
val outStatusList = MutableLiveData(
|
||||||
|
listOf(
|
||||||
|
KeyValue("全部", ""),
|
||||||
|
KeyValue("未出库", "0"),
|
||||||
|
KeyValue("已出库", "1")
|
||||||
|
)
|
||||||
|
)
|
||||||
|
|
||||||
|
// ==================== 适配器配置 ====================
|
||||||
|
val itemViewHolder = IntImpQueryViewHolder::class.java
|
||||||
|
val itemLayoutId = R.layout.item_int_imp_query
|
||||||
|
|
||||||
|
// ==================== 统计数据 ====================
|
||||||
|
val totalCount = MutableLiveData("0")
|
||||||
|
val totalPc = MutableLiveData("0")
|
||||||
|
val totalWeight = MutableLiveData("0")
|
||||||
|
|
||||||
|
// ==================== 筛选条件 ====================
|
||||||
|
val spCode = MutableLiveData("")
|
||||||
|
val flightNo = MutableLiveData("")
|
||||||
|
val dest = MutableLiveData("")
|
||||||
|
val awbType = MutableLiveData("")
|
||||||
|
val businessType = MutableLiveData("")
|
||||||
|
val goodsCn = MutableLiveData("")
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
// 方法区
|
||||||
|
///////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
fun waybillScanClick() {
|
||||||
|
ScanModel.startScan(getTopActivity(), Constant.RequestCode.WAYBILL)
|
||||||
|
}
|
||||||
|
|
||||||
|
fun searchClick() {
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
|
||||||
|
fun filterClick() {
|
||||||
|
val filterDialog = IntImpQueryFilterDialogModel(
|
||||||
|
spCode = spCode,
|
||||||
|
flightNo = flightNo,
|
||||||
|
dest = dest,
|
||||||
|
awbType = awbType,
|
||||||
|
businessType = businessType,
|
||||||
|
goodsCn = goodsCn,
|
||||||
|
onConfirm = { refresh() }
|
||||||
|
)
|
||||||
|
filterDialog.show()
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun getData() {
|
||||||
|
val listParams = mapOf(
|
||||||
|
"pageNum" to pageModel.page,
|
||||||
|
"pageSize" to pageModel.limit,
|
||||||
|
"beginDate" to flightDateStart.value!!.ifEmpty { null },
|
||||||
|
"endDate" to flightDateEnd.value!!.ifEmpty { null },
|
||||||
|
"agentCode" to agentId.value!!.ifEmpty { null },
|
||||||
|
"outState" to outStatus.value!!.ifEmpty { null },
|
||||||
|
"wbNo" to waybillNo.value!!.ifEmpty { null },
|
||||||
|
"spCode" to spCode.value!!.ifEmpty { null },
|
||||||
|
"fno" to flightNo.value!!.ifEmpty { null },
|
||||||
|
"dest" to dest.value!!.ifEmpty { null },
|
||||||
|
"awbType" to awbType.value!!.ifEmpty { null },
|
||||||
|
"businessType" to businessType.value!!.ifEmpty { null },
|
||||||
|
"goods" to goodsCn.value!!.ifEmpty { null }
|
||||||
|
).toRequestBody()
|
||||||
|
|
||||||
|
val totalParams = mapOf(
|
||||||
|
"beginDate" to flightDateStart.value!!.ifEmpty { null },
|
||||||
|
"endDate" to flightDateEnd.value!!.ifEmpty { null },
|
||||||
|
"agentCode" to agentId.value!!.ifEmpty { null },
|
||||||
|
"outState" to outStatus.value!!.ifEmpty { null },
|
||||||
|
"wbNo" to waybillNo.value!!.ifEmpty { null },
|
||||||
|
"spCode" to spCode.value!!.ifEmpty { null },
|
||||||
|
"fno" to flightNo.value!!.ifEmpty { null },
|
||||||
|
"dest" to dest.value!!.ifEmpty { null },
|
||||||
|
"awbType" to awbType.value!!.ifEmpty { null },
|
||||||
|
"businessType" to businessType.value!!.ifEmpty { null },
|
||||||
|
"goods" to goodsCn.value!!.ifEmpty { null }
|
||||||
|
).toRequestBody()
|
||||||
|
|
||||||
|
launchLoadingCollect({
|
||||||
|
NetApply.api.getIntImpQueryList(listParams)
|
||||||
|
}) {
|
||||||
|
onSuccess = { pageInfo ->
|
||||||
|
pageModel.handleListBean(pageInfo.toBaseListBean())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
launchCollect({
|
||||||
|
NetApply.api.getIntImpQueryTotal(totalParams)
|
||||||
|
}) {
|
||||||
|
onSuccess = { result ->
|
||||||
|
val data = result.data
|
||||||
|
totalCount.value = (data?.wbNumber ?: 0).toString()
|
||||||
|
totalPc.value = (data?.totalPc ?: 0).toString()
|
||||||
|
totalWeight.value = (data?.totalWeight ?: 0.0).toString()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {
|
||||||
|
if (resultCode == Activity.RESULT_OK && data != null) {
|
||||||
|
when (requestCode) {
|
||||||
|
Constant.RequestCode.WAYBILL -> {
|
||||||
|
waybillNo.value = data.getStringExtra(Constant.Result.CODED_CONTENT)
|
||||||
|
refresh()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fun initAgentList() {
|
||||||
|
launchCollect({
|
||||||
|
NetApply.api.getIntImpAgentList()
|
||||||
|
}) {
|
||||||
|
onSuccess = { result ->
|
||||||
|
val list = mutableListOf(KeyValue("全部", ""))
|
||||||
|
result.data?.forEach {
|
||||||
|
list.add(KeyValue(it.name ?: "", it.code ?: ""))
|
||||||
|
}
|
||||||
|
agentList.value = list
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,198 @@
|
|||||||
|
<?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.search.layout.SearchLayoutType" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="viewModel"
|
||||||
|
type="com.lukouguoji.gjj.viewModel.IntImpAccidentVisaViewModel" />
|
||||||
|
</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" />
|
||||||
|
|
||||||
|
<!-- 搜索区域 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<!-- 航班日期 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请选择航班日期"}'
|
||||||
|
icon="@{@drawable/img_date}"
|
||||||
|
setRefreshCallBack="@{viewModel::onFlightDateInputComplete}"
|
||||||
|
type="@{SearchLayoutType.DATE}"
|
||||||
|
value="@={viewModel.flightDate}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 航班号 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入航班号"}'
|
||||||
|
setRefreshCallBack="@{viewModel::onFlightNoInputComplete}"
|
||||||
|
setUpperCaseAlphanumeric="@{true}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.flightNo}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 始发站(下拉,由航班查询填充) -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请选择始发站"}'
|
||||||
|
list="@{viewModel.fdepList}"
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
value="@={viewModel.fdep}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 目的站(禁止编辑,由航班查询返回) -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
enable="@{false}"
|
||||||
|
hint='@{"目的站"}'
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.fdest}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 运单号(含扫码) -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入运单号"}'
|
||||||
|
icon="@{@drawable/img_scan}"
|
||||||
|
setOnIconClickListener="@{(v)-> viewModel.scanWbNo()}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.wbNo}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 操作按钮区:搜索、新增、删除 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_vertical|start"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:paddingHorizontal="16dp">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:onClick="@{()-> viewModel.searchClick()}"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_search" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:layout_marginStart="8dp"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_add" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:layout_marginStart="8dp"
|
||||||
|
android:onClick="@{()-> viewModel.deleteClick()}"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_delete" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 列表 -->
|
||||||
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
|
android:id="@+id/srl"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rv"
|
||||||
|
itemLayoutId="@{viewModel.itemLayoutId}"
|
||||||
|
viewHolder="@{viewModel.itemViewHolder}"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:overScrollMode="never"
|
||||||
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
|
tools:itemCount="3"
|
||||||
|
tools:listitem="@layout/item_int_imp_accident_visa" />
|
||||||
|
|
||||||
|
</com.scwang.smart.refresh.layout.SmartRefreshLayout>
|
||||||
|
|
||||||
|
<!-- 底部统计栏 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:paddingHorizontal="15dp">
|
||||||
|
|
||||||
|
<!-- 全选按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:onClick="@{()-> viewModel.checkAllClick()}"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/checkIcon"
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:src="@drawable/img_check_all" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="全选"
|
||||||
|
android:textColor="@color/color_66"
|
||||||
|
android:textSize="18sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 统计信息 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text='@{"合计:"+viewModel.totalCount+"条"}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</layout>
|
||||||
197
module_gjj/src/main/res/layout/activity_int_imp_pick_up_dlv.xml
Normal file
197
module_gjj/src/main/res/layout/activity_int_imp_pick_up_dlv.xml
Normal file
@@ -0,0 +1,197 @@
|
|||||||
|
<?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.search.layout.SearchLayoutType" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="viewModel"
|
||||||
|
type="com.lukouguoji.gjj.viewModel.IntImpPickUpDLVViewModel" />
|
||||||
|
</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" />
|
||||||
|
|
||||||
|
<!-- 搜索区域 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<!-- 缴费日期起 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"选择缴费日期起"}'
|
||||||
|
icon="@{@drawable/img_date}"
|
||||||
|
type="@{SearchLayoutType.DATE}"
|
||||||
|
value="@={viewModel.paymentDateStart}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 缴费日期止 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"选择缴费日期止"}'
|
||||||
|
icon="@{@drawable/img_date}"
|
||||||
|
type="@{SearchLayoutType.DATE}"
|
||||||
|
value="@={viewModel.paymentDateEnd}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 代理人 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请选择代理人"}'
|
||||||
|
list="@{viewModel.agentList}"
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
value="@={viewModel.agentCode}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 运单号 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入运单号"}'
|
||||||
|
icon="@{@drawable/img_scan}"
|
||||||
|
setOnIconClickListener="@{(v)-> viewModel.scanWbNo()}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.wbNo}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 提货单号 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
hint='@{"请输入提货单号"}'
|
||||||
|
icon="@{@drawable/img_scan}"
|
||||||
|
setOnIconClickListener="@{(v)-> viewModel.scanPickUpNo()}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.pickUpNo}"
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1" />
|
||||||
|
|
||||||
|
<!-- 搜索按钮 -->
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:onClick="@{()-> viewModel.searchClick()}"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_search" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 列表 -->
|
||||||
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
|
android:id="@+id/srl"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rv"
|
||||||
|
itemLayoutId="@{viewModel.itemLayoutId}"
|
||||||
|
viewHolder="@{viewModel.itemViewHolder}"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:overScrollMode="never"
|
||||||
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
|
tools:itemCount="3"
|
||||||
|
tools:listitem="@layout/item_int_imp_pick_up_dlv" />
|
||||||
|
|
||||||
|
</com.scwang.smart.refresh.layout.SmartRefreshLayout>
|
||||||
|
|
||||||
|
<!-- 底部统计和操作按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@android:color/white"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:paddingHorizontal="15dp">
|
||||||
|
|
||||||
|
<!-- 全选按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:onClick="@{()-> viewModel.checkAllClick()}"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/checkIcon"
|
||||||
|
android:layout_width="24dp"
|
||||||
|
android:layout_height="24dp"
|
||||||
|
android:layout_marginEnd="5dp"
|
||||||
|
android:src="@drawable/img_check_all" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="全选"
|
||||||
|
android:textColor="@color/color_66"
|
||||||
|
android:textSize="18sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 统计信息 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text='@{"合计:" + viewModel.totalCount + "票"}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:text='@{"总件数:" + viewModel.totalPc}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:text='@{"总重量:" + viewModel.totalWeight}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="18sp"
|
||||||
|
android:textStyle="bold" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 确认出库按钮 -->
|
||||||
|
<TextView
|
||||||
|
style="@style/tv_bottom_btn"
|
||||||
|
android:onClick="@{()-> viewModel.confirmOutbound()}"
|
||||||
|
android:text="确认出库" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</layout>
|
||||||
177
module_gjj/src/main/res/layout/activity_int_imp_query.xml
Normal file
177
module_gjj/src/main/res/layout/activity_int_imp_query.xml
Normal file
@@ -0,0 +1,177 @@
|
|||||||
|
<?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.search.layout.SearchLayoutType" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="viewModel"
|
||||||
|
type="com.lukouguoji.gjj.viewModel.IntImpQueryViewModel" />
|
||||||
|
</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" />
|
||||||
|
|
||||||
|
<!-- 搜索区域 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginHorizontal="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<!-- 航班日期起 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
hint='@{"请选择开始日期"}'
|
||||||
|
icon="@{@drawable/img_date}"
|
||||||
|
type="@{SearchLayoutType.DATE}"
|
||||||
|
value="@={viewModel.flightDateStart}" />
|
||||||
|
|
||||||
|
<!-- 航班日期止 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
hint='@{"请选择结束日期"}'
|
||||||
|
icon="@{@drawable/img_date}"
|
||||||
|
type="@{SearchLayoutType.DATE}"
|
||||||
|
value="@={viewModel.flightDateEnd}" />
|
||||||
|
|
||||||
|
<!-- 代理人 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
hint='@{"请选择代理"}'
|
||||||
|
list="@{viewModel.agentList}"
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
value="@={viewModel.agentId}" />
|
||||||
|
|
||||||
|
<!-- 出库状态 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
hint='@{"请选择出库状态"}'
|
||||||
|
list="@{viewModel.outStatusList}"
|
||||||
|
type="@{SearchLayoutType.SPINNER}"
|
||||||
|
value="@={viewModel.outStatus}" />
|
||||||
|
|
||||||
|
<!-- 运单号 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.search.layout.PadSearchLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
hint='@{"请输入运单号"}'
|
||||||
|
icon="@{@drawable/img_scan}"
|
||||||
|
setOnIconClickListener="@{()-> viewModel.waybillScanClick()}"
|
||||||
|
type="@{SearchLayoutType.INPUT}"
|
||||||
|
value="@={viewModel.waybillNo}" />
|
||||||
|
|
||||||
|
<!-- 搜索和筛选按钮 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:gravity="center_vertical|start"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:paddingHorizontal="24dp">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:onClick="@{()-> viewModel.searchClick()}"
|
||||||
|
android:padding="2dp"
|
||||||
|
android:src="@drawable/img_search" />
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="36dp"
|
||||||
|
android:layout_height="36dp"
|
||||||
|
android:layout_marginLeft="16dp"
|
||||||
|
android:onClick="@{()-> viewModel.filterClick()}"
|
||||||
|
android:padding="5dp"
|
||||||
|
android:src="@drawable/img_filter" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 列表区域 -->
|
||||||
|
<com.scwang.smart.refresh.layout.SmartRefreshLayout
|
||||||
|
android:id="@+id/srl"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_weight="1">
|
||||||
|
|
||||||
|
<androidx.recyclerview.widget.RecyclerView
|
||||||
|
android:id="@+id/rv"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
itemLayoutId="@{viewModel.itemLayoutId}"
|
||||||
|
viewHolder="@{viewModel.itemViewHolder}"
|
||||||
|
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||||
|
tools:listitem="@layout/item_int_imp_query" />
|
||||||
|
|
||||||
|
</com.scwang.smart.refresh.layout.SmartRefreshLayout>
|
||||||
|
|
||||||
|
<!-- 底部统计信息 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:paddingHorizontal="15dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
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='@{`合计:` + viewModel.totalCount + `票`}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
tools:text="合计:3票" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:text='@{`总件数:` + viewModel.totalPc}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
tools:text="总件数:100" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginLeft="20dp"
|
||||||
|
android:text='@{`总重量:` + viewModel.totalWeight}'
|
||||||
|
android:textColor="@color/bottom_tool_tips_text_color"
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:textStyle="bold"
|
||||||
|
tools:text="总重量:100" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
</layout>
|
||||||
153
module_gjj/src/main/res/layout/dialog_int_imp_query_filter.xml
Normal file
153
module_gjj/src/main/res/layout/dialog_int_imp_query_filter.xml
Normal file
@@ -0,0 +1,153 @@
|
|||||||
|
<?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="model"
|
||||||
|
type="com.lukouguoji.gjj.dialog.IntImpQueryFilterDialogModel" />
|
||||||
|
</data>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<!-- 状态栏占位 -->
|
||||||
|
<View
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="25dp"
|
||||||
|
android:background="@color/white" />
|
||||||
|
|
||||||
|
<!-- 标题栏 -->
|
||||||
|
<include layout="@layout/title_tool_bar" />
|
||||||
|
|
||||||
|
<com.google.android.material.divider.MaterialDivider
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="1dp" />
|
||||||
|
|
||||||
|
<!-- 筛选条件区域 -->
|
||||||
|
<ScrollView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="0dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:padding="15dp">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<!-- 特码 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
hint='@{"请输入特码"}'
|
||||||
|
title='@{"特码"}'
|
||||||
|
titleLength="@{4}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={model.spCode}'
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
|
|
||||||
|
<!-- 航班号 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
hint='@{"请输入航班号"}'
|
||||||
|
title='@{"航班号"}'
|
||||||
|
titleLength="@{4}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={model.flightNo}'
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
|
|
||||||
|
<!-- 目的港 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
hint='@{"请输入目的港"}'
|
||||||
|
title='@{"目的港"}'
|
||||||
|
titleLength="@{4}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={model.dest}'
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
|
|
||||||
|
<!-- 运单类型 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
hint='@{"请选择运单类型"}'
|
||||||
|
list="@{model.awbTypeList}"
|
||||||
|
title='@{"运单类型"}'
|
||||||
|
titleLength="@{4}"
|
||||||
|
type="@{DataLayoutType.SPINNER}"
|
||||||
|
value='@={model.awbType}'
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
|
|
||||||
|
<!-- 业务类型 -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
hint='@{"请选择业务类型"}'
|
||||||
|
list="@{model.businessTypeList}"
|
||||||
|
title='@{"业务类型"}'
|
||||||
|
titleLength="@{4}"
|
||||||
|
type="@{DataLayoutType.SPINNER}"
|
||||||
|
value='@={model.businessType}'
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
|
|
||||||
|
<!-- 品名(中) -->
|
||||||
|
<com.lukouguoji.module_base.ui.weight.data.layout.PadDataLayoutNew
|
||||||
|
hint='@{"请输入品名"}'
|
||||||
|
title='@{"品名(中)"}'
|
||||||
|
titleLength="@{4}"
|
||||||
|
type="@{DataLayoutType.INPUT}"
|
||||||
|
value='@={model.goodsCn}'
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginBottom="10dp" />
|
||||||
|
|
||||||
|
<!-- 底部按钮区域 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="300dp"
|
||||||
|
android:layout_height="50dp"
|
||||||
|
android:layout_gravity="center_horizontal"
|
||||||
|
android:layout_marginTop="32dp"
|
||||||
|
android:background="@color/white"
|
||||||
|
android:gravity="center"
|
||||||
|
android:orientation="horizontal"
|
||||||
|
android:paddingHorizontal="15dp">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_marginRight="24dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/bg_primary_radius_4"
|
||||||
|
android:gravity="center"
|
||||||
|
android:onClick="@{()-> model.onResetClick()}"
|
||||||
|
android:text="重置"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:background="@drawable/bg_primary_radius_4"
|
||||||
|
android:gravity="center"
|
||||||
|
android:onClick="@{()-> model.onConfirmClick()}"
|
||||||
|
android:text="搜索"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</ScrollView>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</layout>
|
||||||
294
module_gjj/src/main/res/layout/item_int_imp_accident_visa.xml
Normal file
294
module_gjj/src/main/res/layout/item_int_imp_accident_visa.xml
Normal file
@@ -0,0 +1,294 @@
|
|||||||
|
<?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.IntImpAccidentVisaBean" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="position"
|
||||||
|
type="Integer" />
|
||||||
|
</data>
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:id="@+id/ll"
|
||||||
|
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">
|
||||||
|
|
||||||
|
<!-- 左侧选中图标 -->
|
||||||
|
<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_marginLeft="10dp"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<!-- 第一行:航班日期 | 始发站 | 运单总件数 | 不正常件数 | 运单号 -->
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
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="@{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:layout_marginTop="10dp"
|
||||||
|
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="@{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>
|
||||||
|
|
||||||
|
</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>
|
||||||
|
|
||||||
|
</layout>
|
||||||
271
module_gjj/src/main/res/layout/item_int_imp_pick_up_dlv.xml
Normal file
271
module_gjj/src/main/res/layout/item_int_imp_pick_up_dlv.xml
Normal file
@@ -0,0 +1,271 @@
|
|||||||
|
<?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.IntImpPickUpDLVBean" />
|
||||||
|
|
||||||
|
<variable
|
||||||
|
name="position"
|
||||||
|
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">
|
||||||
|
|
||||||
|
<!-- 选中图标 -->
|
||||||
|
<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" />
|
||||||
|
|
||||||
|
<!-- 数据展示区域 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<!-- 第一行:运单号、代理人、航班信息、件数、重量 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
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
|
||||||
|
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.wbNo}"
|
||||||
|
android:textColor="@color/colorPrimary"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 代理人 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.8"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
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:text="@{bean.agentCode}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 航班信息 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1.2"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
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:text="@{bean.flight}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 件数 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.8"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
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:text="@{String.valueOf(bean.pc)}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 重量 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.8"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
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:text="@{String.valueOf((int)bean.weight)}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 第二行:提货单号、库位、提取时间、品名(中) -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
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
|
||||||
|
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.pkId}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 库位 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="0.8"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
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:text="@{bean.location}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 提取时间 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1.2"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
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:text="@{bean.chargeTime}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<!-- 品名(中):合并件数+重量列位置 -->
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="0dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_weight="1.6"
|
||||||
|
android:gravity="center_vertical"
|
||||||
|
android:orientation="horizontal">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
completeSpace="@{6}"
|
||||||
|
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.goods}"
|
||||||
|
android:textSize="16sp" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</layout>
|
||||||
273
module_gjj/src/main/res/layout/item_int_imp_query.xml
Normal file
273
module_gjj/src/main/res/layout/item_int_imp_query.xml
Normal file
@@ -0,0 +1,273 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
|
<data>
|
||||||
|
<variable
|
||||||
|
name="bean"
|
||||||
|
type="com.lukouguoji.module_base.bean.IntImpQueryBean" />
|
||||||
|
</data>
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
|
android:id="@+id/ll"
|
||||||
|
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">
|
||||||
|
|
||||||
|
<!-- 左侧图标 -->
|
||||||
|
<ImageView
|
||||||
|
android:layout_width="40dp"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
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.1"
|
||||||
|
android:gravity="center_vertical">
|
||||||
|
|
||||||
|
<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.wbNo}"
|
||||||
|
android:textColor="@color/colorPrimary"
|
||||||
|
tools:text="78109081212" />
|
||||||
|
|
||||||
|
</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
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
completeSpace="@{3}"
|
||||||
|
android:text="件数:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text='@{String.valueOf(bean.awbPc)}'
|
||||||
|
tools:text="10" />
|
||||||
|
|
||||||
|
</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"
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:text="运单类型:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
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:gravity="center_vertical">
|
||||||
|
|
||||||
|
<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.agentName}'
|
||||||
|
tools:text="SF" />
|
||||||
|
|
||||||
|
</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"
|
||||||
|
completeSpace="@{5}"
|
||||||
|
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" />
|
||||||
|
|
||||||
|
</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:gravity="center_vertical">
|
||||||
|
|
||||||
|
<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.flight}"
|
||||||
|
tools:text="20240513/MU2026" />
|
||||||
|
|
||||||
|
</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
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
completeSpace="@{3}"
|
||||||
|
android:text="特码:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@{bean.spCode}"
|
||||||
|
tools:text="NOR" />
|
||||||
|
|
||||||
|
</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"
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:text="业务类型:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text='@{bean.businessName}'
|
||||||
|
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:gravity="center_vertical">
|
||||||
|
|
||||||
|
<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}"
|
||||||
|
tools:text="HFE" />
|
||||||
|
|
||||||
|
</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"
|
||||||
|
completeSpace="@{5}"
|
||||||
|
android:text="出库时间:" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text='@{bean.dlvTime}'
|
||||||
|
tools:text="2024-05-13 17:10:22" />
|
||||||
|
|
||||||
|
</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>
|
||||||
|
|
||||||
|
</layout>
|
||||||
Reference in New Issue
Block a user