Browse Source

2024-08-26 修改

修改:
1. 团组信息/接团客户名单 - 客户名单界面,限制名单到达或扫描名单超过最大人数的操作

2. 酒店VOUCHER 下载,接口更改
zhaiy 7 months ago
parent
commit
1a657abb9d

+ 1 - 1
app/src/main/java/com/pan_american/android/data/network/APIService.kt

@@ -803,7 +803,7 @@ interface APIService {
     /**
      * 文档下载 酒店资料 voucher
      */
-    @POST("api/Groups/PostHotelReservationsCreateVoucher")
+    @POST("api/Groups/PostHotelReservationsCreateVoucherBatchNew")
     fun hotelVoucherGenerate(@Body hotelDocumentGenerateRequest: HotelDocumentGenerateRequest): Call<HotelDocumentGenerateResponse>
 
     /**

+ 11 - 0
app/src/main/java/com/pan_american/android/ui/group_management/group_info/GroupCustomerListFragment.kt

@@ -70,6 +70,12 @@ class GroupCustomerListFragment : BaseFragment<FragmentGroupCustomerListBinding>
     override fun initEvents() {
 
         binding.add.setOnClickListener {
+
+            if (OASystem.groupOperationRequest.visitPNumber == OASystem.groupInfoGroupCustomerList.size) {
+                showMessage(resources.getString(R.string.visit_member_max_hint))
+                return@setOnClickListener
+            }
+
             val groupCustomerDetailFragment = GroupCustomerDetailFragment()
             val bundle = Bundle()
 
@@ -112,6 +118,11 @@ class GroupCustomerListFragment : BaseFragment<FragmentGroupCustomerListBinding>
 
         binding.nextPage.setOnClickListener {
 
+            if (OASystem.groupOperationRequest.visitPNumber > OASystem.groupInfoGroupCustomerList.size) {
+                showMessage(resources.getString(R.string.visit_member_over_hint))
+                return@setOnClickListener
+            }
+
             for ((i, item) in OASystem.groupInfoGroupCustomerList.withIndex()) {
                 if (item.companyFullName == resources.getString(R.string.no_info) || item.companyFullName.isBlank()) {
                     showMessage(String.format(resources.getString(R.string.client_company_hint), i + 1))

+ 2 - 0
app/src/main/res/values/strings.xml

@@ -501,6 +501,8 @@
     <string name="phone_number_hint">请输入手机号</string>
     <string name="id_code_hint">请输入身份证号</string>
     <string name="birthday_hint">请选择出生日期</string>
+    <string name="visit_member_max_hint">接团客户名单人数达到团组人数上限,无法添加更多客户</string>
+    <string name="visit_member_over_hint">接团客户名单人数超过团组人数上限,请调整客户名单</string>
 
     <string name="group_customer_list">接团客户名单</string>