|
|
@@ -120,9 +120,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
_createItem( |
|
|
|
'出生日期', |
|
|
|
birthday > 0 |
|
|
|
? DateFormat('yyyy-MM-dd').format( |
|
|
|
DateTime.fromMillisecondsSinceEpoch( |
|
|
|
birthday * 1000)) |
|
|
|
? DateFormat('yyyy-MM-dd').format(DateTime.fromMillisecondsSinceEpoch(birthday * 1000)) |
|
|
|
: user?.birthday ?? '', onTap: () { |
|
|
|
_selectBrithday(); |
|
|
|
}), |
|
|
@@ -130,16 +128,13 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
_createItem( |
|
|
|
'注册时间', |
|
|
|
registTime > 0 |
|
|
|
? DateFormat('yyyy-MM-dd').format( |
|
|
|
DateTime.fromMillisecondsSinceEpoch( |
|
|
|
registTime * 1000)) |
|
|
|
? DateFormat('yyyy-MM-dd').format(DateTime.fromMillisecondsSinceEpoch(registTime * 1000)) |
|
|
|
: user?.registerTime ?? ''), |
|
|
|
|
|
|
|
Padding( padding: const EdgeInsets.only(top: 8),child: _createItem('填写微信号', user?.is_upload_wx == '1' ? '已上传' : '未上传微信号与二维码', |
|
|
|
onTap: (){ |
|
|
|
Padding( |
|
|
|
padding: const EdgeInsets.only(top: 8), |
|
|
|
child: _createItem('填写微信号', user?.is_upload_wx == '1' ? '已上传' : '未上传微信号与二维码', onTap: () { |
|
|
|
Navigator.push(context, CupertinoPageRoute(builder: (_) => UploadWeChatPage())); |
|
|
|
})) |
|
|
|
|
|
|
|
], |
|
|
|
), |
|
|
|
); |
|
|
@@ -148,6 +143,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
|
|
|
|
// 头像 |
|
|
|
Widget _creteHeader(MineDetailModel user, {VoidCallback onTap}) { |
|
|
|
// Logger.log("头像:" + user?.avatar); |
|
|
|
return GestureDetector( |
|
|
|
child: Container( |
|
|
|
height: 140, |
|
|
@@ -160,9 +156,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
width: 80, |
|
|
|
height: 80, |
|
|
|
margin: EdgeInsets.only(top: 15), |
|
|
|
decoration: BoxDecoration( |
|
|
|
borderRadius: BorderRadius.circular(40), |
|
|
|
color: Colors.black12), |
|
|
|
decoration: BoxDecoration(borderRadius: BorderRadius.circular(40), color: Colors.black12), |
|
|
|
child: ClipRRect( |
|
|
|
borderRadius: BorderRadius.circular(40), |
|
|
|
child: CachedNetworkImage( |
|
|
@@ -196,10 +190,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
Expanded( |
|
|
|
child: Text( |
|
|
|
title ?? '', |
|
|
|
style: TextStyle( |
|
|
|
fontSize: 13, |
|
|
|
color: Color(0xff333333), |
|
|
|
fontWeight: FontWeight.bold), |
|
|
|
style: TextStyle(fontSize: 13, color: Color(0xff333333), fontWeight: FontWeight.bold), |
|
|
|
), |
|
|
|
), |
|
|
|
Text( |
|
|
@@ -223,8 +214,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
); |
|
|
|
} |
|
|
|
|
|
|
|
Widget _createInput(String title, TextEditingController controller, |
|
|
|
{VoidCallback onTap}) { |
|
|
|
Widget _createInput(String title, TextEditingController controller, {VoidCallback onTap}) { |
|
|
|
return GestureDetector( |
|
|
|
child: Container( |
|
|
|
padding: EdgeInsets.only(left: 12.5, right: 12.5), |
|
|
@@ -235,10 +225,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
Expanded( |
|
|
|
child: Text( |
|
|
|
title ?? '', |
|
|
|
style: TextStyle( |
|
|
|
fontSize: 13, |
|
|
|
color: Color(0xff333333), |
|
|
|
fontWeight: FontWeight.bold), |
|
|
|
style: TextStyle(fontSize: 13, color: Color(0xff333333), fontWeight: FontWeight.bold), |
|
|
|
), |
|
|
|
), |
|
|
|
Expanded( |
|
|
@@ -325,8 +312,7 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
toolbarWidgetColor: Colors.white, |
|
|
|
initAspectRatio: CropAspectRatioPreset.original, |
|
|
|
lockAspectRatio: true), |
|
|
|
iosUiSettings: IOSUiSettings( |
|
|
|
minimumAspectRatio: 1.0, aspectRatioLockEnabled: true)); |
|
|
|
iosUiSettings: IOSUiSettings(minimumAspectRatio: 1.0, aspectRatioLockEnabled: true)); |
|
|
|
if (cropperFile == null) { |
|
|
|
return; |
|
|
|
} |
|
|
@@ -360,13 +346,13 @@ class _MineDetailContainerState extends State<_MineDetailContainer> { |
|
|
|
builder: (context) { |
|
|
|
return ActionDateAlert( |
|
|
|
title: '选择出生日期', |
|
|
|
maxTimeNew: "max", |
|
|
|
); |
|
|
|
}, |
|
|
|
isScrollControlled: false, |
|
|
|
backgroundColor: Colors.transparent); |
|
|
|
if (dateTime != null) { |
|
|
|
String timeStamp = |
|
|
|
(dateTime.millisecondsSinceEpoch / 1000).ceil().toString(); |
|
|
|
String timeStamp = (dateTime.millisecondsSinceEpoch / 1000).ceil().toString(); |
|
|
|
_bloc.updateUser(birthday: timeStamp); |
|
|
|
} |
|
|
|
} |
|
|
|