glglove 3 тижнів тому
батько
коміт
713e8ef1e5
53 змінених файлів з 732 додано та 161 видалено
  1. 1 1
      app/android/app/build.gradle
  2. 1 1
      app/lib/main.dart
  3. 19 19
      app/pubspec_overrides.yaml
  4. 5 1
      melos.yaml
  5. 7 7
      packages/cpt_auth/pubspec_overrides.yaml
  6. 7 7
      packages/cpt_community/pubspec_overrides.yaml
  7. 7 7
      packages/cpt_facility/pubspec_overrides.yaml
  8. 7 7
      packages/cpt_form/pubspec_overrides.yaml
  9. 7 7
      packages/cpt_main/pubspec_overrides.yaml
  10. 7 7
      packages/cpt_notice_board/pubspec_overrides.yaml
  11. 7 7
      packages/cpt_payment/pubspec_overrides.yaml
  12. 7 7
      packages/cpt_profile/pubspec_overrides.yaml
  13. 41 0
      packages/cpt_property/lib/modules/ioan/page/property_ioan_page.dart
  14. 14 14
      packages/cpt_property/lib/modules/property/vm/property_view_model.dart
  15. 10 10
      packages/cpt_property/lib/modules/property/vm/property_view_model.g.dart
  16. 33 0
      packages/cpt_property/lib/modules/news/page/property_news_page.dart
  17. 14 0
      packages/cpt_property/lib/modules/news/vm/property_news_vm.dart
  18. 26 0
      packages/cpt_property/lib/modules/news/vm/property_news_vm.g.dart
  19. 84 8
      packages/cpt_property/lib/modules/property/page/property_page.dart
  20. 79 0
      packages/cpt_property/lib/modules/property/vm/property_vm.dart
  21. 25 0
      packages/cpt_property/lib/modules/property/vm/property_vm.g.dart
  22. 33 0
      packages/cpt_property/lib/modules/rent/page/property_rent_page.dart
  23. 14 0
      packages/cpt_property/lib/modules/rent/vm/property_rent_vm.dart
  24. 26 0
      packages/cpt_property/lib/modules/rent/vm/property_rent_vm.g.dart
  25. 33 0
      packages/cpt_property/lib/modules/sale/page/property_sale_page.dart
  26. 14 0
      packages/cpt_property/lib/modules/sale/vm/property_sale_vm.dart
  27. 26 0
      packages/cpt_property/lib/modules/sale/vm/property_sale_vm.g.dart
  28. 32 3
      packages/cpt_property/lib/router/page/property_page_router.dart
  29. 81 1
      packages/cpt_property/lib/router/page/property_page_router.gr.dart
  30. 7 7
      packages/cpt_property/pubspec_overrides.yaml
  31. 7 7
      packages/cpt_rewards/pubspec_overrides.yaml
  32. 7 7
      packages/cpt_services/pubspec_overrides.yaml
  33. 6 6
      packages/cs_domain/pubspec_overrides.yaml
  34. 7 7
      packages/cs_initializer/pubspec_overrides.yaml
  35. 6 6
      packages/cs_plugin_basic/pubspec_overrides.yaml
  36. 4 4
      packages/cs_plugin_platform/pubspec_overrides.yaml
  37. BIN
      packages/cs_resources/assets/property/advice_pic@2x.png
  38. BIN
      packages/cs_resources/assets/property/approval@2x.png
  39. BIN
      packages/cs_resources/assets/property/conveyancing_lawyer@2x.png
  40. BIN
      packages/cs_resources/assets/property/home_equity_loans@2x.png
  41. BIN
      packages/cs_resources/assets/property/home_loan_bg@2x.png
  42. BIN
      packages/cs_resources/assets/property/ioan@2x.png
  43. BIN
      packages/cs_resources/assets/property/new_home_loans@2x.png
  44. BIN
      packages/cs_resources/assets/property/news@2x.png
  45. BIN
      packages/cs_resources/assets/property/our_partners@2x.png
  46. BIN
      packages/cs_resources/assets/property/overseas_home_loan@2x.png
  47. BIN
      packages/cs_resources/assets/property/refinancing@2x.png
  48. BIN
      packages/cs_resources/assets/property/rent@2x.png
  49. BIN
      packages/cs_resources/assets/property/sale@2x.png
  50. 13 0
      packages/cs_resources/lib/generated/assets.dart
  51. 1 0
      packages/cs_resources/pubspec.yaml
  52. 4 0
      packages/cs_router/lib/path/router_path.dart
  53. 3 3
      packages/cs_widgets/pubspec_overrides.yaml

+ 1 - 1
app/android/app/build.gradle

@@ -59,7 +59,7 @@ android {
 
         ndk {
             //选择要添加的对应 cpu 类型的 .so 库。
-//            abiFilters 'x86', 'x86_64', 'armeabi-v7a', 'arm64-v8a'
+            abiFilters 'x86', 'x86_64', 'armeabi-v7a', 'arm64-v8a'
             abiFilters 'armeabi-v7a', 'arm64-v8a'
 //            abiFilters 'armeabi-v7a'
 //            abiFilters 'arm64-v8a'

+ 1 - 1
app/lib/main.dart

@@ -107,7 +107,7 @@ class MyApp extends HookConsumerWidget {
         usePenetrate: false,
       )
       ..loading = SmartConfigLoading(
-        backDismiss: true,
+        // backDismiss: true,
         clickMaskDismiss: true,
       )
       ..toast = SmartConfigToast(

+ 19 - 19
app/pubspec_overrides.yaml

@@ -1,40 +1,40 @@
 # melos_managed_dependency_overrides: cpt_auth,cpt_community,cpt_facility,cpt_form,cpt_main,cpt_notice_board,cpt_payment,cpt_profile,cpt_rewards,cpt_services,cs_resources,domain,initializer,plugin_basic,plugin_platform,router,shared,widgets,cpt_property
 dependency_overrides:
   cpt_auth:
-    path: ../packages/cpt_auth
+    path: ..\\packages\\cpt_auth
   cpt_community:
-    path: ../packages/cpt_community
+    path: ..\\packages\\cpt_community
   cpt_facility:
-    path: ../packages/cpt_facility
+    path: ..\\packages\\cpt_facility
   cpt_form:
-    path: ../packages/cpt_form
+    path: ..\\packages\\cpt_form
   cpt_main:
-    path: ../packages/cpt_main
+    path: ..\\packages\\cpt_main
   cpt_notice_board:
-    path: ../packages/cpt_notice_board
+    path: ..\\packages\\cpt_notice_board
   cpt_payment:
-    path: ../packages/cpt_payment
+    path: ..\\packages\\cpt_payment
   cpt_profile:
-    path: ../packages/cpt_profile
+    path: ..\\packages\\cpt_profile
   cpt_property:
-    path: ../packages/cpt_property
+    path: ..\\packages\\cpt_property
   cpt_rewards:
-    path: ../packages/cpt_rewards
+    path: ..\\packages\\cpt_rewards
   cpt_services:
-    path: ../packages/cpt_services
+    path: ..\\packages\\cpt_services
   cs_resources:
-    path: ../packages/cs_resources
+    path: ..\\packages\\cs_resources
   domain:
-    path: ../packages/cs_domain
+    path: ..\\packages\\cs_domain
   initializer:
-    path: ../packages/cs_initializer
+    path: ..\\packages\\cs_initializer
   plugin_basic:
-    path: ../packages/cs_plugin_basic
+    path: ..\\packages\\cs_plugin_basic
   plugin_platform:
-    path: ../packages/cs_plugin_platform
+    path: ..\\packages\\cs_plugin_platform
   router:
-    path: ../packages/cs_router
+    path: ..\\packages\\cs_router
   shared:
-    path: ../packages/cs_shared
+    path: ..\\packages\\cs_shared
   widgets:
-    path: ../packages/cs_widgets
+    path: ..\\packages\\cs_widgets

+ 5 - 1
melos.yaml

@@ -76,7 +76,11 @@ scripts:
     description: Run `dart run build_runner build` in profile module
 
   build_runner_property:
-    run: cd "$MELOS_ROOT_PATH/packages/cpt_property" && dart run build_runner build
+    run: cd "$MELOS_ROOT_PATH/packages/cpt_property" && flutter pub run build_runner build --delete-conflicting-outputs --verbose
+    description: Run `dart run build_runner build` in property module
+
+  watch_runner_property:
+    run: cd "$MELOS_ROOT_PATH/packages/cpt_property" && flutter pub run build_runner watch --delete-conflicting-outputs --verbose
     description: Run `dart run build_runner build` in property module
 
   build_runner_rewards:

+ 7 - 7
packages/cpt_auth/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_community/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_facility/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_form/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_main/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_notice_board/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_payment/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_profile/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 41 - 0
packages/cpt_property/lib/modules/ioan/page/property_ioan_page.dart

@@ -0,0 +1,41 @@
+import 'package:cs_resources/generated/assets.dart';
+import 'package:flutter/material.dart';
+import 'package:auto_route/auto_route.dart';
+import 'package:hooks_riverpod/hooks_riverpod.dart';
+import 'package:router/ext/auto_router_extensions.dart';
+import 'package:widgets/my_load_image.dart';
+
+import '../../../router/page/property_page_router.dart';
+import '../vm/property_ioan_vm.dart';
+
+@RoutePage()
+class PropertyIoanPage extends HookConsumerWidget {
+  const PropertyIoanPage({Key? key}) : super(key: key);
+
+  //启动当前页面
+  static void startInstance({BuildContext? context}) {
+    if (context != null) {
+      context.router.push(const PropertyIoanPageRoute());
+    } else {
+      appRouter.push(const PropertyIoanPageRoute());
+    }
+  }
+
+  @override
+  Widget build(BuildContext context, WidgetRef ref) {
+    final _vm = ref.read(propertyIoanVmProvider.notifier);
+
+    return Scaffold(
+      // appBar: AppBar(title: Text("资产")),
+      body: Column(
+        children: [
+          MyAssetImage(
+            Assets.propertyIoan2x,
+            width: 100,
+            height: 100,
+          ),
+        ],
+      ),
+    );
+  }
+}

+ 14 - 14
packages/cpt_property/lib/modules/property/vm/property_view_model.dart

@@ -1,14 +1,14 @@
-
-import 'package:riverpod_annotation/riverpod_annotation.dart';
-
-part 'property_view_model.g.dart';
-
-@riverpod
-class PropertyViewModel extends _$PropertyViewModel {
-
-  @override
-  void build(){
-
-  }
-
-}
+
+import 'package:riverpod_annotation/riverpod_annotation.dart';
+
+part 'property_ioan_vm.g.dart';
+
+@riverpod
+class PropertyIoanVm extends _$PropertyIoanVm {
+
+  @override
+  void build(){
+
+  }
+
+}

+ 10 - 10
packages/cpt_property/lib/modules/property/vm/property_view_model.g.dart

@@ -1,26 +1,26 @@
 // GENERATED CODE - DO NOT MODIFY BY HAND
 
-part of 'property_view_model.dart';
+part of 'property_ioan_vm.dart';
 
 // **************************************************************************
 // RiverpodGenerator
 // **************************************************************************
 
-String _$propertyViewModelHash() => r'5b26fb8c848e6e1bc2527fd4ec1799929f095866';
+String _$propertyIoanVmHash() => r'e543d5bc121950c3301766873f79a84632d07887';
 
-/// See also [PropertyViewModel].
-@ProviderFor(PropertyViewModel)
-final propertyViewModelProvider =
-    AutoDisposeNotifierProvider<PropertyViewModel, void>.internal(
-  PropertyViewModel.new,
-  name: r'propertyViewModelProvider',
+/// See also [PropertyIoanVm].
+@ProviderFor(PropertyIoanVm)
+final propertyIoanVmProvider =
+    AutoDisposeNotifierProvider<PropertyIoanVm, void>.internal(
+  PropertyIoanVm.new,
+  name: r'propertyIoanVmProvider',
   debugGetCreateSourceHash: const bool.fromEnvironment('dart.vm.product')
       ? null
-      : _$propertyViewModelHash,
+      : _$propertyIoanVmHash,
   dependencies: null,
   allTransitiveDependencies: null,
 );
 
-typedef _$PropertyViewModel = AutoDisposeNotifier<void>;
+typedef _$PropertyIoanVm = AutoDisposeNotifier<void>;
 // ignore_for_file: type=lint
 // ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member, deprecated_member_use_from_same_package

+ 33 - 0
packages/cpt_property/lib/modules/news/page/property_news_page.dart

@@ -0,0 +1,33 @@
+import 'package:flutter/material.dart';
+import 'package:auto_route/auto_route.dart';
+import 'package:hooks_riverpod/hooks_riverpod.dart';
+import 'package:router/ext/auto_router_extensions.dart';
+
+import '../../../router/page/property_page_router.dart';
+import '../vm/property_news_vm.dart';
+
+@RoutePage()
+class PropertyNewsPage extends HookConsumerWidget {
+  const PropertyNewsPage({Key? key}) : super(key: key);
+
+  //启动当前页面
+  static void startInstance({BuildContext? context}) {
+    if (context != null) {
+      context.router.push(const PropertyNewsPageRoute());
+    } else {
+      appRouter.push(const PropertyNewsPageRoute());
+    }
+  }
+
+  @override
+  Widget build(BuildContext context, WidgetRef ref) {
+    final _vm = ref.read(propertyNewsVmProvider.notifier);
+
+    return Scaffold(
+      // appBar: AppBar(title: Text("资产")),
+      body: Center(
+        child: Text("房屋news的主页面"),
+      ),
+    );
+  }
+}

+ 14 - 0
packages/cpt_property/lib/modules/news/vm/property_news_vm.dart

@@ -0,0 +1,14 @@
+
+import 'package:riverpod_annotation/riverpod_annotation.dart';
+
+part 'property_news_vm.g.dart';
+
+@riverpod
+class PropertyNewsVm extends _$PropertyNewsVm {
+
+  @override
+  void build(){
+
+  }
+
+}

+ 26 - 0
packages/cpt_property/lib/modules/news/vm/property_news_vm.g.dart

@@ -0,0 +1,26 @@
+// GENERATED CODE - DO NOT MODIFY BY HAND
+
+part of 'property_news_vm.dart';
+
+// **************************************************************************
+// RiverpodGenerator
+// **************************************************************************
+
+String _$propertyNewsVmHash() => r'f18922e4ca3d2a59ba6f2504064b9bb073719979';
+
+/// See also [PropertyNewsVm].
+@ProviderFor(PropertyNewsVm)
+final propertyNewsVmProvider =
+    AutoDisposeNotifierProvider<PropertyNewsVm, void>.internal(
+  PropertyNewsVm.new,
+  name: r'propertyNewsVmProvider',
+  debugGetCreateSourceHash: const bool.fromEnvironment('dart.vm.product')
+      ? null
+      : _$propertyNewsVmHash,
+  dependencies: null,
+  allTransitiveDependencies: null,
+);
+
+typedef _$PropertyNewsVm = AutoDisposeNotifier<void>;
+// ignore_for_file: type=lint
+// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member, deprecated_member_use_from_same_package

+ 84 - 8
packages/cpt_property/lib/modules/property/page/property_page.dart

@@ -1,10 +1,17 @@
+import 'package:cpt_property/modules/ioan/page/property_ioan_page.dart';
+import 'package:cpt_property/modules/news/page/property_news_page.dart';
+import 'package:cpt_property/modules/rent/page/property_rent_page.dart';
+import 'package:cpt_property/modules/sale/page/property_sale_page.dart';
 import 'package:flutter/material.dart';
 import 'package:auto_route/auto_route.dart';
 import 'package:hooks_riverpod/hooks_riverpod.dart';
 import 'package:router/ext/auto_router_extensions.dart';
+import 'package:shared/utils/log_utils.dart';
+import 'package:widgets/my_load_image.dart';
+import 'package:widgets/ext/ex_widget.dart';
 
 import '../../../router/page/property_page_router.dart';
-import '../vm/property_view_model.dart';
+import '../vm/property_vm.dart';
 
 @RoutePage()
 class PropertyPage extends HookConsumerWidget {
@@ -19,15 +26,84 @@ class PropertyPage extends HookConsumerWidget {
     }
   }
 
-  @override
-  Widget build(BuildContext context, WidgetRef ref) {
-    final _viewModel = ref.read(propertyViewModelProvider.notifier);
 
-    return Scaffold(
-      appBar: AppBar(title: Text("资产")),
-      body: Center(
-        child: Text("房屋资产的主页面"),
+
+  // 顶部tab 切换
+  Widget _buildTopSection(BuildContext context, WidgetRef ref, _vm) {
+    final topSectionsData = _vm.topSectionsData;
+    return Container(
+      color: Colors.white,
+      child: Center(
+        child: Row(
+          mainAxisAlignment: MainAxisAlignment.center,
+          crossAxisAlignment: CrossAxisAlignment.center,
+          children: List.generate(topSectionsData.length, (index) {
+            final item = topSectionsData[index];
+            return Container(
+              child: Column(
+                children: [
+                  MyAssetImage(item['icon'], width: 70, height: 70,).onTap((){
+                      Log.d("fdjskfds${item['title']}");
+                      _vm.switchPage(index, context);
+                      switch(index){
+                         case 0:
+                           PropertySalePage.startInstance(context: context);
+                           break;
+                         case 1:
+                           PropertyRentPage.startInstance(context: context);
+                           break;
+                         case 2:
+                           PropertyIoanPage.startInstance(context: context);
+                           break;
+                         case 3:
+                           PropertyNewsPage.startInstance(context: context);
+                           break;
+                      }
+                    },
+                    type: ClickType.throttle,
+                  ),
+                  TextButton(
+                    onPressed: () {
+                      // _vm.selectTab(index);
+                    },
+                    child: Text(item['title']),
+                  ),
+                ],
+              ),
+            ).marginOnly(left:18,right:18,top: 10,bottom: 10);
+          }),
+        ),
       ),
     );
   }
+
+
+  @override
+  Widget build(BuildContext context, WidgetRef ref) {
+    final _vm = ref.read(propertyVmProvider.notifier);
+    return DefaultTabController(
+        length: 4,
+        child: Scaffold(
+          appBar: AppBar(
+            title: Text("Property"),
+            bottomOpacity: 0.0, // 取消下横线
+            titleTextStyle: TextStyle(color: Colors.black),
+          ),
+          body: Row(
+            children: [
+              Expanded(
+                child: Column(
+                  children: [
+                    _buildTopSection(context, ref, _vm),
+                    Expanded(
+                      child: AutoRouter(),
+                    )
+                  ],
+                ),
+              )
+            ],
+          )
+        ),
+    );
+  }
 }

+ 79 - 0
packages/cpt_property/lib/modules/property/vm/property_vm.dart

@@ -0,0 +1,79 @@
+
+import 'package:cs_resources/generated/assets.dart';
+import 'package:flutter/cupertino.dart';
+import 'package:riverpod_annotation/riverpod_annotation.dart';
+import 'package:shared/utils/log_utils.dart';
+
+import '../../ioan/page/property_ioan_page.dart';
+import '../../news/page/property_news_page.dart';
+import '../../rent/page/property_rent_page.dart';
+import '../../sale/page/property_sale_page.dart';
+
+part 'property_vm.g.dart';
+
+
+class PropertyVmState {
+  List<Map<String, dynamic>> topSectionsData;
+  PropertyVmState({
+    required this.topSectionsData,
+  });
+
+  PropertyVmState CopyWith({
+    required List<Map<String, dynamic>> topSectionsData,
+  }){
+    return PropertyVmState(
+      topSectionsData: topSectionsData ?? this.topSectionsData,
+    );
+  }
+}
+
+@riverpod
+class PropertyVm extends _$PropertyVm {
+  get topSectionsData => state.topSectionsData;
+
+  PropertyVmState initState() {
+    return PropertyVmState(
+      topSectionsData: [
+        {
+          "title": "Sale",
+          "icon": Assets.propertySale2x,
+          "pageStartInstanceFn": PropertySalePage.startInstance,
+          "page": const PropertySalePage(),
+        },
+        {
+          "title": "Rent",
+          "icon": Assets.propertyRent2x,
+          "pageStartInstanceFn": PropertyRentPage.startInstance,
+          "page": const PropertyRentPage(),
+        },
+        {
+          "title": "Ioan",
+          "icon": Assets.propertyIoan2x,
+          "pageStartInstanceFn": PropertyIoanPage.startInstance,
+          "page": const PropertyIoanPage(),
+        },
+        {
+          "title": "News",
+          "icon": Assets.propertyNews2x,
+          "pageStartInstanceFn": PropertyNewsPage.startInstance,
+          "page": const PropertyNewsPage(),
+        }
+      ],
+    );
+  }
+
+  @override
+  PropertyVmState build(){
+    final state = initState();
+    return state;
+  }
+
+  // 页面切换
+  switchPage(int index, context){
+    final _topSectionsData = state.topSectionsData;
+    Log.d("当前页面${_topSectionsData[index]['pageStartInstanceFn']}");
+    final pageStartInstanceFn = _topSectionsData[index]['pageStartInstanceFn'] as Function({BuildContext? context});
+    pageStartInstanceFn(context:context);
+  }
+
+}

+ 25 - 0
packages/cpt_property/lib/modules/property/vm/property_vm.g.dart

@@ -0,0 +1,25 @@
+// GENERATED CODE - DO NOT MODIFY BY HAND
+
+part of 'property_vm.dart';
+
+// **************************************************************************
+// RiverpodGenerator
+// **************************************************************************
+
+String _$propertyVmHash() => r'f98e7cc04acc4620ceeab7bf45bdc1459648e4b3';
+
+/// See also [PropertyVm].
+@ProviderFor(PropertyVm)
+final propertyVmProvider =
+    AutoDisposeNotifierProvider<PropertyVm, PropertyVmState>.internal(
+  PropertyVm.new,
+  name: r'propertyVmProvider',
+  debugGetCreateSourceHash:
+      const bool.fromEnvironment('dart.vm.product') ? null : _$propertyVmHash,
+  dependencies: null,
+  allTransitiveDependencies: null,
+);
+
+typedef _$PropertyVm = AutoDisposeNotifier<PropertyVmState>;
+// ignore_for_file: type=lint
+// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member, deprecated_member_use_from_same_package

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

@@ -0,0 +1,33 @@
+import 'package:flutter/material.dart';
+import 'package:auto_route/auto_route.dart';
+import 'package:hooks_riverpod/hooks_riverpod.dart';
+import 'package:router/ext/auto_router_extensions.dart';
+
+import '../../../router/page/property_page_router.dart';
+import '../vm/property_rent_vm.dart';
+
+@RoutePage()
+class PropertyRentPage extends HookConsumerWidget {
+  const PropertyRentPage({Key? key}) : super(key: key);
+
+  //启动当前页面
+  static void startInstance({BuildContext? context}) {
+    if (context != null) {
+      context.router.push(const PropertyRentPageRoute());
+    } else {
+      appRouter.push(const PropertyRentPageRoute());
+    }
+  }
+
+  @override
+  Widget build(BuildContext context, WidgetRef ref) {
+    final _vm = ref.read(propertyRentVmProvider.notifier);
+
+    return Scaffold(
+      // appBar: AppBar(title: Text("资产")),
+      body: Center(
+        child: Text("房屋rent的主页面"),
+      ),
+    );
+  }
+}

+ 14 - 0
packages/cpt_property/lib/modules/rent/vm/property_rent_vm.dart

@@ -0,0 +1,14 @@
+
+import 'package:riverpod_annotation/riverpod_annotation.dart';
+
+part 'property_rent_vm.g.dart';
+
+@riverpod
+class PropertyRentVm extends _$PropertyRentVm {
+
+  @override
+  void build(){
+
+  }
+
+}

+ 26 - 0
packages/cpt_property/lib/modules/rent/vm/property_rent_vm.g.dart

@@ -0,0 +1,26 @@
+// GENERATED CODE - DO NOT MODIFY BY HAND
+
+part of 'property_rent_vm.dart';
+
+// **************************************************************************
+// RiverpodGenerator
+// **************************************************************************
+
+String _$propertyRentVmHash() => r'7746ebd091e4bfe92688f58d8fe1aa74eb7c09fc';
+
+/// See also [PropertyRentVm].
+@ProviderFor(PropertyRentVm)
+final propertyRentVmProvider =
+    AutoDisposeNotifierProvider<PropertyRentVm, void>.internal(
+  PropertyRentVm.new,
+  name: r'propertyRentVmProvider',
+  debugGetCreateSourceHash: const bool.fromEnvironment('dart.vm.product')
+      ? null
+      : _$propertyRentVmHash,
+  dependencies: null,
+  allTransitiveDependencies: null,
+);
+
+typedef _$PropertyRentVm = AutoDisposeNotifier<void>;
+// ignore_for_file: type=lint
+// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member, deprecated_member_use_from_same_package

+ 33 - 0
packages/cpt_property/lib/modules/sale/page/property_sale_page.dart

@@ -0,0 +1,33 @@
+import 'package:flutter/material.dart';
+import 'package:auto_route/auto_route.dart';
+import 'package:hooks_riverpod/hooks_riverpod.dart';
+import 'package:router/ext/auto_router_extensions.dart';
+
+import '../../../router/page/property_page_router.dart';
+import '../vm/property_sale_vm.dart';
+
+@RoutePage()
+class PropertySalePage extends HookConsumerWidget {
+  const PropertySalePage({Key? key}) : super(key: key);
+
+  //启动当前页面
+  static void startInstance({BuildContext? context}) {
+    if (context != null) {
+      context.router.push(const PropertySalePageRoute());
+    } else {
+      appRouter.push(const PropertySalePageRoute());
+    }
+  }
+
+  @override
+  Widget build(BuildContext context, WidgetRef ref) {
+    final _vm = ref.read(propertySaleVmProvider.notifier);
+
+    return Scaffold(
+      // appBar: AppBar(title: Text("资产")),
+      body: Center(
+        child: Text("房屋sale的主页面"),
+      ),
+    );
+  }
+}

+ 14 - 0
packages/cpt_property/lib/modules/sale/vm/property_sale_vm.dart

@@ -0,0 +1,14 @@
+
+import 'package:riverpod_annotation/riverpod_annotation.dart';
+
+part 'property_sale_vm.g.dart';
+
+@riverpod
+class PropertySaleVm extends _$PropertySaleVm {
+
+  @override
+  void build(){
+
+  }
+
+}

+ 26 - 0
packages/cpt_property/lib/modules/sale/vm/property_sale_vm.g.dart

@@ -0,0 +1,26 @@
+// GENERATED CODE - DO NOT MODIFY BY HAND
+
+part of 'property_sale_vm.dart';
+
+// **************************************************************************
+// RiverpodGenerator
+// **************************************************************************
+
+String _$propertySaleVmHash() => r'0f03c435057215656f637aef71c2458299f34fa3';
+
+/// See also [PropertySaleVm].
+@ProviderFor(PropertySaleVm)
+final propertySaleVmProvider =
+    AutoDisposeNotifierProvider<PropertySaleVm, void>.internal(
+  PropertySaleVm.new,
+  name: r'propertySaleVmProvider',
+  debugGetCreateSourceHash: const bool.fromEnvironment('dart.vm.product')
+      ? null
+      : _$propertySaleVmHash,
+  dependencies: null,
+  allTransitiveDependencies: null,
+);
+
+typedef _$PropertySaleVm = AutoDisposeNotifier<void>;
+// ignore_for_file: type=lint
+// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member, deprecated_member_use_from_same_package

+ 32 - 3
packages/cpt_property/lib/router/page/property_page_router.dart

@@ -4,6 +4,10 @@ import 'package:router/ext/auto_router_extensions.dart';
 import 'package:router/path/router_path.dart';
 
 import '../../modules/property/page/property_page.dart';
+import '../../modules/ioan/page/property_ioan_page.dart';
+import '../../modules/news/page/property_news_page.dart';
+import '../../modules/sale/page/property_sale_page.dart';
+import '../../modules/rent/page/property_rent_page.dart';
 
 
 part 'property_page_router.gr.dart';
@@ -14,8 +18,33 @@ part 'property_page_router.gr.dart';
 @AutoRouterConfig(replaceInRouteName: 'Page|Screen,PageRoute')
 class PropertyPageRouter extends _$PropertyPageRouter {
   @override
-  List<AutoRoute> get routes => [
-
-    CustomRoute(page: PropertyPageRoute.page, path: RouterPath.property, transitionsBuilder: applySlideTransition),
+  List<AutoRoute> get routes  => [
+    CustomRoute(
+      page: PropertyPageRoute.page,
+      path: RouterPath.property,
+      transitionsBuilder: applySlideTransition,
+      children: [
+        CustomRoute(
+          page: PropertyIoanPageRoute.page,
+          path: RouterPath.propertyIoan,
+          transitionsBuilder: applySlideTransition,
+        ),
+        CustomRoute(
+          page: PropertyNewsPageRoute.page,
+          path: RouterPath.propertyNews,
+          transitionsBuilder: applySlideTransition,
+        ),
+        CustomRoute(
+          page: PropertySalePageRoute.page,
+          path: RouterPath.propertySale,
+          transitionsBuilder: applySlideTransition,
+        ),
+        CustomRoute(
+          page: PropertyRentPageRoute.page,
+          path: RouterPath.propertyRent,
+          transitionsBuilder: applySlideTransition,
+        ),
+      ]
+    ),
   ];
 }

+ 81 - 1
packages/cpt_property/lib/router/page/property_page_router.gr.dart

@@ -15,16 +15,68 @@ abstract class _$PropertyPageRouter extends RootStackRouter {
 
   @override
   final Map<String, PageFactory> pagesMap = {
+    PropertyIoanPageRoute.name: (routeData) {
+      return AutoRoutePage<dynamic>(
+        routeData: routeData,
+        child: const PropertyIoanPage(),
+      );
+    },
+    PropertyNewsPageRoute.name: (routeData) {
+      return AutoRoutePage<dynamic>(
+        routeData: routeData,
+        child: const PropertyNewsPage(),
+      );
+    },
     PropertyPageRoute.name: (routeData) {
       return AutoRoutePage<dynamic>(
         routeData: routeData,
         child: const PropertyPage(),
       );
-    }
+    },
+    PropertyRentPageRoute.name: (routeData) {
+      return AutoRoutePage<dynamic>(
+        routeData: routeData,
+        child: const PropertyRentPage(),
+      );
+    },
+    PropertySalePageRoute.name: (routeData) {
+      return AutoRoutePage<dynamic>(
+        routeData: routeData,
+        child: const PropertySalePage(),
+      );
+    },
   };
 }
 
 /// generated route for
+/// [PropertyIoanPage]
+class PropertyIoanPageRoute extends PageRouteInfo<void> {
+  const PropertyIoanPageRoute({List<PageRouteInfo>? children})
+      : super(
+          PropertyIoanPageRoute.name,
+          initialChildren: children,
+        );
+
+  static const String name = 'PropertyIoanPageRoute';
+
+  static const PageInfo<void> page = PageInfo<void>(name);
+}
+
+/// generated route for
+/// [PropertyNewsPage]
+class PropertyNewsPageRoute extends PageRouteInfo<void> {
+  const PropertyNewsPageRoute({List<PageRouteInfo>? children})
+      : super(
+          PropertyNewsPageRoute.name,
+          initialChildren: children,
+        );
+
+  static const String name = 'PropertyNewsPageRoute';
+
+  static const PageInfo<void> page = PageInfo<void>(name);
+}
+
+/// generated route for
 /// [PropertyPage]
 class PropertyPageRoute extends PageRouteInfo<void> {
   const PropertyPageRoute({List<PageRouteInfo>? children})
@@ -37,3 +89,31 @@ class PropertyPageRoute extends PageRouteInfo<void> {
 
   static const PageInfo<void> page = PageInfo<void>(name);
 }
+
+/// generated route for
+/// [PropertyRentPage]
+class PropertyRentPageRoute extends PageRouteInfo<void> {
+  const PropertyRentPageRoute({List<PageRouteInfo>? children})
+      : super(
+          PropertyRentPageRoute.name,
+          initialChildren: children,
+        );
+
+  static const String name = 'PropertyRentPageRoute';
+
+  static const PageInfo<void> page = PageInfo<void>(name);
+}
+
+/// generated route for
+/// [PropertySalePage]
+class PropertySalePageRoute extends PageRouteInfo<void> {
+  const PropertySalePageRoute({List<PageRouteInfo>? children})
+      : super(
+          PropertySalePageRoute.name,
+          initialChildren: children,
+        );
+
+  static const String name = 'PropertySalePageRoute';
+
+  static const PageInfo<void> page = PageInfo<void>(name);
+}

+ 7 - 7
packages/cpt_property/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_rewards/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cpt_services/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 6 - 6
packages/cs_domain/pubspec_overrides.yaml

@@ -1,14 +1,14 @@
 # melos_managed_dependency_overrides: cs_resources,plugin_platform,shared,widgets,plugin_basic,router
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 7 - 7
packages/cs_initializer/pubspec_overrides.yaml

@@ -1,16 +1,16 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_basic,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_basic:
-    path: ../cs_plugin_basic
+    path: ..\\cs_plugin_basic
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 6 - 6
packages/cs_plugin_basic/pubspec_overrides.yaml

@@ -1,14 +1,14 @@
 # melos_managed_dependency_overrides: cs_resources,domain,plugin_platform,router,shared,widgets
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   domain:
-    path: ../cs_domain
+    path: ..\\cs_domain
   plugin_platform:
-    path: ../cs_plugin_platform
+    path: ..\\cs_plugin_platform
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

+ 4 - 4
packages/cs_plugin_platform/pubspec_overrides.yaml

@@ -1,10 +1,10 @@
 # melos_managed_dependency_overrides: cs_resources,shared,widgets,router
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared
   widgets:
-    path: ../cs_widgets
+    path: ..\\cs_widgets

BIN
packages/cs_resources/assets/property/advice_pic@2x.png


BIN
packages/cs_resources/assets/property/approval@2x.png


BIN
packages/cs_resources/assets/property/conveyancing_lawyer@2x.png


BIN
packages/cs_resources/assets/property/home_equity_loans@2x.png


BIN
packages/cs_resources/assets/property/home_loan_bg@2x.png


BIN
packages/cs_resources/assets/property/ioan@2x.png


BIN
packages/cs_resources/assets/property/new_home_loans@2x.png


BIN
packages/cs_resources/assets/property/news@2x.png


BIN
packages/cs_resources/assets/property/our_partners@2x.png


BIN
packages/cs_resources/assets/property/overseas_home_loan@2x.png


BIN
packages/cs_resources/assets/property/refinancing@2x.png


BIN
packages/cs_resources/assets/property/rent@2x.png


BIN
packages/cs_resources/assets/property/sale@2x.png


+ 13 - 0
packages/cs_resources/lib/generated/assets.dart

@@ -26,5 +26,18 @@ class Assets {
   static const String baseServiceTitleBarFilterIcon = 'assets/base_service/title_bar_filter_icon.webp';
   static const String baseServiceTriangleDropDown = 'assets/base_service/triangle_drop_down.webp';
   static const String baseServiceTriangleDropDownIcon = 'assets/base_service/triangle_drop_down_icon.webp';
+  static const String propertyAdvicePic2x = 'assets/property/advice_pic@2x.png';
+  static const String propertyApproval2x = 'assets/property/approval@2x.png';
+  static const String propertyConveyancingLawyer2x = 'assets/property/conveyancing_lawyer@2x.png';
+  static const String propertyHomeEquityLoans2x = 'assets/property/home_equity_loans@2x.png';
+  static const String propertyHomeLoanBg2x = 'assets/property/home_loan_bg@2x.png';
+  static const String propertyIoan2x = 'assets/property/ioan@2x.png';
+  static const String propertyNewHomeLoans2x = 'assets/property/new_home_loans@2x.png';
+  static const String propertyNews2x = 'assets/property/news@2x.png';
+  static const String propertyOurPartners2x = 'assets/property/our_partners@2x.png';
+  static const String propertyOverseasHomeLoan2x = 'assets/property/overseas_home_loan@2x.png';
+  static const String propertyRefinancing2x = 'assets/property/refinancing@2x.png';
+  static const String propertyRent2x = 'assets/property/rent@2x.png';
+  static const String propertySale2x = 'assets/property/sale@2x.png';
 
 }

+ 1 - 0
packages/cs_resources/pubspec.yaml

@@ -27,6 +27,7 @@ flutter:
     - assets/
     - assets/base_lib/
     - assets/base_service/
+    - assets/property/
 
 
 flutter_intl:

+ 4 - 0
packages/cs_router/lib/path/router_path.dart

@@ -34,6 +34,10 @@ class RouterPath {
 
   //房屋资产
   static const property = '/property';
+  static const propertyIoan = 'property/ioan';
+  static const propertyNews = 'property/news';
+  static const propertySale = 'property/sale';
+  static const propertyRent = 'property/rent';
 
   //奖励
   static const rewards = '/rewards';

+ 3 - 3
packages/cs_widgets/pubspec_overrides.yaml

@@ -1,8 +1,8 @@
 # melos_managed_dependency_overrides: cs_resources,shared,router
 dependency_overrides:
   cs_resources:
-    path: ../cs_resources
+    path: ..\\cs_resources
   router:
-    path: ../cs_router
+    path: ..\\cs_router
   shared:
-    path: ../cs_shared
+    path: ..\\cs_shared