修改个人中心登录逻辑

hmxc
张萌 4 years ago
parent 115bd12187
commit 718615a66c

@ -13,7 +13,8 @@ import 'package:akuCommunity/routers/page_routers.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
class PersonalIndex extends StatefulWidget {
PersonalIndex({Key key}) : super(key: key);
final bool isSign;
PersonalIndex({Key key, this.isSign}) : super(key: key);
@override
_PersonalIndexState createState() => _PersonalIndexState();
@ -24,7 +25,12 @@ class _PersonalIndexState extends State<PersonalIndex>
@override
bool get wantKeepAlive => true;
bool _isSigned = false;
bool _isSigned=false;
@override
void initState() {
super.initState();
_isSigned=widget.isSign;
}
SliverAppBar _sliverAppBar(double height) {
return SliverAppBar(

@ -39,8 +39,8 @@ class _UserAuthenticationPageState extends State<UserAuthenticationPage> {
MaterialButton(
child: Text('跳过'),
onPressed: () {
ARoute.pop(context);
ARoute.pushReplace(context, TabNavigator());
ARoute.pop(context,root: true);
ARoute.pushReplace(context, TabNavigator(isSign: true,));
},
),
],

@ -9,16 +9,11 @@ import 'property/property_index.dart';
import 'community/community_index.dart';
import 'personal/personal_page.dart';
//
List<Widget> _pages = <Widget>[
HomePage(),
MarketPage(),
PropertyIndex(),
CommunityIndex(),
PersonalIndex()
];
class TabNavigator extends StatefulWidget {
final bool isSign;
const TabNavigator({Key key, this.isSign=false}) : super(key: key);
@override
_TabNavigatorState createState() => _TabNavigatorState();
}
@ -28,9 +23,23 @@ class _TabNavigatorState extends State<TabNavigator> {
int _currentIndex = 0;
DateTime _lastPressed;
//
List<Widget> _pages = <Widget>[
];
@override
void initState() {
super.initState();
_pages=[
HomePage(),
MarketPage(),
PropertyIndex(),
CommunityIndex(),
PersonalIndex(
isSign: widget.isSign,
)
];
}
@override

Loading…
Cancel
Save