Browse Source

Merge branch 'master' of http://192.168.0.138:3000/FnuoOS_ZhiYing/zhiying_comm

 Conflicts:
	.dart_tool/package_config.json
tags/0.0.3+3
“yanghuaxuan” 3 years ago
parent
commit
9dd3501937
9 changed files with 139 additions and 109 deletions
  1. +101
    -95
      .dart_tool/package_config.json
  2. +7
    -0
      example/pubspec.lock
  3. +10
    -14
      lib/models/user/user_info_model_notifier.dart
  4. +5
    -0
      lib/util/event_util/event_util.dart
  5. +2
    -0
      lib/util/event_util/log_out.dart
  6. +3
    -0
      lib/util/event_util/login_success_event.dart
  7. +3
    -0
      lib/util/router_util.dart
  8. +7
    -0
      pubspec.lock
  9. +1
    -0
      pubspec.yaml

+ 101
- 95
.dart_tool/package_config.json View File

@@ -3,565 +3,571 @@
"packages": [ "packages": [
{ {
"name": "ali_auth_wbq", "name": "ali_auth_wbq",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/git/zhiying_ali_auth_wbq-f6421fe5735eab13738946da8fa7405e7aa952c6/",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/git/zhiying_ali_auth_wbq-f6421fe5735eab13738946da8fa7405e7aa952c6/",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "archive", "name": "archive",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/archive-2.0.13",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/archive-2.0.13",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "args", "name": "args",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/args-1.6.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/args-1.6.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.3" "languageVersion": "2.3"
}, },
{ {
"name": "async", "name": "async",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/async-2.4.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/async-2.4.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "bloc", "name": "bloc",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/bloc-4.0.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/bloc-4.0.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "boolean_selector", "name": "boolean_selector",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/boolean_selector-2.0.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/boolean_selector-2.0.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.4" "languageVersion": "2.4"
}, },
{ {
"name": "cached_network_image", "name": "cached_network_image",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/cached_network_image-2.2.0+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/cached_network_image-2.2.0+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "charcode", "name": "charcode",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/charcode-1.1.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/charcode-1.1.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "clock", "name": "clock",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/clock-1.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/clock-1.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "collection", "name": "collection",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/collection-1.14.12",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/collection-1.14.12",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "convert", "name": "convert",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/convert-2.1.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/convert-2.1.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.17" "languageVersion": "1.17"
}, },
{ {
"name": "cookie_jar", "name": "cookie_jar",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/cookie_jar-1.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/cookie_jar-1.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.20" "languageVersion": "1.20"
}, },
{ {
"name": "crypto", "name": "crypto",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/crypto-2.1.4",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/crypto-2.1.4",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "device_info", "name": "device_info",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/device_info-0.4.2+9",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/device_info-0.4.2+9",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "device_info_platform_interface", "name": "device_info_platform_interface",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/device_info_platform_interface-1.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/device_info_platform_interface-1.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "dio", "name": "dio",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/dio-3.0.10",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/dio-3.0.10",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.4" "languageVersion": "2.4"
}, },
{ {
"name": "dio_cookie_manager", "name": "dio_cookie_manager",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/dio_cookie_manager-1.0.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/dio_cookie_manager-1.0.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.4" "languageVersion": "2.4"
}, },
{ {
"name": "equatable", "name": "equatable",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/equatable-1.2.5",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/equatable-1.2.5",
"packageUri": "lib/",
"languageVersion": "2.0"
},
{
"name": "event_bus",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/event_bus-1.1.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "ffi", "name": "ffi",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/ffi-0.1.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/ffi-0.1.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "file", "name": "file",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/file-5.2.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/file-5.2.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "flutter", "name": "flutter",
"rootUri": "file:///Users/fnuser02/flutter/packages/flutter",
"rootUri": "file:///D:/flutter/flutter/packages/flutter",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "flutter_alibc", "name": "flutter_alibc",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/git/zhiying_flutter_alibc-ba413f84090cd58b8b769ca43ff3ef65a0e53274/",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/git/zhiying_flutter_alibc-ba413f84090cd58b8b769ca43ff3ef65a0e53274/",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "flutter_bloc", "name": "flutter_bloc",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_bloc-4.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_bloc-4.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "flutter_cache_manager", "name": "flutter_cache_manager",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_cache_manager-1.4.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_cache_manager-1.4.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "flutter_native_image", "name": "flutter_native_image",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_native_image-0.0.5+2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_native_image-0.0.5+2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.19" "languageVersion": "1.19"
}, },
{ {
"name": "flutter_screenutil", "name": "flutter_screenutil",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_screenutil-1.1.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_screenutil-1.1.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "flutter_test", "name": "flutter_test",
"rootUri": "file:///Users/fnuser02/flutter/packages/flutter_test",
"rootUri": "file:///D:/flutter/flutter/packages/flutter_test",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "flutter_update_dialog", "name": "flutter_update_dialog",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_update_dialog-1.0.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/flutter_update_dialog-1.0.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "flutter_web_plugins", "name": "flutter_web_plugins",
"rootUri": "file:///Users/fnuser02/flutter/packages/flutter_web_plugins",
"rootUri": "file:///D:/flutter/flutter/packages/flutter_web_plugins",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "flutter_xupdate", "name": "flutter_xupdate",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/git/flutter_xupdate-d17c695461ee4588dec990533d7467c11884cd0f/",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/git/flutter_xupdate-d17c695461ee4588dec990533d7467c11884cd0f/",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "fluttertoast", "name": "fluttertoast",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/fluttertoast-4.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/fluttertoast-4.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "http", "name": "http",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/http-0.12.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/http-0.12.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.4" "languageVersion": "2.4"
}, },
{ {
"name": "http_parser", "name": "http_parser",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/http_parser-3.1.4",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/http_parser-3.1.4",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.3" "languageVersion": "2.3"
}, },
{ {
"name": "image", "name": "image",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/image-2.1.12",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/image-2.1.12",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "imei_plugin", "name": "imei_plugin",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/imei_plugin-1.2.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/imei_plugin-1.2.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "intl", "name": "intl",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/intl-0.16.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/intl-0.16.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.5" "languageVersion": "2.5"
}, },
{ {
"name": "jdsdk", "name": "jdsdk",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/jdsdk-0.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/jdsdk-0.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "loading_indicator", "name": "loading_indicator",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/loading_indicator-1.2.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/loading_indicator-1.2.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "matcher", "name": "matcher",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/matcher-0.12.6",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/matcher-0.12.6",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "meta", "name": "meta",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/meta-1.1.8",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/meta-1.1.8",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.12" "languageVersion": "1.12"
}, },
{ {
"name": "moblink", "name": "moblink",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/git/moblink-5472bb698d70e336cf55febb9b0a209411466632/",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/git/moblink-5472bb698d70e336cf55febb9b0a209411466632/",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "mobsms", "name": "mobsms",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/mobsms-1.1.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/mobsms-1.1.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "nested", "name": "nested",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/nested-0.0.4",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/nested-0.0.4",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "package_info", "name": "package_info",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/package_info-0.4.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/package_info-0.4.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "path", "name": "path",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/path-1.6.4",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/path-1.6.4",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "path_provider", "name": "path_provider",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider-1.6.21",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider-1.6.21",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "path_provider_linux", "name": "path_provider_linux",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_linux-0.0.1+2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_linux-0.0.1+2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "path_provider_macos", "name": "path_provider_macos",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_macos-0.0.4+4",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_macos-0.0.4+4",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "path_provider_platform_interface", "name": "path_provider_platform_interface",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_platform_interface-1.0.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_platform_interface-1.0.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "path_provider_windows", "name": "path_provider_windows",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_windows-0.0.4+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/path_provider_windows-0.0.4+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "pedantic", "name": "pedantic",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/pedantic-1.9.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/pedantic-1.9.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "permission_handler", "name": "permission_handler",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/git/permission_handler-b8c45c4c20221ac39fe083113fc360cc632f33a4/",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/git/permission_handler-b8c45c4c20221ac39fe083113fc360cc632f33a4/",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "permission_handler_platform_interface", "name": "permission_handler_platform_interface",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/permission_handler_platform_interface-2.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/permission_handler_platform_interface-2.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "petitparser", "name": "petitparser",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/petitparser-2.4.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/petitparser-2.4.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.4" "languageVersion": "2.4"
}, },
{ {
"name": "photo_view", "name": "photo_view",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/photo_view-0.10.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/photo_view-0.10.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "platform", "name": "platform",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/platform-2.2.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/platform-2.2.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.24" "languageVersion": "1.24"
}, },
{ {
"name": "plugin_platform_interface", "name": "plugin_platform_interface",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/plugin_platform_interface-1.0.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/plugin_platform_interface-1.0.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "process", "name": "process",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/process-3.0.13",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/process-3.0.13",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "provider", "name": "provider",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/provider-4.3.2+2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/provider-4.3.2+2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "quiver", "name": "quiver",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/quiver-2.1.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/quiver-2.1.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "rxdart", "name": "rxdart",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/rxdart-0.24.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/rxdart-0.24.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "save_image", "name": "save_image",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/save_image-1.0.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/save_image-1.0.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "secverify", "name": "secverify",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/secverify-1.0.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/secverify-1.0.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shared_preferences", "name": "shared_preferences",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences-0.5.12+2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences-0.5.12+2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shared_preferences_linux", "name": "shared_preferences_linux",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_linux-0.0.2+2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_linux-0.0.2+2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shared_preferences_macos", "name": "shared_preferences_macos",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_macos-0.0.1+10",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_macos-0.0.1+10",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shared_preferences_platform_interface", "name": "shared_preferences_platform_interface",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_platform_interface-1.0.4",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_platform_interface-1.0.4",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shared_preferences_web", "name": "shared_preferences_web",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_web-0.1.2+7",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_web-0.1.2+7",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shared_preferences_windows", "name": "shared_preferences_windows",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_windows-0.0.1+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shared_preferences_windows-0.0.1+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "sharesdk_plugin", "name": "sharesdk_plugin",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/sharesdk_plugin-1.2.8",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/sharesdk_plugin-1.2.8",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "shimmer", "name": "shimmer",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/shimmer-1.1.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/shimmer-1.1.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.20" "languageVersion": "1.20"
}, },
{ {
"name": "sky_engine", "name": "sky_engine",
"rootUri": "file:///Users/fnuser02/flutter/bin/cache/pkg/sky_engine",
"rootUri": "file:///D:/flutter/flutter/bin/cache/pkg/sky_engine",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.11" "languageVersion": "1.11"
}, },
{ {
"name": "source_span", "name": "source_span",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/source_span-1.7.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/source_span-1.7.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
{ {
"name": "sqflite", "name": "sqflite",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite-1.3.1+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite-1.3.1+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "sqflite_common", "name": "sqflite_common",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite_common-1.0.2+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/sqflite_common-1.0.2+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "stack_trace", "name": "stack_trace",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/stack_trace-1.9.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/stack_trace-1.9.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.23" "languageVersion": "1.23"
}, },
{ {
"name": "stream_channel", "name": "stream_channel",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/stream_channel-2.0.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/stream_channel-2.0.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "string_scanner", "name": "string_scanner",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/string_scanner-1.0.5",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/string_scanner-1.0.5",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "synchronized", "name": "synchronized",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/synchronized-2.2.0+2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/synchronized-2.2.0+2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.8" "languageVersion": "2.8"
}, },
{ {
"name": "term_glyph", "name": "term_glyph",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/term_glyph-1.1.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/term_glyph-1.1.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "1.8" "languageVersion": "1.8"
}, },
{ {
"name": "test_api", "name": "test_api",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/test_api-0.2.15",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/test_api-0.2.15",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.4" "languageVersion": "2.4"
}, },
{ {
"name": "typed_data", "name": "typed_data",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/typed_data-1.1.6",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/typed_data-1.1.6",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "url_launcher", "name": "url_launcher",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher-5.7.5",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher-5.7.5",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "url_launcher_linux", "name": "url_launcher_linux",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_linux-0.0.1+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_linux-0.0.1+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "url_launcher_macos", "name": "url_launcher_macos",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_macos-0.0.1+8",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_macos-0.0.1+8",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "url_launcher_platform_interface", "name": "url_launcher_platform_interface",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_platform_interface-1.0.8",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_platform_interface-1.0.8",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "url_launcher_web", "name": "url_launcher_web",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_web-0.1.4+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_web-0.1.4+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "url_launcher_windows", "name": "url_launcher_windows",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_windows-0.0.1+1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/url_launcher_windows-0.0.1+1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.1" "languageVersion": "2.1"
}, },
{ {
"name": "uuid", "name": "uuid",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/uuid-2.2.2",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/uuid-2.2.2",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.2" "languageVersion": "2.2"
}, },
{ {
"name": "vector_math", "name": "vector_math",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/vector_math-2.0.8",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/vector_math-2.0.8",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.0" "languageVersion": "2.0"
}, },
{ {
"name": "webview_flutter", "name": "webview_flutter",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/webview_flutter-0.3.24",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/webview_flutter-0.3.24",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "win32", "name": "win32",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/win32-1.7.3",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/win32-1.7.3",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.7" "languageVersion": "2.7"
}, },
{ {
"name": "xdg_directories", "name": "xdg_directories",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/xdg_directories-0.1.0",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/xdg_directories-0.1.0",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.3" "languageVersion": "2.3"
}, },
{ {
"name": "xml", "name": "xml",
"rootUri": "file:///Users/fnuser02/flutter/.pub-cache/hosted/pub.flutter-io.cn/xml-3.6.1",
"rootUri": "file:///D:/flutter/flutter/.pub-cache/hosted/pub.flutter-io.cn/xml-3.6.1",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "2.6" "languageVersion": "2.6"
}, },
@@ -572,7 +578,7 @@
"languageVersion": "2.1" "languageVersion": "2.1"
} }
], ],
"generated": "2020-12-31T06:56:37.245843Z",
"generated": "2021-01-06T08:05:40.700817Z",
"generator": "pub", "generator": "pub",
"generatorVersion": "2.8.2" "generatorVersion": "2.8.2"
} }

+ 7
- 0
example/pubspec.lock View File

@@ -136,6 +136,13 @@ packages:
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "1.2.5" version: "1.2.5"
event_bus:
dependency: transitive
description:
name: event_bus
url: "https://pub.flutter-io.cn"
source: hosted
version: "1.1.1"
ffi: ffi:
dependency: transitive dependency: transitive
description: description:


+ 10
- 14
lib/models/user/user_info_model_notifier.dart View File

@@ -3,6 +3,8 @@ import 'dart:convert';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_alibc/flutter_alibc.dart'; import 'package:flutter_alibc/flutter_alibc.dart';
import 'package:zhiying_comm/models/user/user_info_model.dart'; import 'package:zhiying_comm/models/user/user_info_model.dart';
import 'package:zhiying_comm/util/event_util/event_util.dart';
import 'package:zhiying_comm/util/event_util/log_out.dart';
import 'package:zhiying_comm/util/global_config.dart'; import 'package:zhiying_comm/util/global_config.dart';
import 'package:zhiying_comm/util/log/let_log.dart'; import 'package:zhiying_comm/util/log/let_log.dart';
import 'package:zhiying_comm/util/mob_util/mob_util.dart'; import 'package:zhiying_comm/util/mob_util/mob_util.dart';
@@ -54,12 +56,9 @@ class UserInfoNotifier with ChangeNotifier {
print('${loginUser.toString()}'); print('${loginUser.toString()}');
_userInfo = loginUser; _userInfo = loginUser;
// 缓存数据 // 缓存数据
await SharedPreferencesUtil.setStringValue(
GlobalConfig.SHARED_KEY_TOKEN, loginUser.token);
await SharedPreferencesUtil.setStringValue(
GlobalConfig.SHARED_KEY_MOBILE, loginUser.mobile);
await SharedPreferencesUtil.setStringValue(
GlobalConfig.SHARED_KEY_USER_INFO, jsonEncode(loginUser.toJson()));
await SharedPreferencesUtil.setStringValue(GlobalConfig.SHARED_KEY_TOKEN, loginUser.token);
await SharedPreferencesUtil.setStringValue(GlobalConfig.SHARED_KEY_MOBILE, loginUser.mobile);
await SharedPreferencesUtil.setStringValue(GlobalConfig.SHARED_KEY_USER_INFO, jsonEncode(loginUser.toJson()));
notifyListeners(); notifyListeners();
} }


@@ -67,18 +66,16 @@ class UserInfoNotifier with ChangeNotifier {
void unLogin() async { void unLogin() async {
_userInfo = null; _userInfo = null;
// 清除缓存数据 // 清除缓存数据
await SharedPreferencesUtil.setStringValue(
GlobalConfig.SHARED_KEY_TOKEN, '');
await SharedPreferencesUtil.setStringValue(
GlobalConfig.SHARED_KEY_MOBILE, '');
await SharedPreferencesUtil.setStringValue(
GlobalConfig.SHARED_KEY_USER_INFO, '');
await SharedPreferencesUtil.setStringValue(GlobalConfig.SHARED_KEY_TOKEN, '');
await SharedPreferencesUtil.setStringValue(GlobalConfig.SHARED_KEY_MOBILE, '');
await SharedPreferencesUtil.setStringValue(GlobalConfig.SHARED_KEY_USER_INFO, '');
// 退出淘宝登录 // 退出淘宝登录
FlutterAlibc.loginOut(); FlutterAlibc.loginOut();
// 退出QQ登录 // 退出QQ登录
MobUtil.cancelQQAuth(); MobUtil.cancelQQAuth();
// 退出微信登录 // 退出微信登录
MobUtil.cancelWeChatAuth(); MobUtil.cancelWeChatAuth();
EventUtil.instance.fire(LogOut());
notifyListeners(); notifyListeners();
} }


@@ -88,8 +85,7 @@ class UserInfoNotifier with ChangeNotifier {
return _userInfo; return _userInfo;
} }
try { try {
String userInfoJson = await SharedPreferencesUtil.getStringValue(
GlobalConfig.SHARED_KEY_USER_INFO);
String userInfoJson = await SharedPreferencesUtil.getStringValue(GlobalConfig.SHARED_KEY_USER_INFO);
if (userInfoJson == null || userInfoJson == '') { if (userInfoJson == null || userInfoJson == '') {
_userInfo = UserInfoModel(); _userInfo = UserInfoModel();
} else { } else {


+ 5
- 0
lib/util/event_util/event_util.dart View File

@@ -0,0 +1,5 @@
import 'package:event_bus/event_bus.dart';

class EventUtil{
static EventBus instance = new EventBus();
}

+ 2
- 0
lib/util/event_util/log_out.dart View File

@@ -0,0 +1,2 @@
class LogOut{
}

+ 3
- 0
lib/util/event_util/login_success_event.dart View File

@@ -0,0 +1,3 @@
class LoginSuccessEvent{

}

+ 3
- 0
lib/util/router_util.dart View File

@@ -5,6 +5,8 @@ import 'package:flutter/material.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
import 'package:zhiying_comm/pages/login_page/account/login_account_page.dart'; import 'package:zhiying_comm/pages/login_page/account/login_account_page.dart';
import 'package:zhiying_comm/pages/login_page/login_page.dart'; import 'package:zhiying_comm/pages/login_page/login_page.dart';
import 'package:zhiying_comm/util/event_util/event_util.dart';
import 'package:zhiying_comm/util/event_util/login_success_event.dart';
import 'package:zhiying_comm/util/shared_prefe_util.dart'; import 'package:zhiying_comm/util/shared_prefe_util.dart';
import 'package:zhiying_comm/zhiying_comm.dart'; import 'package:zhiying_comm/zhiying_comm.dart';


@@ -77,6 +79,7 @@ class RouterUtil {
static Future goBackHomePage(BuildContext context, {bool needUpdateAuth = true}) async{ static Future goBackHomePage(BuildContext context, {bool needUpdateAuth = true}) async{
if(needUpdateAuth) { if(needUpdateAuth) {
await TaobaoAuth.initAuth(context); await TaobaoAuth.initAuth(context);
EventUtil.instance.fire(LoginSuccessEvent());
} }
Navigator.popUntil(context, ModalRoute.withName('/homePage')); Navigator.popUntil(context, ModalRoute.withName('/homePage'));
} }


+ 7
- 0
pubspec.lock View File

@@ -129,6 +129,13 @@ packages:
url: "https://pub.flutter-io.cn" url: "https://pub.flutter-io.cn"
source: hosted source: hosted
version: "1.2.5" version: "1.2.5"
event_bus:
dependency: "direct main"
description:
name: event_bus
url: "https://pub.flutter-io.cn"
source: hosted
version: "1.1.1"
ffi: ffi:
dependency: transitive dependency: transitive
description: description:


+ 1
- 0
pubspec.yaml View File

@@ -79,6 +79,7 @@ dependencies:


dio_cookie_manager: 1.0.0 dio_cookie_manager: 1.0.0


event_bus: 1.1.1


dev_dependencies: dev_dependencies:
flutter_test: flutter_test:


Loading…
Cancel
Save