Browse Source

Merge branch 'dev' of http://git.wmzhubo.com/guadoutech/YYHome into dev

jiangwei 2 weeks ago
parent
commit
a470f3a016
38 changed files with 59 additions and 31 deletions
  1. 6 0
      app/android/app/proguard-rules.pro
  2. 1 0
      app/android/gradle.properties
  3. 22 13
      packages/cpt_form/lib/modules/apply/vm/apply_view_model.dart
  4. 7 3
      packages/cpt_payment/lib/modules/payment/info/info_screen.dart
  5. 1 1
      packages/cpt_property/lib/modules/rent/page/property_rent_page.dart
  6. 5 3
      packages/cpt_property/lib/modules/sale/page/property_sale_page.dart
  7. 7 5
      packages/cpt_services/lib/modules/services/services_main_page.dart
  8. 1 1
      packages/cpt_services/lib/respository/services_respository.dart
  9. 0 0
      packages/cpt_services/lib/services_export.dart
  10. 1 1
      packages/cs_plugin_basic/lib/dialog/country_code_selecter.dart
  11. 2 1
      packages/cs_plugin_platform/lib/platform_export.dart
  12. 3 0
      packages/cs_plugin_platform/pubspec.yaml
  13. BIN
      packages/cs_resources/assets/facility/active_icon.webp
  14. BIN
      packages/cs_resources/assets/facility/book_icon.webp
  15. BIN
      packages/cs_resources/assets/facility/deposit_icon.webp
  16. BIN
      packages/cs_resources/assets/form/submit_icon.webp
  17. BIN
      packages/cs_resources/assets/main/feedback_history.webp
  18. BIN
      packages/cs_resources/assets/main/feedback_in_progress.webp
  19. BIN
      packages/cs_resources/assets/main/feedback_send.webp
  20. BIN
      packages/cs_resources/assets/main/latest_info.webp
  21. BIN
      packages/cs_resources/assets/main/latest_internal.webp
  22. BIN
      packages/cs_resources/assets/main/latest_property.webp
  23. BIN
      packages/cs_resources/assets/main/latest_publish.webp
  24. BIN
      packages/cs_resources/assets/main/visitor_active.webp
  25. BIN
      packages/cs_resources/assets/main/visitor_history.webp
  26. BIN
      packages/cs_resources/assets/main/visitor_now.webp
  27. BIN
      packages/cs_resources/assets/notice_board/announcement_icon.png
  28. BIN
      packages/cs_resources/assets/notice_board/announcement_icon.webp
  29. BIN
      packages/cs_resources/assets/notice_board/documents_icon.png
  30. BIN
      packages/cs_resources/assets/notice_board/documents_icon.webp
  31. BIN
      packages/cs_resources/assets/notice_board/event_icon.png
  32. BIN
      packages/cs_resources/assets/notice_board/event_icon.webp
  33. BIN
      packages/cs_resources/assets/payment/info_icon.webp
  34. BIN
      packages/cs_resources/assets/payment/manage_icon.webp
  35. BIN
      packages/cs_resources/assets/service/home_services.webp
  36. BIN
      packages/cs_resources/assets/service/in-progress.webp
  37. BIN
      packages/cs_resources/assets/service/maintenance.webp
  38. 3 3
      packages/cs_resources/lib/generated/assets.dart

+ 6 - 0
app/android/app/proguard-rules.pro

@@ -155,5 +155,11 @@ public void *(android.webkit.WebView, jav.lang.String);
 -dontwarn cn.jpush.**
 -keep class cn.jpush.** { *; }
 
+# Stripe支付
+-dontwarn com.stripe.android.pushProvisioning.PushProvisioningActivity$g
+-dontwarn com.stripe.android.pushProvisioning.PushProvisioningActivityStarter$Args
+-dontwarn com.stripe.android.pushProvisioning.PushProvisioningActivityStarter$Error
+-dontwarn com.stripe.android.pushProvisioning.PushProvisioningActivityStarter
+-dontwarn com.stripe.android.pushProvisioning.PushProvisioningEphemeralKeyProvider
 
 

+ 1 - 0
app/android/gradle.properties

@@ -1,4 +1,5 @@
 org.gradle.jvmargs=-Xmx4G -XX:MaxMetaspaceSize=2G -XX:+HeapDumpOnOutOfMemoryError
 android.useAndroidX=true
 android.enableJetifier=true
+android.enableR8.fullMode=false
 maven={ url 'https://maven.aliyun.com/repository/public' }

+ 22 - 13
packages/cpt_form/lib/modules/apply/vm/apply_view_model.dart

@@ -8,6 +8,7 @@ import 'package:flutter/cupertino.dart';
 import 'package:plugin_platform/engine/toast/toast_engine.dart';
 import 'package:plugin_platform/engine/notify/notify_engine.dart';
 import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
+import 'package:plugin_platform/platform_export.dart';
 import 'package:riverpod_annotation/riverpod_annotation.dart';
 import 'package:shared/utils/log_utils.dart';
 import 'package:widgets/picker/date_picker_util.dart';
@@ -153,18 +154,26 @@ class ApplyViewModel extends _$ApplyViewModel with DioCancelableMixin {
 
   /// 提交Form表单
   void submitForm() async {
-    final result = await _formRepository.submitForm(
-      estateFormId: state.estateFormId,
-      typeId: state.formType,
-      content: state.formContentDetail,
-      cancelToken: cancelToken,
-    );
-
-    if (result.isSuccess) {
-      NotifyEngine.showSuccess(S.current.successful);
-      gotoNextPage();
-    } else {
-      ToastEngine.show(result.errorMsg ?? "UnKnow Error");
-    }
+    //   final result = await _formRepository.submitForm(
+    //     estateFormId: state.estateFormId,
+    //     typeId: state.formType,
+    //     content: state.formContentDetail,
+    //     cancelToken: cancelToken,
+    //   );
+    //
+    //   if (result.isSuccess) {
+    //     NotifyEngine.showSuccess(S.current.successful);
+    //     gotoNextPage();
+    //   } else {
+    //     ToastEngine.show(result.errorMsg ?? "UnKnow Error");
+    //   }
+    // }
+
+    //TODO 测试Stripe支付
+    // Stripe.instance.initPaymentSheet(paymentSheetParameters: paymentSheetParameters)
+    // PaymentIntent pi = await Stripe.instance.confirmPayment(
+    //   paymentIntentClientSecret: 'pi_3RNlYBRpg7SPAcNn1CwGxP7e',
+    // );
+    // Log.d("测试Stripe支付 pi:$pi");
   }
 }

+ 7 - 3
packages/cpt_payment/lib/modules/payment/info/info_screen.dart

@@ -10,6 +10,7 @@ import 'package:widgets/ext/ex_widget.dart';
 import 'package:widgets/load_state_layout.dart';
 import 'package:widgets/my_load_image.dart';
 import 'package:widgets/my_text_view.dart';
+import 'package:widgets/utils/dark_theme_util.dart';
 import 'package:widgets/widget_export.dart';
 
 @RoutePage()
@@ -127,10 +128,11 @@ class InfoScreen extends HookConsumerWidget {
             ),
 
             //图标1
-            const MyAssetImage(
+            MyAssetImage(
               Assets.paymentInfoCashBack,
               width: 53.5,
               height: 55,
+              color: DarkThemeUtil.multiColors(context, AppColorsTheme.colorPrimary, darkColor: Colors.white),
             ),
 
             //文本3
@@ -147,10 +149,11 @@ class InfoScreen extends HookConsumerWidget {
             ),
 
             //图标2
-            const MyAssetImage(
+            MyAssetImage(
               Assets.paymentInfoRewards,
               width: 49,
               height: 53.5,
+              color: DarkThemeUtil.multiColors(context, AppColorsTheme.colorPrimary, darkColor: Colors.white),
             ),
 
             //文本4
@@ -167,10 +170,11 @@ class InfoScreen extends HookConsumerWidget {
             ),
 
             //图标3
-            const MyAssetImage(
+            MyAssetImage(
               Assets.paymentInfoBusiness,
               width: 55.5,
               height: 55.5,
+              color: DarkThemeUtil.multiColors(context, AppColorsTheme.colorPrimary, darkColor: Colors.white),
             ),
 
             //文本5

+ 1 - 1
packages/cpt_property/lib/modules/rent/page/property_rent_page.dart

@@ -71,7 +71,7 @@ class PropertyRentPage extends HookConsumerWidget {
             mainAxisAlignment: MainAxisAlignment.center,
             children: [
               MyTextView(
-                price,
+                '\$$price',
                 fontSize: 17,
                 isFontMedium: true,
               ),

+ 5 - 3
packages/cpt_property/lib/modules/sale/page/property_sale_page.dart

@@ -65,7 +65,7 @@ class PropertySalePage extends HookConsumerWidget {
           ),
         ),
         child: MyTextView(
-          price,
+          '\$$price',
           fontSize: 17,
           textColor: context.appColors.textBlack,
           isFontMedium: true,
@@ -75,7 +75,7 @@ class PropertySalePage extends HookConsumerWidget {
   }
 
   // listitem
-  Widget _buildSaleItem(BuildContext context,WidgetRef ref, item, _vm) {
+  Widget _buildSaleItem(BuildContext context,WidgetRef ref, Map<String, dynamic>item, _vm) {
     return Container(
       decoration: BoxDecoration(
         color: context.appColors.backgroundWhite,
@@ -95,7 +95,9 @@ class PropertySalePage extends HookConsumerWidget {
               crossAxisAlignment: CrossAxisAlignment.center,
               children: [
                 Expanded(child: _buildItemLeftSection(context, ref, item, _vm)),
-                _buildItemRightSection(context, ref, item, _vm),
+                Container(child: _buildItemRightSection(context, ref, item, _vm)).constrained(
+                  minWidth: 120,
+                ),
               ],
             ),
           ),

+ 7 - 5
packages/cpt_services/lib/modules/services/services_main_page.dart

@@ -85,11 +85,12 @@ class ServicesMainPage extends HookConsumerWidget {
                 },
                 successSliverWidget:[
                   SliverGrid(
-                    gridDelegate:  const SliverGridDelegateWithFixedCrossAxisCount(
+                    gridDelegate:  SliverGridDelegateWithFixedCrossAxisCount(
                       crossAxisCount: 2,
-                      mainAxisSpacing: 10,
-                      crossAxisSpacing: 5,
-                      childAspectRatio: 165/146, //宽高比
+                      mainAxisSpacing: 15,
+                      crossAxisSpacing: 15,
+                      // childAspectRatio: 165/146, //宽高比
+                      childAspectRatio:  165/160 * ((165/160).ap), // 宽高比
                     ),
                     delegate: SliverChildBuilderDelegate(
                           (context, index) {
@@ -157,7 +158,8 @@ class ServicesMainPage extends HookConsumerWidget {
       double iconHeight,
   ) {
     return Container(
-      margin: EdgeInsets.all(10),
+        width: double.infinity,
+      padding: const EdgeInsets.only(left: 10, right: 10),
       decoration: BoxDecoration(
         color: context.appColors.whiteBG,
         borderRadius: BorderRadius.circular(10),

+ 1 - 1
packages/cpt_services/lib/respository/services_respository.dart

@@ -60,7 +60,7 @@ class ServicesRespository {
       params: params,
       headers: headers,
       method: HttpMethod.GET,
-      isShowLoadingDialog: true,
+      isShowLoadingDialog: false,
       //是否展示默认的Loading弹窗
       networkDebounce: true,
       //是否防抖防止重复请求

+ 0 - 0
packages/cpt_services/lib/services_export.dart


+ 1 - 1
packages/cs_plugin_basic/lib/dialog/country_code_selecter.dart

@@ -156,7 +156,7 @@ class _AttachCountryDialog extends StatelessWidget {
                   item['code']!,
                   marginLeft: 8,
                   marginRight: 10,
-                  textColor: Colors.black,
+                  textColor: context.appColors.textBlack,
                   isFontMedium: true,
                   fontSize: 16,
                 ).expanded(),

+ 2 - 1
packages/cs_plugin_platform/lib/platform_export.dart

@@ -1,4 +1,5 @@
 export 'package:dio/dio.dart';
 export 'package:permission_handler/permission_handler.dart';
 export 'engine/image/image_nine_grid.dart';
-export 'engine/media/image_picker_utils.dart';
+export 'engine/media/image_picker_utils.dart';
+// export 'package:flutter_stripe/flutter_stripe.dart';

+ 3 - 0
packages/cs_plugin_platform/pubspec.yaml

@@ -78,5 +78,8 @@ dependencies:
   # 5.5.0 报错,这里强制指定版本适配 Flutter 版本 3.24.0
   win32: 5.5.4
 
+  #Stripe支付
+#  flutter_stripe: 11.5.0
+
 flutter:
   uses-material-design: true

BIN
packages/cs_resources/assets/facility/active_icon.webp


BIN
packages/cs_resources/assets/facility/book_icon.webp


BIN
packages/cs_resources/assets/facility/deposit_icon.webp


BIN
packages/cs_resources/assets/form/submit_icon.webp


BIN
packages/cs_resources/assets/main/feedback_history.webp


BIN
packages/cs_resources/assets/main/feedback_in_progress.webp


BIN
packages/cs_resources/assets/main/feedback_send.webp


BIN
packages/cs_resources/assets/main/latest_info.webp


BIN
packages/cs_resources/assets/main/latest_internal.webp


BIN
packages/cs_resources/assets/main/latest_property.webp


BIN
packages/cs_resources/assets/main/latest_publish.webp


BIN
packages/cs_resources/assets/main/visitor_active.webp


BIN
packages/cs_resources/assets/main/visitor_history.webp


BIN
packages/cs_resources/assets/main/visitor_now.webp


BIN
packages/cs_resources/assets/notice_board/announcement_icon.png


BIN
packages/cs_resources/assets/notice_board/announcement_icon.webp


BIN
packages/cs_resources/assets/notice_board/documents_icon.png


BIN
packages/cs_resources/assets/notice_board/documents_icon.webp


BIN
packages/cs_resources/assets/notice_board/event_icon.png


BIN
packages/cs_resources/assets/notice_board/event_icon.webp


BIN
packages/cs_resources/assets/payment/info_icon.webp


BIN
packages/cs_resources/assets/payment/manage_icon.webp


BIN
packages/cs_resources/assets/service/home_services.webp


BIN
packages/cs_resources/assets/service/in-progress.webp


BIN
packages/cs_resources/assets/service/maintenance.webp


+ 3 - 3
packages/cs_resources/lib/generated/assets.dart

@@ -153,9 +153,9 @@ class Assets {
   static const String noticeBoardAnnouncementDetailDate = 'assets/notice_board/announcement_detail_date.png';
   static const String noticeBoardAnnouncementDetailOur = 'assets/notice_board/announcement_detail_our.png';
   static const String noticeBoardAnnouncementDetailTo = 'assets/notice_board/announcement_detail_to.png';
-  static const String noticeBoardAnnouncementIcon = 'assets/notice_board/announcement_icon.png';
-  static const String noticeBoardDocumentsIcon = 'assets/notice_board/documents_icon.png';
-  static const String noticeBoardEventIcon = 'assets/notice_board/event_icon.png';
+  static const String noticeBoardAnnouncementIcon = 'assets/notice_board/announcement_icon.webp';
+  static const String noticeBoardDocumentsIcon = 'assets/notice_board/documents_icon.webp';
+  static const String noticeBoardEventIcon = 'assets/notice_board/event_icon.webp';
   static const String paymentAmericanExpressIcon = 'assets/payment/american_express_icon.webp';
   static const String paymentCardIcon = 'assets/payment/card_icon.webp';
   static const String paymentCardName = 'assets/payment/card_name.webp';