forked from eatvio/eatvio_app
Plans dynamic display
This commit is contained in:
@@ -112,6 +112,9 @@ final Map<String, String> ru = {
|
||||
"circumferences_chart": "График обхватов",
|
||||
"bodymass_chart": "График ИМТ",
|
||||
"exit": "Выйти",
|
||||
"active": "Активен",
|
||||
"archived": "В архиве",
|
||||
"draft": "Черновик",
|
||||
"my_blog": "Мой блог", "lbl_01_04_21": "01.04.21", "lbl_01_05_21": "01.05.21",
|
||||
|
||||
// Настройки Screen
|
||||
|
||||
@@ -121,8 +121,7 @@ class MyProfileScreen extends StatelessWidget {
|
||||
text: "тест".toUpperCase(),
|
||||
margin: EdgeInsets.only(left: 10.h),
|
||||
onPressed: () {
|
||||
print(dotenv.env['STORAGE_URL']! +
|
||||
state.plans?[0]['image']);
|
||||
print(dotenv.env['STORAGE_URL']!);
|
||||
});
|
||||
default:
|
||||
return Text('text',
|
||||
@@ -579,66 +578,79 @@ class MyProfileScreen extends StatelessWidget {
|
||||
child: Stack(alignment: Alignment.bottomCenter, children: [
|
||||
Align(
|
||||
alignment: Alignment.topCenter,
|
||||
child: SizedBox(
|
||||
height: 40.v,
|
||||
width: 343.h,
|
||||
child: Stack(
|
||||
alignment: Alignment.bottomRight,
|
||||
children: [
|
||||
Align(
|
||||
alignment: Alignment.topCenter,
|
||||
child: Container(
|
||||
margin: EdgeInsets.only(bottom: 11.v),
|
||||
padding: EdgeInsets.symmetric(
|
||||
horizontal: 6.h, vertical: 4.v),
|
||||
decoration: AppDecoration.fillGray
|
||||
.copyWith(
|
||||
borderRadius:
|
||||
BorderRadiusStyle
|
||||
.roundedBorder5),
|
||||
child: Row(
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment
|
||||
.spaceBetween,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.only(
|
||||
bottom: 1.v),
|
||||
child: Text(plans![0],
|
||||
style: CustomTextStyles
|
||||
.titleSmallBluegray800Bold)),
|
||||
Container(
|
||||
height: 19.v,
|
||||
width: 100.h,
|
||||
decoration: BoxDecoration(
|
||||
color:
|
||||
appTheme.greenA700,
|
||||
borderRadius:
|
||||
BorderRadius
|
||||
.circular(5.h)))
|
||||
]))),
|
||||
Align(
|
||||
alignment: Alignment.center,
|
||||
child: Container(
|
||||
margin: EdgeInsets.only(bottom: 12.h),
|
||||
child: Image.network(
|
||||
dotenv.env['STORAGE_URL']! +
|
||||
image_paths?[0],
|
||||
height: 25.adaptSize,
|
||||
width: 25.adaptSize,
|
||||
))),
|
||||
Align(
|
||||
child: ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: plans?.length ?? 0,
|
||||
itemBuilder: (context, i) {
|
||||
String state = states?[i];
|
||||
return SizedBox(
|
||||
height: 40.v,
|
||||
width: 343.h,
|
||||
child: Stack(
|
||||
alignment: Alignment.bottomRight,
|
||||
child: Container(
|
||||
width: 60.h,
|
||||
margin: EdgeInsets.only(
|
||||
right: 0.h, top: 0.h),
|
||||
child: Text(states?[0],
|
||||
maxLines: 2,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style:
|
||||
theme.textTheme.titleSmall)))
|
||||
]))),
|
||||
children: [
|
||||
Align(
|
||||
alignment: Alignment.topCenter,
|
||||
child: Container(
|
||||
margin: EdgeInsets.only(
|
||||
bottom: 11.v),
|
||||
padding: EdgeInsets.symmetric(
|
||||
horizontal: 6.h,
|
||||
vertical: 4.v),
|
||||
decoration: AppDecoration
|
||||
.fillGray
|
||||
.copyWith(
|
||||
borderRadius:
|
||||
BorderRadiusStyle
|
||||
.roundedBorder5),
|
||||
child: Row(
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment
|
||||
.spaceBetween,
|
||||
children: [
|
||||
Padding(
|
||||
padding:
|
||||
EdgeInsets.only(
|
||||
bottom: 1.v),
|
||||
child: Text(plans![i],
|
||||
style: CustomTextStyles
|
||||
.titleSmallBluegray800Bold)),
|
||||
Container(
|
||||
height: 19.v,
|
||||
width: 100.h,
|
||||
decoration: BoxDecoration(
|
||||
color: appTheme
|
||||
.greenA700,
|
||||
borderRadius:
|
||||
BorderRadius
|
||||
.circular(
|
||||
5.h)))
|
||||
]))),
|
||||
/*Align(
|
||||
alignment: Alignment.center,
|
||||
child: Container(
|
||||
margin: EdgeInsets.only(
|
||||
bottom: 12.h),
|
||||
child: Image.network(
|
||||
dotenv.env['STORAGE_URL']! +
|
||||
image_paths?[i],
|
||||
height: 25.adaptSize,
|
||||
width: 25.adaptSize,
|
||||
))),*/
|
||||
Align(
|
||||
alignment: Alignment.bottomRight,
|
||||
child: Container(
|
||||
width: 60.h,
|
||||
margin: EdgeInsets.only(
|
||||
bottom: 13.h, right: 22.h),
|
||||
child: Text("$state".tr,
|
||||
maxLines: 2,
|
||||
overflow:
|
||||
TextOverflow.ellipsis,
|
||||
style: theme
|
||||
.textTheme.titleSmall)))
|
||||
]));
|
||||
})),
|
||||
]))
|
||||
])));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user