forked from eatvio/eatvio_app
fix(diary) Layout padding fix
This commit is contained in:
@@ -396,6 +396,8 @@ class DiaryEditBloc extends Bloc<DiaryEditEvent, DiaryEditState> {
|
|||||||
var updatedState = currentState.copyWith(
|
var updatedState = currentState.copyWith(
|
||||||
portions: currentState.meals?[id ?? 0]['portions'],
|
portions: currentState.meals?[id ?? 0]['portions'],
|
||||||
);
|
);
|
||||||
|
print(currentState.portions);
|
||||||
|
print(updatedState.portions);
|
||||||
emit(updatedState); // Передаем обновленное состояние в emit
|
emit(updatedState); // Передаем обновленное состояние в emit
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -416,7 +418,6 @@ class DiaryEditBloc extends Bloc<DiaryEditEvent, DiaryEditState> {
|
|||||||
'portion': portion,
|
'portion': portion,
|
||||||
'quantity': quantity,
|
'quantity': quantity,
|
||||||
};
|
};
|
||||||
print(credentials);
|
|
||||||
var response = await http.post(Uri.parse(url),
|
var response = await http.post(Uri.parse(url),
|
||||||
headers: {
|
headers: {
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
@@ -425,7 +426,6 @@ class DiaryEditBloc extends Bloc<DiaryEditEvent, DiaryEditState> {
|
|||||||
body: json.encode(credentials),
|
body: json.encode(credentials),
|
||||||
encoding: utf8);
|
encoding: utf8);
|
||||||
|
|
||||||
print(response.body);
|
|
||||||
return response;
|
return response;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -220,6 +220,10 @@ class DiaryEditScreen extends StatelessWidget {
|
|||||||
print(_options);
|
print(_options);
|
||||||
return Container(
|
return Container(
|
||||||
margin: EdgeInsets.symmetric(horizontal: 16.h),
|
margin: EdgeInsets.symmetric(horizontal: 16.h),
|
||||||
|
padding: EdgeInsets.symmetric(
|
||||||
|
horizontal: 24.h,
|
||||||
|
vertical: 12.v,
|
||||||
|
),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: Colors.white,
|
color: Colors.white,
|
||||||
borderRadius: const BorderRadius.all(Radius.circular(12)),
|
borderRadius: const BorderRadius.all(Radius.circular(12)),
|
||||||
|
|||||||
Reference in New Issue
Block a user