|
@@ -103,6 +103,13 @@ class MaterialOperateActivity : BaseActivity<ActivityMaterialOperateBinding>() {
|
|
|
|
|
|
OASystem.materialBaseData = dataSourceResponse.data.goodsTypeData
|
|
|
|
|
|
+ materialSearchRequest.apply {
|
|
|
+ pageIndex = 1
|
|
|
+ pageSize = 10
|
|
|
+ }
|
|
|
+
|
|
|
+ materialSearch(1)
|
|
|
+
|
|
|
initEvents()
|
|
|
|
|
|
} else {
|
|
@@ -254,7 +261,7 @@ class MaterialOperateActivity : BaseActivity<ActivityMaterialOperateBinding>() {
|
|
|
|
|
|
for (item in materialTypeDetail) {
|
|
|
detailTypeText += item.name
|
|
|
- detailTypeText += "\t"
|
|
|
+ detailTypeText += "\t\t"
|
|
|
}
|
|
|
|
|
|
binding.detailType.text = detailTypeText.trim()
|
|
@@ -274,21 +281,27 @@ class MaterialOperateActivity : BaseActivity<ActivityMaterialOperateBinding>() {
|
|
|
|
|
|
binding.commit.setButtonStatus(CommitButton.STATUS_IN_COMMITING)
|
|
|
|
|
|
- if (materialList.size != 0) {
|
|
|
- materialList.clear()
|
|
|
- binding.materialList.adapter!!.notifyItemRangeRemoved(0, materialList.size)
|
|
|
- }
|
|
|
+ materialList.clear()
|
|
|
+ binding.materialList.adapter!!.notifyItemRangeRemoved(0, materialList.size)
|
|
|
|
|
|
materialSearchRequest.apply {
|
|
|
- pageIndex = this@MaterialOperateActivity.pageIndex
|
|
|
+ pageIndex = 1
|
|
|
pageSize = 10
|
|
|
|
|
|
- for (item in materialTypeDetail) {
|
|
|
- typeIds += item.name
|
|
|
- typeIds += ","
|
|
|
- }
|
|
|
+ typeIds = ""
|
|
|
+
|
|
|
+ var i = 0
|
|
|
+
|
|
|
+ while (i < materialTypeDetail.size) {
|
|
|
+
|
|
|
+ typeIds += materialTypeDetail[i].id
|
|
|
|
|
|
- typeIds.substringBeforeLast(",")
|
|
|
+ i += 1
|
|
|
+
|
|
|
+ if (i < materialTypeDetail.size) {
|
|
|
+ typeIds += ","
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
goodsName = binding.materialName.text.toString()
|
|
|
}
|