diff --git a/lib/main.dart b/lib/main.dart index a1e57fee..97b77fe9 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,6 +1,8 @@ import 'dart:io'; +import 'package:akuCommunity/pages/home/home_page.dart'; import 'package:akuCommunity/pages/sign/sign_in_page.dart'; +import 'package:akuCommunity/pages/tab_navigator.dart'; import 'package:amap_map_fluttify/amap_map_fluttify.dart'; import 'package:ani_route/ani_route.dart'; import 'package:flutter/material.dart'; @@ -62,7 +64,7 @@ class _MyAppState extends State { visualDensity: VisualDensity.adaptivePlatformDensity, ), // home: TabNavigator(), - home: SignInPage(), + home: TabNavigator(), //国际化支持 localizationsDelegates: [ PickerLocalizationsDelegate.delegate, diff --git a/lib/pages/goods_details/widget/product_content.dart b/lib/pages/goods_details/widget/product_content.dart index 0bec9373..cc29e95e 100644 --- a/lib/pages/goods_details/widget/product_content.dart +++ b/lib/pages/goods_details/widget/product_content.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter_icons/flutter_icons.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart'; +import 'package:fluwx/fluwx.dart'; class ProductContent extends StatelessWidget { final String itemprice, itemtitle, itemshorttitle, itemdesc; @@ -102,7 +103,14 @@ class ProductContent extends StatelessWidget { right: 0, top: ScreenUtil().setWidth(169), child: InkWell( - onTap: () {}, + onTap: () { + shareToWeChat(WeChatShareWebPageModel( + 'https://mobile.baidu.com/item?docid=27505288', + + title:itemtitle, + description: '前往小蜜蜂智慧社区查看吧', + )); + }, child: Container( decoration: BoxDecoration( color: Color(0xfff0f0f0), diff --git a/lib/pages/home/home_page.dart b/lib/pages/home/home_page.dart index e0d2f6d4..a25135a7 100644 --- a/lib/pages/home/home_page.dart +++ b/lib/pages/home/home_page.dart @@ -3,6 +3,7 @@ import 'dart:convert'; import 'dart:io'; import 'package:flutter/material.dart'; import 'package:flutter/cupertino.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:pull_to_refresh/pull_to_refresh.dart'; import 'package:akuCommunity/base/assets_image.dart'; import 'package:akuCommunity/utils/screenutil.dart'; @@ -76,6 +77,8 @@ class _HomePageState extends State @override Widget build(BuildContext context) { + ScreenUtil.init(context, + designSize: Size(750, 1334), allowFontScaling: true); return Scaffold( appBar: PreferredSize( child: HomeAppBar(), diff --git a/lib/pages/sign/sign_in_page.dart b/lib/pages/sign/sign_in_page.dart index 1e8abd2b..33cd84f2 100644 --- a/lib/pages/sign/sign_in_page.dart +++ b/lib/pages/sign/sign_in_page.dart @@ -196,10 +196,6 @@ class _SignInPageState extends State { @override Widget build(BuildContext context) { double _statusHeight = MediaQuery.of(context).padding.top; - - ScreenUtil.init(context, - designSize: Size(750, 1334), allowFontScaling: true); - return Scaffold( backgroundColor: Colors.white, appBar: _appBar(), diff --git a/pubspec.yaml b/pubspec.yaml index 11464346..0c5a2f26 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -15,7 +15,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. # Read more about iOS versioning at # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html -version: 1.0.5+6 +version: 1.0.6+7 environment: sdk: ">=2.7.0 <3.0.0"