feat : SalesOutOfProvincePage main page
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:rasadyar_chicken/data/models/response/steward_free_bar_dashboard/steward_free_bar_dashboard.dart';
|
||||
import 'package:rasadyar_core/core.dart';
|
||||
@@ -11,25 +10,108 @@ class SalesOutOfProvincePage extends GetView<SalesOutOfProvinceLogic> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: RAppBar(
|
||||
title: 'رصدطیور',
|
||||
iconTitle: Assets.vec.chickenSvg.path,
|
||||
titleTextStyle:AppFonts.yekan16Bold.copyWith(color: Colors.white),
|
||||
centerTitle: true,
|
||||
hasBack: false,
|
||||
leading: Row(children: [Text('مباشر', style: AppFonts.yekan16Bold.copyWith(color: Colors.white))]),
|
||||
),
|
||||
body: SingleChildScrollView(
|
||||
child: Column(
|
||||
backgroundColor: AppColor.bgLight,
|
||||
appBar: RAppBar(
|
||||
title: 'رصدطیور',
|
||||
iconTitle: Assets.vec.chickenSvg.path,
|
||||
titleTextStyle: AppFonts.yekan16Bold.copyWith(color: Colors.white),
|
||||
centerTitle: true,
|
||||
hasBack: false,
|
||||
leadingWidth: 130,
|
||||
leading: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
spacing: 6,
|
||||
children: [
|
||||
SizedBox(height: 12),
|
||||
ObxValue(
|
||||
(model) => summaryOfInformation(model.value),
|
||||
controller.stewardFreeDashboard,
|
||||
Assets.vec.cubeSearchSvg.svg(
|
||||
width: 24,
|
||||
height: 24,
|
||||
colorFilter: const ColorFilter.mode(Colors.white, BlendMode.srcIn),
|
||||
),
|
||||
Text('خارج استان', style: AppFonts.yekan16Bold.copyWith(color: Colors.white)),
|
||||
],
|
||||
),
|
||||
additionalActions: [
|
||||
Assets.vec.searchSvg.svg(
|
||||
width: 24,
|
||||
height: 24,
|
||||
colorFilter: const ColorFilter.mode(Colors.white, BlendMode.srcIn),
|
||||
),
|
||||
SizedBox(width: 8),
|
||||
Assets.vec.filterOutlineSvg.svg(
|
||||
width: 20,
|
||||
height: 20,
|
||||
colorFilter: const ColorFilter.mode(Colors.white, BlendMode.srcIn),
|
||||
),
|
||||
SizedBox(width: 8),
|
||||
],
|
||||
),
|
||||
body: Column(
|
||||
children: [
|
||||
SizedBox(height: 12),
|
||||
ObxValue((model) => summaryOfInformation(model.value), controller.stewardFreeDashboard),
|
||||
Expanded(
|
||||
child: ListView.separated(
|
||||
padding: const EdgeInsets.fromLTRB(8, 12, 8, 100),
|
||||
shrinkWrap: true,
|
||||
physics: BouncingScrollPhysics(),
|
||||
itemBuilder: (BuildContext context, int index) {
|
||||
return Container(
|
||||
padding: EdgeInsets.symmetric(horizontal: 8, vertical: 10),
|
||||
|
||||
decoration: BoxDecoration(color: Colors.white, borderRadius: BorderRadius.circular(8)),
|
||||
child: Column(
|
||||
spacing: 8,
|
||||
children: [
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Assets.vec.editSvg.svg(
|
||||
width: 20,
|
||||
height: 20,
|
||||
colorFilter: ColorFilter.mode(AppColor.blueNormal, BlendMode.srcIn),
|
||||
),
|
||||
|
||||
Text(
|
||||
'لرستان - خرم آباد',
|
||||
textAlign: TextAlign.center,
|
||||
style: AppFonts.yekan16.copyWith(color: AppColor.greenDark),
|
||||
),
|
||||
|
||||
Assets.vec.trashSvg.svg(
|
||||
width: 20,
|
||||
height: 20,
|
||||
colorFilter: ColorFilter.mode(AppColor.error, BlendMode.srcIn),
|
||||
),
|
||||
],
|
||||
),
|
||||
Container(
|
||||
height: 32,
|
||||
padding: EdgeInsets.symmetric(horizontal: 4),
|
||||
decoration: ShapeDecoration(
|
||||
color: AppColor.blueLight,
|
||||
shape: RoundedRectangleBorder(
|
||||
side: BorderSide(width: 1, color: AppColor.blueLightHover),
|
||||
borderRadius: BorderRadius.circular(8),
|
||||
),
|
||||
),
|
||||
child: buildRow('تاریخ', '07:15:00 - 1402/07/01'),
|
||||
),
|
||||
|
||||
buildRow('مشخصات فروشنده', 'افلاک - 09203659874'),
|
||||
buildRow('وزن خریداری شده', '200 کیلوگرم'),
|
||||
buildRow('لاشه خریداری شده', '200 عدد'),
|
||||
],
|
||||
),
|
||||
);
|
||||
},
|
||||
separatorBuilder: (BuildContext context, int index) => SizedBox(height: 6),
|
||||
itemCount: 3,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
floatingActionButton: RFab.add(onPressed: () {}),
|
||||
floatingActionButtonLocation: FloatingActionButtonLocation.startFloat,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -39,14 +121,7 @@ class SalesOutOfProvincePage extends GetView<SalesOutOfProvinceLogic> {
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8),
|
||||
child: Row(
|
||||
children: [
|
||||
Text(
|
||||
'خلاصه اطلاعات',
|
||||
style: AppFonts.yekan16Bold.copyWith(
|
||||
color: AppColor.blueNormal,
|
||||
),
|
||||
),
|
||||
],
|
||||
children: [Text('خلاصه اطلاعات', style: AppFonts.yekan16Bold.copyWith(color: AppColor.blueNormal))],
|
||||
),
|
||||
),
|
||||
Container(
|
||||
@@ -65,15 +140,9 @@ class SalesOutOfProvincePage extends GetView<SalesOutOfProvinceLogic> {
|
||||
spacing: 10,
|
||||
children: [
|
||||
const SizedBox(height: 12),
|
||||
buildRow(
|
||||
'تعداد کل بارها',
|
||||
model.totalQuantity?.toString() ?? '0',
|
||||
),
|
||||
buildRow('تعداد کل بارها', model.totalQuantity?.toString() ?? '0'),
|
||||
buildRow('تعداد کل', model.totalBars?.toString() ?? '0'),
|
||||
buildRow(
|
||||
'وزن کل (کیلوگرم)',
|
||||
model.totalWeight?.toString() ?? '0',
|
||||
),
|
||||
buildRow('وزن کل (کیلوگرم)', model.totalWeight?.toString() ?? '0'),
|
||||
],
|
||||
),
|
||||
),
|
||||
@@ -92,9 +161,7 @@ class SalesOutOfProvincePage extends GetView<SalesOutOfProvinceLogic> {
|
||||
child: Text(
|
||||
title,
|
||||
textAlign: TextAlign.right,
|
||||
style: AppFonts.yekan14.copyWith(
|
||||
color: AppColor.darkGreyDarkHover,
|
||||
),
|
||||
style: AppFonts.yekan14.copyWith(color: AppColor.darkGreyDarkHover),
|
||||
),
|
||||
),
|
||||
Flexible(
|
||||
@@ -102,9 +169,7 @@ class SalesOutOfProvincePage extends GetView<SalesOutOfProvinceLogic> {
|
||||
child: Text(
|
||||
value,
|
||||
textAlign: TextAlign.left,
|
||||
style: AppFonts.yekan14.copyWith(
|
||||
color: AppColor.darkGreyDarkHover,
|
||||
),
|
||||
style: AppFonts.yekan14.copyWith(color: AppColor.darkGreyDarkHover),
|
||||
),
|
||||
),
|
||||
],
|
||||
@@ -112,8 +177,6 @@ class SalesOutOfProvincePage extends GetView<SalesOutOfProvinceLogic> {
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Widget inventoryWidget() {
|
||||
return Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8.0),
|
||||
|
||||
@@ -72,6 +72,9 @@ class $AssetsIconsGen {
|
||||
/// File path: assets/icons/filter.svg
|
||||
SvgGenImage get filter => const SvgGenImage('assets/icons/filter.svg');
|
||||
|
||||
/// File path: assets/icons/filter_outline.svg
|
||||
SvgGenImage get filterOutline => const SvgGenImage('assets/icons/filter_outline.svg');
|
||||
|
||||
/// File path: assets/icons/gps.svg
|
||||
SvgGenImage get gps => const SvgGenImage('assets/icons/gps.svg');
|
||||
|
||||
@@ -192,6 +195,7 @@ class $AssetsIconsGen {
|
||||
edit,
|
||||
excelDownload,
|
||||
filter,
|
||||
filterOutline,
|
||||
gps,
|
||||
home,
|
||||
information,
|
||||
@@ -317,6 +321,9 @@ class $AssetsVecGen {
|
||||
/// File path: assets/vec/filter.svg.vec
|
||||
SvgGenImage get filterSvg => const SvgGenImage.vec('assets/vec/filter.svg.vec');
|
||||
|
||||
/// File path: assets/vec/filter_outline.svg.vec
|
||||
SvgGenImage get filterOutlineSvg => const SvgGenImage.vec('assets/vec/filter_outline.svg.vec');
|
||||
|
||||
/// File path: assets/vec/gps.svg.vec
|
||||
SvgGenImage get gpsSvg => const SvgGenImage.vec('assets/vec/gps.svg.vec');
|
||||
|
||||
@@ -437,6 +444,7 @@ class $AssetsVecGen {
|
||||
editSvg,
|
||||
excelDownloadSvg,
|
||||
filterSvg,
|
||||
filterOutlineSvg,
|
||||
gpsSvg,
|
||||
homeSvg,
|
||||
informationSvg,
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:rasadyar_core/core.dart';
|
||||
import 'package:rasadyar_core/presentation/common/app_color.dart';
|
||||
import 'package:rasadyar_core/presentation/common/app_fonts.dart';
|
||||
|
||||
class RAppBar extends StatelessWidget implements PreferredSizeWidget {
|
||||
final String title;
|
||||
@@ -48,23 +45,15 @@ class RAppBar extends StatelessWidget implements PreferredSizeWidget {
|
||||
titleTextStyle: titleTextStyle ?? AppFonts.yekan16.copyWith(color: Colors.white),
|
||||
title: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [Text(title),
|
||||
if (iconTitle != null)...{
|
||||
const SizedBox(width: 8)
|
||||
},
|
||||
if (iconTitle != null)...{
|
||||
SvgGenImage.vec(iconTitle!).svg(
|
||||
width: 24,
|
||||
height: 24,
|
||||
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
]),
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Text(title),
|
||||
if (iconTitle != null) ...{const SizedBox(width: 8)},
|
||||
if (iconTitle != null) ...{SvgGenImage.vec(iconTitle!).svg(width: 24, height: 24)},
|
||||
],
|
||||
),
|
||||
leadingWidth: leadingWidth?.toDouble(),
|
||||
leading: leading != null ? Padding(padding: const EdgeInsets.only(right: 16), child: leading) : null,
|
||||
leading: leading != null ? Padding(padding: const EdgeInsets.only(right: 6), child: leading) : null,
|
||||
titleSpacing: 8,
|
||||
actions: [
|
||||
if (additionalActions != null) ...additionalActions!,
|
||||
|
||||
@@ -20,3 +20,4 @@ export 'chips/r_chips.dart';
|
||||
export 'overlay_dropdown_widget/view.dart';
|
||||
export 'inputs/input_fixed_hint.dart';
|
||||
export 'bottom_sheet/base_bottom_sheet.dart';
|
||||
export 'buttons/fab.dart';
|
||||
|
||||
Reference in New Issue
Block a user